[SCM] exiv2 packaging branch, master, updated. debian/0.25-3.1-3734-gdcbc29a
Maximiliano Curia
maxy at moszumanska.debian.org
Thu Jul 13 17:38:48 UTC 2017
Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=9e55854
The following commit has been merged in the master branch:
commit 9e55854e87782c089642f815854c1e64af52d934
Author: Andreas Huggel <ahuggel at gmx.net>
Date: Sat Sep 29 17:55:34 2007 +0000
Added associative array style commands.
---
src/xmpsample.cpp | 6 ++++++
test/data/xmpparser-test.out | 17 +++++++++++++++--
2 files changed, 21 insertions(+), 2 deletions(-)
diff --git a/src/xmpsample.cpp b/src/xmpsample.cpp
index 7e193be..9a4c520 100644
--- a/src/xmpsample.cpp
+++ b/src/xmpsample.cpp
@@ -36,6 +36,12 @@ try {
v->read("Hello, World"); // qualifier
xmpData.add(Exiv2::XmpKey("Xmp.dc.description"), v.get());
+ // Or all of the above but using associative array style syntax
+ xmpData["Xmp.dc.format"] = "image/tiff"; // overwrites existing value
+ xmpData["Xmp.dc.subject"] = "Palmtree"; // adds a new array value
+ xmpData["Xmp.dc.subject"] = "Rubbertree"; // adds a second array item
+ xmpData["Xmp.dc.title"] = "lang=en-US Beach"; // a language alternative
+
// -------------------------------------------------------------------------
// Register a namespace which Exiv2 doesn't know yet. This is only needed
// when properties are added manually. If the XMP metadata is read from an
diff --git a/test/data/xmpparser-test.out b/test/data/xmpparser-test.out
index dc84e59..3c0a77f 100644
--- a/test/data/xmpparser-test.out
+++ b/test/data/xmpparser-test.out
@@ -279,9 +279,11 @@ Xmp.ns1.NestedStructProp/ns2:Outer/ns2:Middle/ns2:Inner/ns2:Field2 XmpText 12
>
> <?xpacket end="w"?>
\ No newline at end of file
-Xmp.dc.format XmpText 10 image/jpeg
+Xmp.dc.format XmpText 10 image/tiff
Xmp.dc.creator XmpSeq 3 1) The first creator, 2) The second creator, 3) And another one
Xmp.dc.description LangAlt 2 lang="de-DE" Hallo, Welt, lang="x-default" Hello, World
+Xmp.dc.subject XmpBag 2 Palmtree, Rubbertree
+Xmp.dc.title LangAlt 1 lang="en-US" Beach
Xmp.xmpDM.videoFrameSize/stDim:w XmpText 2 16
Xmp.xmpDM.videoFrameSize/stDim:h XmpText 1 9
Xmp.xmpDM.videoFrameSize/stDim:unit XmpText 4 inch
@@ -303,7 +305,7 @@ Xmp.xmpBJ.JobRef[2]/stJob:role XmpText 8 Best man
xmlns:stDim="http://ns.adobe.com/xap/1.0/sType/Dimensions#"
xmlns:xapBJ="http://ns.adobe.com/xap/1.0/bj/"
xmlns:stJob="http://ns.adobe.com/xap/1.0/sType/Job#"
- dc:format="image/jpeg">
+ dc:format="image/tiff">
<dc:creator>
<rdf:Seq>
<rdf:li>1) The first creator</rdf:li>
@@ -320,6 +322,17 @@ Xmp.xmpBJ.JobRef[2]/stJob:role XmpText 8 Best man
<rdf:li xml:lang="de-DE">Hallo, Welt</rdf:li>
</rdf:Alt>
</dc:description>
+ <dc:subject>
+ <rdf:Bag>
+ <rdf:li>Palmtree</rdf:li>
+ <rdf:li>Rubbertree</rdf:li>
+ </rdf:Bag>
+ </dc:subject>
+ <dc:title>
+ <rdf:Alt>
+ <rdf:li xml:lang="en-US">Beach</rdf:li>
+ </rdf:Alt>
+ </dc:title>
<dc:publisher rdf:parseType="Resource">
<rdf:value>James Bond</rdf:value>
<ns:role>secret agent</ns:role>
--
exiv2 packaging
More information about the pkg-kde-commits
mailing list