All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.sas.graphics.components
Class BrushModel

    com.sas.graphics.components.BrushModel

    public class BrushModel

A BrushModel encapsulates the set of display properties presented when selection is performed. Selection (when applicable) is performed by clicking on a select-able element or by clicking and dragging to create create a brush. When a brush is created it can be moved by clicking inside the brush area and dragging to the desired location. Pressing the ctrl button while clicking or dragging on a non-selected element will add the new element to the set of selected elements.

Since:
  SAS 9.1

Constructor Summary
`BrushModel()`

Method Summary
`void` | `apply(BrushModel theOtherObject)` Utility method to convey properties contained in "theOtherObject" to this object.
`boolean` | `equals(java.lang.Object obj)` Determines whether another object is equal to this `BrushModel`.
`java.awt.Color` | `getSelectionAccentColor()` Returns the secondary color used to indicate selection.
`java.awt.Color` | `getSelectionColor()` Returns the primary color used to indicate selection.
`int` | `hashCode()` Computes the hash code for this `BrushModel`.
`boolean` | `isSelectionAllowed()` Returns whether or not selection can be performed via this graph.
`boolean` | `isSelectOnGrow()` Returns whether or not selection should happen as the brush area is being sized.
`boolean` | `isSelectOnMove()` Returns whether or not selection should happen as the brush area is being moved.
`void` | `setSelectionAccentColor(java.awt.Color newSelectionAccentColor)` Sets the secondary color used to indicate selection.
`void` | `setSelectionAllowed(boolean newSelectionAllowed)` Set whether or not selection can be performed via this graph.
`void` | `setSelectionColor(java.awt.Color newSelectionColor)` Sets the primary color used to indicate selection.
`void` | `setSelectOnGrow(boolean newSelectOnGrow)` Set whether or not selection should happen as the brush area is being sized.
`void` | `setSelectOnMove(boolean newSelectOnMove)` Set whether or not selection should happen as the brush area is being moved.

Methods inherited from class com.sas.graphics.components.ModelBase
`addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, removePropertyChangeListener, setContainedModel`

Constructor Detail

### BrushModel

    public BrushModel()

Method Detail

### apply

    public void apply(BrushModel theOtherObject)

  Utility method to convey properties contained in "theOtherObject" to this object.

  Note: Contained "models" (i.e. properties that are subclasses of ModelBase) will in turn be called on to convey their properties to the like contained models in the other object. In that respect this can be considered a "tree" type copy.

  Also Note: This is a deep copy. Thus after the copy, mutable properties will not be shared by the two instances.

  Parameters:
    `theOtherObject` - properties applied to this instance

### setSelectOnGrow

    public void setSelectOnGrow(boolean newSelectOnGrow)

  Set whether or not selection should happen as the brush area is being sized.

  Parameters:
    `newSelectOnGrow` - true means to perform selections as the brush is sized.
  See Also:
    `isSelectOnGrow()`

### isSelectOnGrow

    public boolean isSelectOnGrow()

  Returns whether or not selection should happen as the brush area is being sized.

  See Also:
    `setSelectOnGrow(boolean)`

### setSelectOnMove

    public void setSelectOnMove(boolean newSelectOnMove)

  Set whether or not selection should happen as the brush area is being moved.

  Parameters:
    `newSelectOnMove` - true means to perform selections as the brush is moved.
  See Also:
    `isSelectOnMove()`

### isSelectOnMove

    public boolean isSelectOnMove()

  Returns whether or not selection should happen as the brush area is being moved.

  See Also:
    `setSelectOnMove(boolean)`

### setSelectionAllowed

    public void setSelectionAllowed(boolean newSelectionAllowed)

  Set whether or not selection can be performed via this graph.

  Parameters:
    `newSelectionAllowed` - true means selection is allowed via this view other wise it is not.
  See Also:
    `isSelectionAllowed()`

### isSelectionAllowed

    public boolean isSelectionAllowed()

  Returns whether or not selection can be performed via this graph.

  See Also:
    `setSelectionAllowed(boolean)`

### setSelectionColor

    public void setSelectionColor(java.awt.Color newSelectionColor)
                           throws java.lang.IllegalArgumentException

  Sets the primary color used to indicate selection. The selectionAccentColor (when applicable) appears as a secondary indicator on selected items. The selectionColor usually appears as a filled area if the selected item. In the absence of a fill area the selectionColor typically appears as the primary color used to draw the item.

  In the case of selected text the selectionColor appears as the text's background color.

  The default value is java.awt.SystemColor.textHighlight.

  Parameters:
    `newSelectionColor` - the primary color used to indicate selection.
  Throws:
    `java.lang.IllegalArgumentException` - is thrown for null parameter.
  See Also:
    `getSelectionColor()`

### getSelectionColor

    public java.awt.Color getSelectionColor()

  Returns the primary color used to indicate selection.

  Returns:
    the primary color used to indicate selection.
  See Also:
    `setSelectionColor(java.awt.Color)`

### setSelectionAccentColor

    public void setSelectionAccentColor(java.awt.Color newSelectionAccentColor)
                                 throws java.lang.IllegalArgumentException

  Sets the secondary color used to indicate selection. The selectionAccentColor (when applicable) appears as a secondary indicator on selected items. The selectionAccentColor typically appears on the outline of selected items.

  In the case of selected text the selectionAccentColor appears as the text's foreground color.

  The default value is java.awt.SystemColor.textHighlightText.

  Parameters:
    `newSelectionAccentColor` - the secondary color used to indicate selection.
  Throws:
    `java.lang.IllegalArgumentException` - is thrown for null parameter.
  See Also:
    `getSelectionAccentColor()`

### getSelectionAccentColor

    public java.awt.Color getSelectionAccentColor()

  Returns the secondary color used to indicate selection.

  Returns:
    the secondary color used to indicate selection.
  See Also:
    `setSelectionAccentColor(java.awt.Color)`

### equals

    public boolean equals(java.lang.Object obj)

  Determines whether another object is equal to this `BrushModel`.

  The result is `true` if and only if the argument is not `null` and is a `BrushModel` object that has the same property values as this object.

  Overrides:
    `equals` in class `ModelBase`
  Parameters:
    `obj` - the object to test for equality with this `BrushModel`
  Returns:
    `true` if the objects are the same; `false` otherwise.

### hashCode

    public int hashCode()

  Computes the hash code for this `BrushModel`.

  Overrides:
    `hashCode` in class `ModelBase`
  Returns:
    a hash code value for this object.

All Libraries | This Library | Package | Class | Use | Tree | Deprecated | Index | Grand Index | Help
|  | Components |
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2009 SAS Institute Inc. All Rights Reserved.