diff options
author | Robin Watts <Robin.Watts@artifex.com> | 2020-07-30 19:16:13 +0100 |
---|---|---|
committer | Robin Watts <Robin.Watts@artifex.com> | 2020-08-03 18:02:41 +0100 |
commit | bf6884134c244c4766d13c76264fa4372eab4056 (patch) | |
tree | ab1af05f3c1ae6b8f76545def0c41770701d71f0 /gpdl | |
parent | 49a4fede913a12a61fd6649898cf5999030f4b69 (diff) | |
download | ghostpdl-bf6884134c244c4766d13c76264fa4372eab4056.tar.gz |
gsapi_set_param improvements.
Allow for a 'parsed' param type; this leverages the functions in
gsparaml.c to parse an input string into a param list, coping
with dictionaries and arrays.
We update those functions to improve behaviour on more exotically
formed numbers ("- 0.3e-10" etc), on 'tricksy' inputs (e.g.
"<< /Foo (>>) >>" etc) and to cope without relying on whitespace
(e.g. "<</Foo/Bar/Baz[1 0]/Fizz<1234>/Bang(A)>>" etc).
Update pl_implementation set_param entrypoint so that the language
interface itself is based upon param lists, rather than typed
params.
Update both implementations of gsapi_set_params so that if
we are too early in the setup process stuff goes into the list
and is held until we have devices/languages to pass it to. Also
add a flag to allow for 'more to come' so that we can effectively
set multiple params at once.
Diffstat (limited to 'gpdl')
-rw-r--r-- | gpdl/psitop.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/gpdl/psitop.c b/gpdl/psitop.c index ed2cb4e64..8d8046b59 100644 --- a/gpdl/psitop.c +++ b/gpdl/psitop.c @@ -378,13 +378,11 @@ ps_impl_get_device_memory(pl_interp_implementation_t *impl) static int ps_impl_set_param(pl_interp_implementation_t *impl, - pl_set_param_type type, - const char *param, - const void *val) + gs_param_list *plist) { ps_interp_instance_t *psi = (ps_interp_instance_t *)impl->interp_client_data; - return psapi_set_param(psi->psapi_instance, type, param, val); + return psapi_set_param(psi->psapi_instance, plist); } static int |