Bug 135476

Summary: support for multiple comment authors
Product: [Applications] digikam Reporter: Wolfgang Mader <Wolfgang_Mader>
Component: Tags-CaptionsAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: wishlist CC: ahuggel, caulier.gilles, marcel.wiesweg
Priority: NOR    
Version: 0.8.2   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In: 1.0.0
Sentry Crash Report:

Description Wolfgang Mader 2006-10-11 23:48:30 UTC
Version:           0.8.2 (using KDE 3.5.5, Debian Package 4:3.5.5a-1 (testing/unstable))
Compiler:          Target: x86_64-linux-gnu
OS:                Linux (x86_64) release 2.6.17-1-amd64-k8

Hello,

I think it would be usefull if digiKam would be able to allow multiple authors to add comments to one picture. The different authors could be distinguished by printing their comments in different colors, or by setting the name in front of the comment.

Thank you. W. Mader
Comment 1 caulier.gilles 2006-11-15 21:53:20 UTC
digikam 0.9.0 support IPTC metadata. In current kipi-plugins implementation, there is a new plugin to edit IPTC data. Look here : http://www.digikam.org/?q=node/163

Please check if IPTC can be a solution for you.

Gilles Caulier

Comment 2 caulier.gilles 2007-10-02 09:34:59 UTC
WolfGang,

digiKam for KDE4 will support Xmp metadata witch support multiple comment authors...

Gilles

Comment 3 caulier.gilles 2007-10-03 12:35:25 UTC
SVN commit 720609 by cgilles:

digiKam from trunk (KDE4) : XMP metadata management with database.

This is the first stage to control XMP metadata contents with Database contents and vis versa. This code handle XMP with current Database schema witch still the same than 0.9.x.

Marcel work currently on the new databse schema describe on the OpenOffice document available at this url :

http://websvn.kde.org/trunk/extragear/graphics/digikam/DBSCHEMA.ODS?view=log

The code will be adapted later by Marcel to handle more XMP tags according with this new schema.

This is the list of current changes :

- Preparing code to handle strings hosted in different languages (comments for example, dixit B.K.O #98462).
- Handle all Xmp.exif and Xmp.tiff tags has Exif metadata content to get photo informations set by camera.
- Do not set Iptc.Urgency tag with Rating value, but use standard Xmp.Rating tags instead. Import of Iptc.Urgency
as Rating still running if Xmp metadata are not available. (B.K.O: 134206).
- Preparing code to handle Xmp strings set different authors(comments for example, dixit B.K.O #134476).
- Set the Tags name as Xmp.subject (keywords).
- Set the Copyright/Authors information in Xmp tags (schema inspired from Adobe Photoshop 7.0).
- Store Tags Path List into a dedicaced digiKam.org Xmp namespace as a sequence of strings. Do not use Iptc.Keywords for that. Import from Iptc still running if Xmp metadata is not available. This way is very important to restore properlly in database all tags assigned to an imported picture. There is not strings size limitation with Xmp and char encoding is always UTF-8. Nothing will be lost now.
- Xmp is always stored in pictures format witch support this metadata format : jpeg, png, and tiff.

All these changes require to update libkexiv2 and Exiv2 from trunk to compile and run digiKam properlly.

CCMAIL: digikam-devel@kde.org
CCMAIL: marcel.wiesweg@gmx.de

BUG: 134206
BUG: 149966

CCBUGS: 98462
CCBUGS: 132362
CCBUGS: 91811
CCBUGS: 134476
CCBUGS: 136260
CCBUGS: 146714




 M  +59 -44    digikam/metadatahub.cpp  
 M  +1 -1      libs/database/collectionscanner.cpp  
 M  +127 -71   libs/dmetadata/dmetadata.cpp  
 M  +5 -4      libs/dmetadata/dmetadata.h  
Comment 4 caulier.gilles 2009-06-12 15:42:24 UTC
Marcel,

Same there. DB schema support multi-authors for comments ?

Gilles Caulier
Comment 5 caulier.gilles 2009-07-11 16:37:39 UTC
Marcel, 

I cannot see an XMP structure to host Caption with all properties listed below :

- Language.
- Date
- Author.

Only Language propertie is available.

Solution : create a new entry in XMp digiKam namespace to host all these properties.

Gilles Caulier
Comment 6 caulier.gilles 2009-07-12 10:00:12 UTC
Andreas, 


please read my comment #5, and let's me hear if you know a standard XMP properties to host an alternative language comments with author name and date attributs. 

I think i do not exist and i need to create a dedicated structure in digiKam XMP namespace. Right ?

Gilles
Comment 7 Marcel Wiesweg 2009-07-12 16:38:07 UTC
Yes in XMP there is no relation comment <-> author, there is photoshop:CaptionWriter which is not even a array but a single field.
Our DB schema is extending the XMP data model here, having an author field per comment comes natural for a DB schema but not for a metadata standard.
Comment 8 caulier.gilles 2009-07-14 10:07:03 UTC
SVN commit 996339 by cgilles:

add support of Captions author properties.
For each language alternative caption values, user can fill caption author name
A caption date properties is also set accordingly, using current date when caption is enter.
These new Captions properties are recordrd to datase only, for the moment.
TODO: record all captions properties to digiKam XMP namespace
CCBUGS: 135476


 M  +3 -1      CMakeLists.txt  
 M  +11 -12    digikam/metadatahub.cpp  
 M  +8 -9      digikam/metadatahub.h  
 M  +13 -9     libs/database/imagecomments.cpp  
 M  +5 -12     libs/database/imagecomments.h  
 M  +27 -13    libs/dmetadata/dmetadata.cpp  
 M  +3 -2      libs/dmetadata/dmetadata.h  
 AM            libs/imageproperties/captionedit.cpp   [License: GPL (v2+)]
 AM            libs/imageproperties/captionedit.h   [License: GPL (v2+)]
 AM            libs/imageproperties/captionvalues.cpp   [License: GPL (v2+)]
 AM            libs/imageproperties/captionvalues.h   [License: GPL (v2+)]
 M  +9 -11     libs/imageproperties/imagedescedittab.cpp  
 M  +28 -4     libs/template/altlangstredit.cpp  
 M  +17 -6     libs/template/altlangstredit.h  
 M  +1 -1      utilities/imageeditor/editor/imagewindow.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=996339
Comment 9 caulier.gilles 2009-07-14 10:45:05 UTC
Marcel, Andreas,

How I can play with Exiv2 API to write captions map in digiKam XMP namespace ?

http://websvn.kde.org/trunk/extragear/graphics/digikam/libs/dmetadata/captionvalues.h?view=markup

any pointers ?

Gilles Caulier
Comment 10 caulier.gilles 2009-07-14 21:09:32 UTC
SVN commit 996721 by cgilles:

Save/restore Captions properties to/from digiKam XMP namespace.
Authors and Dates roperties are saved in alternative language bags. Captions Map is build using all these properties,
plus the comments get from standard XMP tags.

Marcel,
When i import a new image with these XMP metadata into collection, authors and dates map are not imported in database...
CCBUGS: 135476
CCMAIL: marcel.wiesweg@gmx.de


 M  +53 -0     captionvalues.cpp  
 M  +10 -0     captionvalues.h  
 M  +32 -16    dmetadata.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=996721
Comment 11 caulier.gilles 2009-07-15 09:44:03 UTC
Marcel,

Sound like the problem from #10 is in this method which don't use DMetadata::getImageComments() :

http://lxr.kde.org/source/extragear/graphics/digikam/libs/database/imagescanner.cpp#352

Gilles
Comment 12 Marcel Wiesweg 2009-07-15 20:47:37 UTC
Yes this code is not ported.
Comparing, it seems that the new getImageComments should honour the DescriptionWriter field ("Iptc.Application2.Writer", "Xmp.photoshop.CaptionWriter"). I think for all comments for which there is no author information in our private XMP fields, this should be the author.
We also need to write this field. A third problem arises if external software edits the DescriptionWriter field but of course does not touch our private XMP values.
Comment 13 Marcel Wiesweg 2009-07-15 20:57:41 UTC
SVN commit 997336 by mwiesweg:

In ImageScanner, rely on DMetadata::getImageComments
to handle all interpretation of comment values. No custom code here.

CCBUG: 135476

 M  +10 -33    imagescanner.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=997336
Comment 14 Marcel Wiesweg 2009-07-16 21:00:53 UTC
SVN commit 997978 by mwiesweg:

Use CollectionScanner/ImageScanner to read metadata from file to database.
This means that this method now uses 100% the same code as if the image
was completely unknown so far and newly added to the collection.

So this method can now be used if
- any metadata was changed by external tools
- a missing piece or bug in our scanning code filled wrong or incomplete info in the db

BUG: 135476

 M  +3 -1      NEWS  
 M  +6 -4      libs/imageproperties/imagedescedittab.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=997978
Comment 15 Marcel Wiesweg 2009-07-16 21:02:32 UTC
Sorry wrong bug number
Comment 16 caulier.gilles 2009-07-16 22:37:46 UTC
Marcel,

From there, when all regression tests will be done, this file can be closed.

Gilles
Comment 17 caulier.gilles 2009-07-18 16:19:20 UTC
Regression test done there. I close this file now...

Gilles Caulier