Citát Gregory John Casamento <[EMAIL PROTECTED]>: <snip>
> Themes in GNUstep are a very different beast than in GNOME or KDE. > Typically, > themes override certain portions of the drawing code in GNUstep to achieve a > new look. GNUstep is a complex piece of work and the creation of a new look > for it is, by no means, a simple task. > I thought that theme support is included in GUI by a class and creating a theme is just replacing only that class, is not that true? AFAIR, there was such class created for this purpose, or not? If that is not true, then I think that GUI/AppKit should be changed to support themes natively by delegating drawing of UI elements to some class. Having a theme bundle to replace drawing methods by poseAs: can be considered a hack. We are in OO world, then it should be not too difficult to have a class with methods more methods. Currently there is GSDrawFunctions with methods: + (NSRect) drawButton: (NSRect)border : (NSRect)clip; + (NSRect) drawDarkButton: (NSRect)border : (NSRect)clip; + (NSRect) drawDarkBezel: (NSRect)border : (NSRect)clip; + (NSRect) drawLightBezel: (NSRect)border : (NSRect)clip; + (NSRect) drawGrayBezel: (NSRect)border : (NSRect)clip; + (NSRect) drawWhiteBezel: (NSRect)border : (NSRect)clip; + (NSRect) drawGroove: (NSRect)border : (NSRect)clip; + (NSRect) drawFramePhoto: (NSRect)border : (NSRect)clip; + (NSRect) drawGradientBorder: (NSGradientType)gradientType inRect: (NSRect)border withClip: (NSRect)clip; If it was extended by more complex methods such as: + drawScrollerKnobInRect:clip: + drawScrollerArrowInRect:clip: + drawPopUpInRect:clip: + drawTableHeaderCellWithTitle:rect:clip: + drawTabsWithLabels:selectedTabIndex:inRect:clip: ... put all GNUStep UI elements/parts here. Even more complex methods should be here, if possible: + drawColumn:ofBrowser:inRect:clip: Then GUI should not use drawing by using bezier paths nor DPS operators, it should use ONLY functions from the "theme class". With this, complete themability can be achieved without it being a hack, as it is now. This desing is much cleaner and straightforward. Theme creator does not have to dig into the AppKit classes to find out "what should be overriden to make the theme work", moreover the theme developer will not end by uncomplete theme, as he knows everything that he should implement. Stefan Urbanek _______________________________________________ Discuss-gnustep mailing list Discuss-gnustep@gnu.org http://lists.gnu.org/mailman/listinfo/discuss-gnustep