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

Re: [XaraXtreme-dev] Moving to Cairo (was Ping)



Alex Bligh wrote:

I am proposing to modify the code base so it internally can either
call Cairo to draw, or to call GDraw, with the switch probably being
made at the GDrawContext level, or (possibly) through a derived
class of GRenderRegion though I expect because of the deep class hierarchy
there that the latter is going to be harder. As I understand what
Carl has done, he's produced a hacked up version of GDrawContext
(or XaDrawContext or whatever it is called today) which calls Cairo
not GDraw. This could just as easily be a separate class. And we can
tidy up the class interface to GDrawContext (rather than the CDraw
'C' API) so it makes fewer assumption about the underlying drawing
engine relatively easily, I think.

Alex

Creating a new RenderRegion-derived class is probably the "correct" way to do it and that would allow you to use the existing RRCaps mechanism to express the capabilities of the new class to the rest of the system.

Phil