gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Simple printing


From: Adam Fedor
Subject: Re: Simple printing
Date: Mon, 14 May 2001 11:18:46 -0600

Fred Kiefer wrote:
> 
> I was thinking of operations that report back the state of the drawing
> context. E.g. methods as [DPScurrentgray:] where the frontend asks the
> backend its internal state, we have about twenty of them, but even for
> one we need to keep track of a stack of gstates to report back the
> current value correctly. We may either drop all those interfaces as a
> whole or decide that they are not important for printing (Which would
> force code to be implemented different when drawing on screen than when
> printing). Or we have to implement them for the printing context too.
> 
You'll have to point out where we actually do this during drawing in the
current code, I couldn't find any examples. FYI, it's not valid to get
state information from a Text context(*) in a true DPS backend - so we
have the same problem there.


> This architecture would not only be usable for xgps and printing, but
> would come handy for any non-PostScript backend. The overhead would be
> rather small, as we would need about one extra method call per drawing
> operation (where the operation itself is much heavier) and nothing for
> most state operations.

Well I think this would be a useful thing to do anyway to make it a
little easier to port to other backends.


(*) Just to point out how you do printing in DPS. You create a text
context and set it as
the current contect:

ctxt = DPSCreateTextContext(text_output_function, error_output_function)
DPSSetContext(ctxt)

and all drawing code goes to the 'text_output_function' in ASCII coded
PostScript.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]