GNU Unifont 15.1.04
Pan-Unicode font with complete Unicode Plane 0 coverage and partial coverage of higher planes
|
unipagecount - Count the number of glyphs defined in each page of 256 code points More...
#include <stdio.h>
#include <stdlib.h>
Go to the source code of this file.
Macros | |
#define | MAXBUF 256 |
Maximum input line size - 1. | |
Functions | |
int | main (int argc, char *argv[]) |
The main function. | |
void | mkftable (unsigned plane, int pagecount[256], int links) |
Create an HTML table linked to PNG images. | |
unipagecount - Count the number of glyphs defined in each page of 256 code points
This program counts the number of glyphs that are defined in each "page" of 256 code points, and prints the counts in an 8 x 8 grid. Input is from stdin. Output is to stdout.
The background color of each cell in a 16-by-16 grid of 256 code points is shaded to indicate percentage coverage. Red indicates 0% coverage, green represents 100% coverage, and colors in between pure red and pure green indicate partial coverage on a scale.
Each code point range number can be a hyperlink to a PNG file for that 256-code point range's corresponding bitmap glyph image.
Synopsis:
unipagecount < font_file.hex > count.txt unipagecount -phex_page_num < font_file.hex -- just 256 points unipagecount -h < font_file.hex -- HTML table unipagecount -P1 -h < font.hex > count.html -- Plane 1, HTML out unipagecount -l < font_file.hex -- linked HTML table
Definition in file unipagecount.c.
#define MAXBUF 256 |
Maximum input line size - 1.
Definition at line 59 of file unipagecount.c.
int main | ( | int | argc, |
char * | argv[] | ||
) |
The main function.
[in] | argc | The count of command line arguments. |
[in] | argv | Pointer to array of command line arguments. |
Definition at line 70 of file unipagecount.c.
void mkftable | ( | unsigned | plane, |
int | pagecount[256], | ||
int | links | ||
) |
Create an HTML table linked to PNG images.
This function creates an HTML table to show PNG files in a 16 by 16 grid. The background color of each "page" of 256 code points is shaded from red (for 0% coverage) to green (for 100% coverage).
[in] | plane | The Unicode plane, 0..17. |
[in] | pagecount | Array with count of glyphs in each 256 code point range. |
[in] | links | 1 = generate hyperlinks, 0 = do not generate hyperlinks. |
Definition at line 190 of file unipagecount.c.