|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.esri.arcgis.framework.ColorSelector
public class ColorSelector
Esri Color Selector object.
The ColorSelector is a dialog box that can be used to create new color objects. The dialog presents slider bars and check boxes that can be used to precisely set the properties of the new color.
Constructor Summary | |
---|---|
ColorSelector()
Constructs a ColorSelector using ArcGIS Engine. |
|
ColorSelector(Object obj)
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts. ColorSelector theColorSelector = (ColorSelector) obj; |
Method Summary | |
---|---|
boolean |
doModal(int hWnd)
Show the browser. |
boolean |
equals(Object o)
Compare this object with another |
static String |
getClsid()
getClsid. |
IColor |
getColor()
Color edited by the browser. |
int |
hashCode()
the hashcode for this object |
void |
initPopupPosition(int parentLeft,
int parentTop,
int parentRight,
int parentBottom,
boolean aboveParent)
Initialize Popup Position. |
void |
setColor(IColor color)
Color edited by the browser. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.esri.arcgis.interop.RemoteObjRef |
---|
getJintegraDispatch, release |
Constructor Detail |
---|
public ColorSelector() throws IOException, UnknownHostException
IOException
- if there are interop problems
UnknownHostException
- if there are interop problemspublic ColorSelector(Object obj) throws IOException
ColorSelector theColorSelector = (ColorSelector) obj;
obj
to ColorSelector
.
obj
- an object returned from ArcGIS Engine or Server
IOException
- if there are interop problemsMethod Detail |
---|
public static String getClsid()
public boolean equals(Object o)
equals
in class Object
public int hashCode()
hashCode
in class Object
public void setColor(IColor color) throws IOException, AutomationException
Set the Color property to an existing IColor object—the type of coclass you use will determine what options the dialog displays for editing the colors (see the pictures in the ColorBrowser topic).
The following code creates an intial color to show in the color browser, displays the color browser, and then sets a new color to the selected color in the color browser. You would get m_app from the hook in ICommand::OnCreate().
setColor
in interface IColorBrowser
color
- A reference to a com.esri.arcgis.display.IColor (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public IColor getColor() throws IOException, AutomationException
Set the Color property to an existing IColor object—the type of coclass you use will determine what options the dialog displays for editing the colors (see the pictures in the ColorBrowser topic).
getColor
in interface IColorBrowser
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public boolean doModal(int hWnd) throws IOException, AutomationException
To display the dialog box, you should call the DoModal method. The method takes one parameter, a handle to the Application object of the ArcMap framework.
The DoModal method returns a Boolean—you should check the result to determine if the user intended to cancel the action (the result is False) or click OK (the result is True).
doModal
in interface IColorBrowser
hWnd
- The hWnd (A COM typedef) (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.public void initPopupPosition(int parentLeft, int parentTop, int parentRight, int parentBottom, boolean aboveParent) throws IOException, AutomationException
The InitPopupPosition method can be used to set the initial display location of the dialog box in screen coordinates.
initPopupPosition
in interface IColorSelector
parentLeft
- The parentLeft (in)parentTop
- The parentTop (in)parentRight
- The parentRight (in)parentBottom
- The parentBottom (in)aboveParent
- The aboveParent (in)
IOException
- If there are interop problems.
AutomationException
- If the ArcObject component throws an exception.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |