Re: Checkbox as title for NSBox
Re: Checkbox as title for NSBox
- Subject: Re: Checkbox as title for NSBox
- From: email@hidden
- Date: Wed, 22 May 2002 08:45:46 -0700
Doug Brown wrote:
|Thank you so much! That's working a lot better. I'll experiment some
|more and see if I can track down a way to get the mouse tracking
|working. I still have that weird display bug - I have a screenshot at:
|
|
http://homepage.mac.com/macg3/weirdbug.jpg
Ah, now that I see it, I understand what you're talking about. (A picture is *so* helpful sometimes.) What the picture tells me is that the "boxed" checkbox isn't disabled, because the label (and the checkbox itself) would be "dimmed" otherwise. (Try setting the non-box checkbox--the one in the lower-left corner of your picture--to disabled and you'll see what I mean.) What appears to be happening is that you're getting the "graphite appearance" checkbox instead of the "blue appearance" one. (Why this would be, I haven't a clue. But I don't think the thing's actually disabled. To look into it, I'd start poking around the setControlTint: method. On the other hand, if it *is* disabled, despite the lack of dimming, that might explain why tracking isn't working.)
|By the way, by putting your code in both mouseDown: and mouseDragged:
|your tracking code seems to work great, if we could get it to draw as
|hilited when it's inside the rect, which I will experiment with.
What I'm wondering is why the NSCell mouse-tracking code doesn't seem to work. I tried it first, and went to the ultra-stripped-down stuff I posted because the NSCell code wasn't doing anything that I could see. When I've used the NSCell methods elsewhere, they work just as you'd want. But here, they seem to do nothing. Seemingly, the NSCell code assumes something that isn't true here. (My guess: that it's being called from an NSControl, which NSBox isn't.) Perhaps someone with access to the AppKit source code can take a look and tell us.
Glen Fisher
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.