Get Toolbar End-Gradient Color
Get Toolbar End-Gradient Color
- Subject: Get Toolbar End-Gradient Color
- From: Brian Amerige <email@hidden>
- Date: Wed, 25 Jul 2007 12:41:16 -0400
Hi all,
Is it possible to get the end-gradient color of a unified toolbar?
This would be the last pixel (heightwise, furthest the bottom) of the
toolbar.
Here's the context:
I'm using PSMTabBarControl (http://www.positivespinmedia.com/dev/
PSMTabBarControl.html, updated code at the Google Code repo), and the
color of the tabs is bound to the backgroundColor of a window with a
unified title/toolbar. In this context, to maintain continuity, the
window backgroundColor must be set to the end-gradient color of my
unified toolbar. When the window is main and key, this end gradient
color is NSColor's secondarySelectedControlColor. On unthemed
systems, this provides an appealing look:
http://brianamerige.com/perm/ProperUnified.png
The catch, however, is that if any user has a theme applies which
modifies the appearance of the unified toolbar at all (UNO, for
example), the continuity between the toolbar and tabs is broken.
(http://brianamerige.com/perm/ThemedUnified.png) I've spent a great
deal of time debating whether or not it's even my responsibility to
fix such an issue, as I suppose that is the price one might pay for
using custom themes, but for the sake of curiosity, I'd like to see
if I can get it working properly.
All in all, it's easy to describe how (get the color of the toolbar
end-gradient) to do this, but it's not so easy (or maybe it is, and
it's just not obvious to me) to perform programmatically.
Any tips are appreciated!
Brian Amerige: Software at Extendmac
email@hidden | aim - applejustworks
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden