Problem with annotation with version 0.5

2007-06-12
2012-12-01
  • Hi,

    Thank you so much for making available a new version and the long awaited annotation feature. 

    One question though.  Where are the annotation data stored?

    I annotated a djvu image with simple yellow highlighter on computer A.  Took it to computer B and tried to view it,  the highlights are gone.  Back to computer A, the highlights are there. 

    md5 check of the djvu image, seems nothing changed.  Tried to find the annotation.  Not on registry or anywhere I can think of. 

    Am I doing something wrong?

    Notes:
    computers are both toshiba laptop running xp sp2, windjview 0.5

    Thanks again. 

     
    • Hi,

      I think I found the registry entry for annotations:

      HKEY_CURRENT_USER\Software\Andrew Zhezherun\WinDjView\Documents

      Can annotation be in a separate file other than the registry? In another word, how to make it simple, portable and without touching the registry? 

      Thanks again

       
      • In a future version it will be possible to keep annotations/bookmarks in an xml file placed alongside the document, but currently they are stored only in the registry.

         
    • Thank you for the clarification.  I just never expected the annotation will be in the registry. It seems, all of a sudden, the usefulness of this new feature is gone.

      Also I just noticed another problem, may be.  Say I have two identical  djvu files in two different locations.  Windjview seems to treat them as the same file, and it is not possible to have  annotations unique to each one of the copies. 

      You are becoming my hero :-)

      John

       
      • This is the intended behavior. The reasoning was the following: 1) the way of storing annotations should be consistent, for simplicity; 2) file and, moreover, the folder are often read-only (reading off a CD); 3) there must be no changes to the djvu file; 4) because of (2) storing the annotations in a separate file in the same folder won't always work either, and because of (1) was not considered; 4) the file may be copied/moved, and the annotations should be preserved. The remaining options were registry and Application Data folder, which were more or less equivalent; and the settings are bound to a checksum of the file to ensure (4). I understand that my solution might be not the optimal one, but it was the best I could do in a limited time. In a future version there might be some changes to this scheme.

         
    • Understood the design constraints and rationale. 

      I love the fact that even though windjview uses the registry, it is small, fast and portable.   Although it would be nicer if  application settings could be saved, as as option, in an .ini file in the directory of windjview.  (I put Windjview with djvu books in usb drives for portability and sharing)

      Personally, I think it will be more intuitive that the default behavior is to modify the original djvu file.  It is the approach taken by good old tiff annotation, exif and iptc for jpg, and pdf annotation.  It solves the problem of scale and maintenance.

      Given the ever dropping cost of hard disk, I think it should be the user's responsibility to make copies of djvu files from CD to the hard disk, renaming if necessary, before annotating. The same problem and solution applies to jpg, pdf and etc that are on CD, DVD, and online that need to be annotated. 

      For me, window registry and Application Data folder are like plagues. 

      Once again, thank you so much for taking the time to explain the design considerations. 

      Best regards,

      John

       
    • Why not put the annotation data in a subfolder within Windjview?  Better give the user a choice to where to put it, in case Windjview is in a read-only folder.

      That should make it easy to backup, copy or move the annotation. 

      Just an opinion.

       
      • Annotation features will be improved in the next versions of WinDjView.

         
    • Known issues, but with some more details..

      ...When someone receives DJVU file on his comp, they cannot be seen.
      The same thing is when I would like to transfer my files into another PC.
      "Bookmarks" is Registry Dependant and WORSE! dependant on size
      of the file. If you insert any bite of data in the file, they disapear!
      If you remove it, they appear! If you add something in the structure,
      they disapear and so on! By this practice, your system may be full of
      nowhere pointing meta data and all the work on bookmarks may
      become spoiled. Finally I have found, by couple of tests, where 
      your bookmarking in WinDjvu is stored. Their file-size dependance is
      of course very unfortunate too. Of course, I am now able to backup my
      annotations by backing the registry values, but still, any change in the
      original file, adding pages, removing pages, adding Comments (previously
      named Bookmarks), all result in change of size of the document and
      therefore in loose of Comments, which will point in the registry to unexisting file.
      Thus the reigstry will stuff with nonsensial data and grow and grow :-)

      I recomend to re-think whole concept and use insteed of it
      filename dependant & directory present bookmark files, as for example...

      (perhaps the bes solution!)
      MyFile.djvu (as a djvu file)
      MyFile.bkm  (as bookmark metadata file - perhaps XML or plain TXT file) !!!

      (alternatively)
      of course if you are not able to directly bundle it (tie up with) the DJVU file !?

      In this way whole think may be transferable into other PCs and
      no conflicts could ocure!

       
      • I understand your concerns. Thing will improve in the future versions of WinDjView, so please be patient. Or you can download the source code, make the necessary changes and submit a patch. Please remember, that this is an open source project. Also have a look at the rest of this thread for the reasoning behind current implementation.