gnustep-dev
[Top][All Lists]
Advanced

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

Re: [Gnustep-cvs] gnustep/core/gui Headers/AppKit/NSCell.h Source...


From: Quentin Mathé
Subject: Re: [Gnustep-cvs] gnustep/core/gui Headers/AppKit/NSCell.h Source...
Date: Sat, 18 Sep 2004 00:17:37 +0200

Le 16 sept. 04, à 17:14, Fred Kiefer a écrit :

Quentin Mathé wrote:
CVSROOT:        /cvsroot/gnustep
Module name:    gnustep
Branch:         
Changes by:     Quentin Mathé <address@hidden>    04/08/30 21:33:17
Modified files:
core/gui/Headers/AppKit: NSCell.h core/gui/Source: NSButtonCell.m NSCell.m NSToolbarItem.m core/gui : ChangeLog Log message:
        Fixed the toolbar layout problem introduced by NSButtonCell changes

Hi Quentin,

Hi Fred,

could you please explain why the new draw methods for GSToolbarButtonCell are needed? I did not compare line by line, but would expect that the drawing code in NSButtonCell should be sufficent for this, when the attributes are set up correctly. But I may be missing the whole point here.

Well, the new draw methods used by GSToolbarButtonCell are needed, because the last Alexander changes to NSButtonCell make the toolbar ugly because of the toolbar item's especially low label position now when you use NSImageAbove mode for the image position (which is set for GSToolbarButton). Moreover GSToolbarBackView, which is equivalent of the GSToolbarButton when you use a custom view with the toolbar item, relies on its layout code for the label, then each time NSButtonCell text layout is changed, the toolbar item's label layout code is broken between the toolbar items which are using a view and the ones which aren't. Conclusion : because Alexander doesn't think it is a good idea (for backward compatibility reason) to change the button cell text layout to have a larger margin between the border and the title, I decided to roll my own layout for the toolbar items label which as a side effect eliminates the code synchronisation issue between GSToolbarBackView and NSButtonCell.

Quentin.

--
Quentin Mathé
address@hidden





reply via email to

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