Re: NSRulerView background color
Subject : Re: NSRulerView background color
From: "Alan Smith" <email@hidden >
Date: Wed, 2 May 2007 12:16:24 -0400
Delivered-to: email@hidden
Delivered-to: email@hidden
Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=llnWUExLFmA34aU7HFxzJhDCJi06JRaplBJT3AQwrovEl+WYAkExndHfgP7k+QD/OvBKhQzWf1sZt5EGTJiz9K4rjWl4nqx2sMmaFdfRM1da0cjeHRf2Xx3G3PChRHm1C8c0GVEYY9uSQJCSMq+/+WCv3tiZ80L1vv5GM7fuahg=
Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=p/tUBzBFext16FGF/0verKiEDqaPf/YCSufXAsroEV0dIbbNwTnRMltCucVT5NlBiH66NSFmtMougg1fdPSgu7n8kN/vS0KvLjHdCdBgay1AU8Js4cEYB5ylKBH8mCj8zntJahAr3FVI097UBBggVxZKQmERecPBWXPWO5A3Gm0=
Hello Lorenzo,
It just so happens NSRulerView has the following method:
- (void)drawBackgroundInRect:(NSRect)rect;
It should suffice very nicely. Don't call super with this though, that
will mess it up. The below snippet should work fine.
- (void)drawBackgroundInRect:(NSRect)rect
{
[[NSColor colorWithCalibratedWhite: 0.85 alpha: 1.0] set];
[NSBezierPath fillRect: rect];
}
Have fun!
Peace, Alan
--
// Quotes from yours truly -------------------------
"You don't forget, you just don't remember."
"Maturity resides in the mind."
"Silence is the Universe's greatest gift."
"When the World realizes that religion really is unnecessary, then it
shall evolve."
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
http://lists.apple.com/mailman/options/cocoa-dev/email@hidden
This email sent to email@hidden
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2007 Apple Inc. All rights reserved.