June 1994
Intermediate to advanced
821 pages
24h 40m
English
GetOpts calls Usage when the
user tries to specify dimensions for the main window or icon, since this
program cannot deal with that complexity.
Example 14-8. basecalc — the Usage routine
/* Print message to stderr and exit */
Usage ()
{
fprintf (stderr,
"%s: [-iconic] [-unsigned] [-hex|x|dec|oct|binary]\
[-display <display>] [-geometry <geometrystring>]\
[-iconGeometry <icongeometrystring>\n",
calcName ? calcName : "basecalc");
exit (1);
}Read now
Unlock full access