NSTextView's drawViewBackgroundInRect: and selection
NSTextView's drawViewBackgroundInRect: and selection
- Subject: NSTextView's drawViewBackgroundInRect: and selection
- From: Keith Blount <email@hidden>
- Date: Sat, 7 May 2005 04:17:09 -0700 (PDT)
- Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys
Hello,
I have a custom subclass of drawViewBackgroundInRect:
that draws rounded rectangles around given ranges of
text to indicate that they have a note associated with
them.
However, because I draw these rects in
drawViewBackgroundInRect:, whenever I select text that
has a custom rect around it, the blue selection
overdraws it completely, which looks odd. But calling
the code in drawRect: doesn't make much sense either,
because the rects need to be drawn behind the text.
I thought I would just be able to set the selected
text attributes so that the background colour was
transparent, but this doesn't seem to work (the alpha
value has weird effects on the selected text colour).
Does anybody know the best way to handle this?
Many thanks in advance,
Keith
__________________________________
Do you Yahoo!?
Yahoo! Mail - Find what you need with new enhanced search.
http://info.mail.yahoo.com/mail_250
_______________________________________________
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