public class LineTool extends Object
setDefaultProperties()
can be used to set the
Annotation
properties to this Tool's default properties.
The Tool's property values can be retrieved and initialized with the methods
toXMLString()
and setFromXML()
in the
AnnotationTools
class. Please see
AnnotationTools
.
Modifier and Type | Field and Description |
---|---|
static int |
SHOW_NOTHING |
static int |
SHOW_POPUP |
static int |
SHOW_PROPS_DIALOG |
Constructor and Description |
---|
LineTool() |
Modifier and Type | Method and Description |
---|---|
static BasicStroke |
getDefaultBasicStroke()
Gets the default stroke.
|
static Color |
getDefaultBorderColor()
Returns the color used for the line when a new annotation is created.
|
static double |
getDefaultBorderWidth2D()
Returns the default line width, used when new annotations are created.
|
static Color |
getDefaultFillColor()
Return the default fill color.
|
static String |
getDefaultLineEndStyle()
Gets the default line end style used when creating new line annotations.
|
static String |
getDefaultLineStartStyle()
Gets the default line start style used when creating new line annotations.
|
static int |
getDefaultTransparency()
Gets the default transparency value that is used when new annotations are created.
|
static Dimension |
getMinimumAnnotSize()
Gets the minimum size for the annotations created with this Tool.
|
static int |
getShowOption()
Returns the option for what this Tool should do after it creates the
annotation.
|
static boolean |
isShowPropDialog()
Deprecated.
|
static boolean |
isToolSticky()
Returns a flag indicating if this tool is sticky.
|
static void |
setDefaultBasicStroke(BasicStroke defaultStroke)
Sets the default stroke.
|
static void |
setDefaultBorderColor(Color defaultBorderColor)
Sets the default line color.
|
static void |
setDefaultBorderWidth2D(double defaultBorderWidth)
Sets the line width used when a new annotation is created.
|
static void |
setDefaultFillColor(Color defaultFillColor)
Sets the default fill color.
|
static void |
setDefaultLineEndStyle(String defaultLineEndStyle)
Possible values are:
ShapeAnnotation.LE_NONE_STR
ShapeAnnotation.LE_SQUARE_STR
ShapeAnnotation.LE_CIRCLE_STR
ShapeAnnotation.LE_DIAMOND_STR
ShapeAnnotation.LE_OPENARROW_STR
ShapeAnnotation.LE_CLOSEDARROW_STR
|
static void |
setDefaultLineStartStyle(String defaultLineStartStyle)
Possible values are:
ShapeAnnotation.LE_NONE_STR
ShapeAnnotation.LE_SQUARE_STR
ShapeAnnotation.LE_CIRCLE_STR
ShapeAnnotation.LE_DIAMOND_STR
ShapeAnnotation.LE_OPENARROW_STR
ShapeAnnotation.LE_CLOSEDARROW_STR
|
static void |
setDefaultProperties(Line line)
This is a convenience method to set the Line properties to the LineTool
default properties.
|
static void |
setDefaultTransparency(int defaultTransparency)
Sets the default transparency values when new annotations are created.
|
static void |
setMinimumAnnotSize(Dimension minimumAnnotSize)
Sets the minimum size for the annotations created with this Tool.
|
static void |
setShowOption(int option)
Sets the option for what this Tool should do after it creates the
annotation.
|
static void |
setShowPropDialog(boolean showPropDialog)
Deprecated.
|
static void |
setToolSticky(boolean toolSticky)
Sets the flag that indicates whether this tool is sticky or not.
|
public static int SHOW_NOTHING
public static int SHOW_PROPS_DIALOG
public static int SHOW_POPUP
public static void setDefaultProperties(Line line)
public static int getDefaultTransparency()
public static void setDefaultTransparency(int defaultTransparency)
defaultTransparency
- The new default transparency valuepublic static String getDefaultLineStartStyle()
public static void setDefaultLineStartStyle(String defaultLineStartStyle)
ShapeAnnotation.LE_NONE_STR
ShapeAnnotation.LE_SQUARE_STR
ShapeAnnotation.LE_CIRCLE_STR
ShapeAnnotation.LE_DIAMOND_STR
ShapeAnnotation.LE_OPENARROW_STR
ShapeAnnotation.LE_CLOSEDARROW_STR
defaultLineStartStyle
- the defaultLineStartStyle to setpublic static String getDefaultLineEndStyle()
public static void setDefaultLineEndStyle(String defaultLineEndStyle)
ShapeAnnotation.LE_NONE_STR
ShapeAnnotation.LE_SQUARE_STR
ShapeAnnotation.LE_CIRCLE_STR
ShapeAnnotation.LE_DIAMOND_STR
ShapeAnnotation.LE_OPENARROW_STR
ShapeAnnotation.LE_CLOSEDARROW_STR
defaultLineEndStyle
- the defaultLineEndStyle to setpublic static Color getDefaultBorderColor()
public static void setDefaultBorderColor(Color defaultBorderColor)
defaultBorderColor
- The new default line color.public static Color getDefaultFillColor()
public static void setDefaultFillColor(Color defaultFillColor)
defaultFillColor
- The new default fill colorpublic static double getDefaultBorderWidth2D()
public static void setDefaultBorderWidth2D(double defaultBorderWidth)
defaultBorderWidth
- The new default line widthpublic static BasicStroke getDefaultBasicStroke()
public static void setDefaultBasicStroke(BasicStroke defaultStroke)
defaultStroke
- The new default strokepublic static boolean isToolSticky()
public static void setToolSticky(boolean toolSticky)
toolSticky
- The new value of the sticky flag.@Deprecated public static boolean isShowPropDialog()
@Deprecated public static void setShowPropDialog(boolean showPropDialog)
showPropDialog
- the showPropDialog to setpublic static int getShowOption()
SHOW_NOTHING
, SHOW_PROPS_DIALOG
, or
.public static void setShowOption(int option)
SHOW_NOTHING
, SHOW_PROPS_DIALOG
, or
.option
- public static Dimension getMinimumAnnotSize()
public static void setMinimumAnnotSize(Dimension minimumAnnotSize)
minimumAnnotSize
- the minimumAnnotSize to set