Re: About Default* resources.

"Igor V. Melichev" <[email protected]>
Newsgroups gmane.comp.printing.ghostscript.patches
Message-ID <[email protected]>
> From: "Alex Cherepanov" <[email protected]>
> To: "Igor V. Melichev" <[email protected]>
> Cc: <[email protected]>
> Sent: Monday, October 20, 2003 5:26 PM
> Subject: Re: [gs-code-review] About Default* resources.


> > At least ColorRendering resources supplied with CPSI don't do so.
> Not true.

I've got a resource file like this :

[file beg]
%!PS-Adobe-3.0 Resource-ColorRendering
%%Title: Color rendering for color monitor
% (1.8 gamma, D65 white point, Apple phosphors)

% Copyright (c) 1992-1993 Adobe Systems Incorporated.
% All rights reserved.
[skip]
% Original version: Ivor Durham: Tue May  4 20:00:50 1993
%%BeginResource: colorrendering AppleMonitor
<<
[skip]
>> /AppleMonitor exch /ColorRendering defineresource pop
%%EndResource
[file end]

I replaced the propertiary information with [skip].

I execute :

    /AppleMonitor /ColorRendering resourcestatus pstack
    /AppleMonitor /ColorRendering findresource gcheck =

Got :

    true
    -1
   1
   true

Thus your statement 'Not true" is not true.

I don't know what Adobe does while loading such resources.
If we put setglobal into our resource files, we'll get an incompatibility
when an user copies Adobe resource files to GS resource directory.

Then I execute :

    /DefaultGray /ColorSpace resourcestatus pstack
    /DefaultGray /ColorSpace findresource gcheck =

Got :

    true
    -1
   0
   true

So DefaultGray was defined by an explicit defineresource in the prelude.

However we need to know whether DefaultGray was defined by a document.
This was Dan's request, and Raph approved.
To satisfy it I moved DefaultGray to gs/Resource .
This implementation isn't equivalent to Adobe.
I don't know how to satisfy both Dan and Adobe without a big effort.
I don't know whether the 'setglobal' must put into the resource file or into
the color space substitution code in gs/lib (handled by Dan),
or into both or into none.

If you find a practical leading example, please let me know.

Igor.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.