X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=blobdiff_plain;f=src%2Fpdf2pdf.c;h=180302963068238454df4682194dd7ada2c043af;hp=faa8d1b6dc415c3c3db3bb7237196c70356bd891;hb=727449f065760e1d99735f44638c25678cd8bc52;hpb=9188f342f67f399dbb7857dd1970ab44a8c24138 diff --git a/src/pdf2pdf.c b/src/pdf2pdf.c index faa8d1b..1803029 100644 --- a/src/pdf2pdf.c +++ b/src/pdf2pdf.c @@ -125,13 +125,16 @@ int args_callback_option(char*name,char*val) { return 0; } -struct options_t options[] = -{{"o","output"}, - {"q","quiet"}, - {"V","version"}, - {"s","set"}, - {"p","pages"}, - {0,0} +static struct options_t options[] = { +{"h", "help"}, +{"v", "verbose"}, +{"p", "pages"}, +{"X", "width"}, +{"Y", "height"}, +{"s", "set"}, +{"o", "output"}, +{"V", "version"}, +{0,0} }; int args_callback_longoption(char*name,char*val) { @@ -168,8 +171,20 @@ int args_callback_command(char*name, char*val) { return 0; } -void args_callback_usage(char*name) +void args_callback_usage(char *name) { + printf("\n"); + printf("Usage: %s \n", name); + printf("\n"); + printf("-h , --help Print short help message and exit\n"); + printf("-v , --verbose Be verbose. Use more than one -v for greater effect.\n"); + printf("-p , --pages Pages to convert\n"); + printf("-X , --width Make sure the output pdf is pixels wide\n"); + printf("-Y , --height Make sure the output pdf is pixels high\n"); + printf("-s , --set = Set to \n"); + printf("-o , --output Write output to file .\n"); + printf("-V , --version Print version info and exit\n"); + printf("\n"); } int main(int argn, char *argv[])