unifont-7.0.06.tar.gz
[unifont.git] / doc / unipng2hex.texi
1 @comment TROFF INPUT: .TH UNIPNG2HEX 1 "2013 Nov 09"
2
3 @node unipng2hex
4 @section unipng2hex
5 @c DEBUG: print_menu("@section")
6
7 @menu
8 * unipng2hex NAME::
9 * unipng2hex SYNOPSIS::
10 * unipng2hex DESCRIPTION::
11 * unipng2hex OPTIONS::
12 * unipng2hex EXAMPLE::
13 * unipng2hex FILES::
14 * unipng2hex SEE ALSO::
15 * unipng2hex AUTHOR::
16 * unipng2hex LICENSE::
17 * unipng2hex BUGS::
18
19 @end menu
20
21
22 @comment TROFF INPUT: .SH NAME
23
24 @node unipng2hex NAME
25 @subsection unipng2hex NAME
26 @c DEBUG: print_menu("unipng2hex NAME")
27
28 unipng2hex @minus{} Portable Network Graphics to GNU Unifont .hex file converter
29 @comment TROFF INPUT: .SH SYNOPSIS
30
31 @node unipng2hex SYNOPSIS
32 @subsection unipng2hex SYNOPSIS
33 @c DEBUG: print_menu("unipng2hex SYNOPSIS")
34
35 @comment TROFF INPUT: .br
36 @comment .br
37 @comment TROFF INPUT: .B unipng2hex
38 @b{unipng2hex}
39 -i
40 @comment TROFF INPUT: .I input_file.png
41 @i{input@t{_}file.png}
42 [-o
43 @comment TROFF INPUT: .I output_file.hex
44 @i{output@t{_}file.hex}
45 ] [-w
46 @comment TROFF INPUT: .I width
47 @i{width}
48 ]
49 @comment TROFF INPUT: .SH DESCRIPTION
50
51 @node unipng2hex DESCRIPTION
52 @subsection unipng2hex DESCRIPTION
53 @c DEBUG: print_menu("unipng2hex DESCRIPTION")
54
55 @comment TROFF INPUT: .B unipng2hex
56 @b{unipng2hex}
57 reads a PNG file produced by
58 @comment TROFF INPUT: .B unihex2png
59 @b{unihex2png}
60 before or after editing, and converts it back into a Unifont .hex format
61 file.  The PNG file contains a block of 256 Unicode code points
62 arranged in a 16 by 16 grid.  Each code point appears in a 32 by 32 or a 40
63 by 40 pixel grid.  Characters are either 16, 24 or 32 pixel rows high,
64 depending on the "-r" parameter specified by
65 @comment TROFF INPUT: .B unihex2png.
66 @b{unihex2png.}
67 They can be 8, 16, 24, or 32 pixel columns wide (widths of 32 are only
68 supported for 32 pixel row tall characters).
69 @comment TROFF INPUT: .SH OPTIONS
70
71 @node unipng2hex OPTIONS
72 @subsection unipng2hex OPTIONS
73 @c DEBUG: print_menu("unipng2hex OPTIONS")
74
75 @comment TROFF INPUT: .TP 12
76
77 @c ---------------------------------------------------------------------
78 @table @code
79 @item -i
80 Specify the input file.
81 @comment TROFF INPUT: .TP
82
83 @item -o
84 Specify the output file.  If omitted, a file in the Unifont .hex format
85 is written to STDOUT.
86 @comment TROFF INPUT: .TP
87
88 @item -w width
89 Specify the minimum width of the output glyphs.  Valid values are 16, 24,
90  and 32.  The default is no minimum width.
91 @comment TROFF INPUT: .TP
92
93 @item -h
94 Print a help message of options and exit.
95 @comment TROFF INPUT: .SH EXAMPLE
96
97 @end table
98
99 @c ---------------------------------------------------------------------
100
101 @node unipng2hex EXAMPLE
102 @subsection unipng2hex EXAMPLE
103 @c DEBUG: print_menu("unipng2hex EXAMPLE")
104
105 Sample usage:
106 @comment TROFF INPUT: .PP
107
108 @comment TROFF INPUT: .RS
109
110 @c ---------------------------------------------------------------------
111 @quotation
112 unipng2hex -i my@t{_}input@t{_}file.png -o my@t{_}output@t{_}file.hex
113 @comment TROFF INPUT: .RE
114
115 @end quotation
116
117 @c ---------------------------------------------------------------------
118 @comment TROFF INPUT: .SH FILES
119
120 @node unipng2hex FILES
121 @subsection unipng2hex FILES
122 @c DEBUG: print_menu("unipng2hex FILES")
123
124 *.png graphics files
125 @comment TROFF INPUT: .SH SEE ALSO
126
127 @node unipng2hex SEE ALSO
128 @subsection unipng2hex SEE ALSO
129 @c DEBUG: print_menu("unipng2hex SEE ALSO")
130
131 @comment TROFF INPUT: .BR bdfimplode(1),
132 @b{bdfimplode(1),}
133 @comment TROFF INPUT: .BR hex2bdf(1),
134 @b{hex2bdf(1),}
135 @comment TROFF INPUT: .BR hex2sfd(1),
136 @b{hex2sfd(1),}
137 @comment TROFF INPUT: .BR hexbraille(1),
138 @b{hexbraille(1),}
139 @comment TROFF INPUT: .BR hexdraw(1),
140 @b{hexdraw(1),}
141 @comment TROFF INPUT: .BR hexkinya(1),
142 @b{hexkinya(1),}
143 @comment TROFF INPUT: .BR hexmerge(1),
144 @b{hexmerge(1),}
145 @comment TROFF INPUT: .BR johab2ucs2(1),
146 @b{johab2ucs2(1),}
147 @comment TROFF INPUT: .BR unibdf2hex(1),
148 @b{unibdf2hex(1),}
149 @comment TROFF INPUT: .BR unibmp2hex(1),
150 @b{unibmp2hex(1),}
151 @comment TROFF INPUT: .BR unicoverage(1),
152 @b{unicoverage(1),}
153 @comment TROFF INPUT: .BR unidup(1),
154 @b{unidup(1),}
155 @comment TROFF INPUT: .BR unifont(5),
156 @b{unifont(5),}
157 @comment TROFF INPUT: .BR unifont-viewer(1),
158 @b{unifont-viewer(1),}
159 @comment TROFF INPUT: .BR unifontchojung(1),
160 @b{unifontchojung(1),}
161 @comment TROFF INPUT: .BR unifontksx(1),
162 @b{unifontksx(1),}
163 @comment TROFF INPUT: .BR unifontpic(1),
164 @b{unifontpic(1),}
165 @comment TROFF INPUT: .BR unigencircles(1),
166 @b{unigencircles(1),}
167 @comment TROFF INPUT: .BR unigenwidth(1),
168 @b{unigenwidth(1),}
169 @comment TROFF INPUT: .BR unihex2bmp(1),
170 @b{unihex2bmp(1),}
171 @comment TROFF INPUT: .BR unihex2png(1),
172 @b{unihex2png(1),}
173 @comment TROFF INPUT: .BR unihexfill(1),
174 @b{unihexfill(1),}
175 @comment TROFF INPUT: .BR unihexgen(1),
176 @b{unihexgen(1),}
177 @comment TROFF INPUT: .BR unipagecount(1)
178 @b{unipagecount(1)}
179 @comment TROFF INPUT: .SH AUTHOR
180
181 @node unipng2hex AUTHOR
182 @subsection unipng2hex AUTHOR
183 @c DEBUG: print_menu("unipng2hex AUTHOR")
184
185 @comment TROFF INPUT: .B unipng2hex
186 @b{unipng2hex}
187 was written by Andrew Miller, starting by converting Paul Hardy's
188 @comment TROFF INPUT: .B unibmp2hex
189 @b{unibmp2hex}
190 C program to Perl.
191 @comment TROFF INPUT: .SH LICENSE
192
193 @node unipng2hex LICENSE
194 @subsection unipng2hex LICENSE
195 @c DEBUG: print_menu("unipng2hex LICENSE")
196
197 @comment TROFF INPUT: .B unipng2hex
198 @b{unipng2hex}
199 is Copyright @copyright{} 2007, 2008 Paul Hardy, @copyright{} 2013 Andrew Miller.
200 @comment TROFF INPUT: .PP
201
202 This program is free software; you can redistribute it and/or modify
203 it under the terms of the GNU General Public License as published by
204 the Free Software Foundation; either version 2 of the License, or
205 (at your option) any later version.
206 @comment TROFF INPUT: .SH BUGS
207
208 @node unipng2hex BUGS
209 @subsection unipng2hex BUGS
210 @c DEBUG: print_menu("unipng2hex BUGS")
211
212 No known real bugs exist, but the optional pixel rows parameter is not
213 yet supported by all other Unifont utilities.  Use of glyphs taller than
214 the default of 16 pixels is considered experimental.  Currently
215 @comment TROFF INPUT: .B unihex2png, unipng2hex, hexdraw,
216 @b{unihex2png, unipng2hex, hexdraw,}
217 and
218 @comment TROFF INPUT: .B hex2bdf
219 @b{hex2bdf}
220 tentatively support glyphs that are 16, 24, and 32 pixels tall.
221 @comment TROFF INPUT: .PP
222
223 Also, this software does not perform extensive error checking on its
224 input files.  If they're not in the format of the original PNG output from
225 @comment TROFF INPUT: .B unihex2png,
226 @b{unihex2png,}
227 all bets are off.
228 @comment TROFF INPUT: .PP
229
230 If the output file is for a "page" containing space code points and the
231 PNG file squares for those code points are not empty,
232 @comment TROFF INPUT: .B unipng2hex
233 @b{unipng2hex}
234 preserves the graphics as they are drawn.
235 @comment TROFF INPUT: .PP
236
237 @comment TROFF INPUT: .B unipng2hex
238 @b{unipng2hex}
239 is designed to work with black and white pixels; do not use other
240 colors.