blob: ba3ffc30c48ae13e67233d5a3400b9792f0ccd55 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
package jogamp.opengl.util.pngj.chunks;
import jogamp.opengl.util.pngj.ImageInfo;
/**
* Superclass (abstract) for three textual chunks (TEXT, ITXT, ZTXT)
*/
public abstract class PngChunkTextVar extends PngChunkMultiple {
protected String key; // key/val: only for tEXt. lazy computed
protected String val;
// http://www.w3.org/TR/PNG/#11keywords
public final static String KEY_Title = "Title"; // Short (one line) title or caption for image
public final static String KEY_Author = "Author"; // Name of image's creator
public final static String KEY_Description = "Description"; // Description of image (possibly long)
public final static String KEY_Copyright = "Copyright"; // Copyright notice
public final static String KEY_Creation_Time = "Creation Time"; // Time of original image creation
public final static String KEY_Software = "Software"; // Software used to create the image
public final static String KEY_Disclaimer = "Disclaimer"; // Legal disclaimer
public final static String KEY_Warning = "Warning"; // Warning of nature of content
public final static String KEY_Source = "Source"; // Device used to create the image
public final static String KEY_Comment = "Comment"; // Miscellaneous comment
protected PngChunkTextVar(String id, ImageInfo info) {
super(id, info);
}
@Override
public ChunkOrderingConstraint getOrderingConstraint() {
return ChunkOrderingConstraint.NONE;
}
public static class PngTxtInfo {
public String title;
public String author;
public String description;
public String creation_time;// = (new Date()).toString();
public String software;
public String disclaimer;
public String warning;
public String source;
public String comment;
}
public String getKey() {
return key;
}
public String getVal() {
return val;
}
public void setKeyVal(String key, String val) {
this.key = key;
this.val = val;
}
}
|