Mercurial > hg > octave-nkf
comparison scripts/plot/util/private/__print_parse_opts__.m @ 18748:cdc16fbb513f
Allow only Ghostscript devices when spooling to a printer (bug #41957)
* __print_parse_opts__.m: Allow only Ghostscript devices when spooling to a
printer.
author | Rik <rik@octave.org> |
---|---|
date | Fri, 28 Mar 2014 12:15:25 -0700 |
parents | d63878346099 |
children | 077575fe9a7e |
comparison
equal
deleted
inserted
replaced
18747:348f67886dc4 | 18748:cdc16fbb513f |
---|---|
333 arg_st.name = "-"; | 333 arg_st.name = "-"; |
334 else | 334 else |
335 error ("print: a file name may not specified when spooling to a printer") | 335 error ("print: a file name may not specified when spooling to a printer") |
336 endif | 336 endif |
337 if (! any (strcmp (arg_st.devopt, gs_device_list)) | 337 if (! any (strcmp (arg_st.devopt, gs_device_list)) |
338 || ! any (strcmp (arg_st.devopt, {"pswrite", "ps2write"}))) | 338 ## Only supported ghostscript devices |
339 ## Only postscript and supported ghostscript devices | 339 error ("print: format must be a valid Ghostscript format for spooling to a printer") |
340 error ("print: invalid format for spooling to a printer") | |
341 endif | 340 endif |
342 elseif (isempty (arg_st.name)) | 341 elseif (isempty (arg_st.name)) |
343 error ("print: an output file name must be specified") | 342 error ("print: an output file name must be specified") |
344 endif | 343 endif |
345 | 344 |