RE: Color Picker implementation error
RE: Color Picker implementation error
- Subject: RE: Color Picker implementation error
- From: Vinay Prabhu <email@hidden>
- Date: Wed, 7 Jun 2006 11:31:51 +0530
- Importance: Normal
>It sounds like what you really want is to integrate the NSColorPanel
>Color Wheel into an existing window so it won't popup as a separate
>panel. I doubt there is a way to do this with the standard
>NSColorPanel. I don't suppose it would be too hard to write your
>own... display a color wheel graphic and then come up with a color
>based on the position of a picker (I wouldn't bother trying to read
>the screen color of the actual wheel graphic).
Yes, I want to integrate the NSColorPanel Color Wheel into an existing
window so it won't popup as a separate panel.
How does, NSColroPanel has implemented the Color Wheel view?
I think NSColorPanel makes use of a class, which will draw the color
spectrum and implement the
color picker based on the position of the mouse click.
Does that class is exposed? so that we can declare a class which inherits
from that class
and implement the color wheel pane in the existing window.
-----Original Message-----
From: George Orthwein [mailto:email@hidden]
Sent: Tuesday, June 06, 2006 9:57 PM
To: Vinay Prabhu
Cc: email@hidden
Subject: Re: Color Picker implementation error
What exactly do you want to do?
On Jun 6, 2006, at 9:30 AM, Vinay Prabhu wrote:
> I am trying to customize the color picker which I can be used in the
> application.
> I have created a cocoa bundle with the class that implements
> NSColorPickingDefault and Custom.
> Also placed the bundle in the proper location.
That will let you add a custom pane to the Color Panel:
http://developer.apple.com/documentation/Cocoa/Conceptual/DrawColor/
Tasks/AddingColorPickers.html
Google "color picker source cocoa" for some code samples. Here's one:
http://wafflesoftware.net/hexpicker/
It sounds like what you really want is to integrate the NSColorPanel
Color Wheel into an existing window so it won't popup as a separate
panel. I doubt there is a way to do this with the standard
NSColorPanel. I don't suppose it would be too hard to write your
own... display a color wheel graphic and then come up with a color
based on the position of a picker (I wouldn't bother trying to read
the screen color of the actual wheel graphic).
But of course, if the standard NSColorPanel will work at all, it will
be easier for you and more consistent for the user.
Hope that helps,
George
The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s)and may contain confidential or privileged information. If you are not the intended recipient, please notify the sender or email@hidden
_______________________________________________
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