Re: NSSliderCell does not use drawBarInside:flipped:?
Re: NSSliderCell does not use drawBarInside:flipped:?
- Subject: Re: NSSliderCell does not use drawBarInside:flipped:?
- From: Ryan Stevens <email@hidden>
- Date: Tue, 14 Jun 2005 10:05:50 -0700
Here's what my drawInteriorWithFrame:inView: looks like ..
[self drawBarInside:cellFrame flipped:[controlView
isFlipped]];
[self drawKnob];
Not sure if I'm missing out on some "free" stuff this way but it
seems to work well enough for me. *shrug*
On Jun 13, 2005, at 5:08 PM, Andreas Mayer wrote:
The documentation for NSSliderCell's drawBarInside:flipped: says:
"Draws the slider’s bar—but not its bezel or knob—inside aRect.
aRect is the bounds of the bar, not its interior rect.
The flipped argument indicates whether the cell’s control view—that
is, the NSSlider or NSMatrix associated with the NSSliderCell—has a
flipped coordinate system.
You should never invoke this method explicitly. It’s included so
you can override it in a subclass."
So I did overwrite drawBarInside:flipped:.
But the (old) slider track gets drawn anyway.
Unless I made a really stupid mistake, this seems to be a bug in
NSSliderCell where the track is not drawn in drawBarInside:flipped:
but directly in drawInteriorWithFrame:inView: instead.
Can anyone confirm this one way or the other?
(I worked around this problem by drawing exactly over the original
track. This is not really a solution but I didn't want to
completely re-implement drawInteriorWithFrame:inView: for
NSSliderCell.)
Andreas
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden