discuss-gnustep
[Top][All Lists]
Advanced

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

Re: Backend Docs (Was: GNUstep Window Manager (was RE: Idea))


From: Adam Fedor
Subject: Re: Backend Docs (Was: GNUstep Window Manager (was RE: Idea))
Date: Mon, 08 Jan 2001 11:11:28 -0700

Richard Frith-Macdonald wrote:
> 
> On Monday, January 8, 2001, at 07:09 AM, Sungjin Chun wrote:
> 
> > Hi,
> >
> > That's the problem; we have almost no documentation or
> > information on how to make a backend system and how
> > currnet backend system works. Yes, I can refer the source code
> > but it's too much for me T_T. Any suggestion or correction?
> 

Your right, there is basically no documentation. I have a short
desription I'm attaching, but we really need better docs (parhaps this
would also help define the API better).

> 
> The header files to look at are
> NSGraphicsContext.h (the claass) and PSOperators.h, DPSOperators.h (inline 
> functions)
> 

Also a few things in GSWraps.h, plus some font management functions
(GSFontInfo.h)
The backend is basically an implementation of the routines in
NSGraphicsContext.h (gui/Headers/gnustep/gui/NSGraphicsContext.h),
functions in NSGraphics.h (gui/Headers/gnustep/gui/NSGraphics.h), Font
management (gui/Headers/gnustep/gui/GSFontInfo.h), and
a few other miscellanoues things.

The graphics routines are modeled after PostScript, so a little
understanding of PostScript would be good, although most PostScript
functions have obvious meanings (i.e. PSmoveto).

Look in the xgps backend for examples of how to implement things
(although it is very X-Windows based):

XGContext.m: Initializes the graphics system and does some basic
implementation of PostScript functions (although it passes off most of
the work to XGGState.m) of NSGraphicContext.

XGGState.m: Does most of the graphics work. a 'gstate' is an
encapsulation of the current graphics information, such as current
drawing color, line width, clipping rectangles, etc.

SharedX/XGContextWindow.m: Implements the basic window creation
routines of NSGraphicContext, plus other things such as cursors, mouse.

SharedX/XGContextEvent.m: Implements event handling routines of
NSGraphicContext.

XGDrawingEngine.m: Implements functions in NSGraphics.

XGFont, XGFontManager: font management stuff, XGFont actually implements
the backend part of GSFontInfo.

Everything else in the backend are just support routines to help
implement all this stuff


reply via email to

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