|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.davisor.graphics.RenderAttributes
com.davisor.graphics.chart.LineRenderAttributes
com.davisor.graphics.chart.DataRenderAttributes
DataRenderAttributes represents data formatting attributes for chart rendering.
LineRenderAttributes super-class. See also the derived
PlotRenderAttributes class.
valueFormat attribute, in a manner
described by the TupleFormat class.
Next to valueFormat attribute there is also a simpler
dataFormat attribute that specifies the text string
output format of a single data value. This attribute corresponds to
FormatType format strings that chart data
framework uses to parse and format individual data values. The
value format depends on the data type the format is applied to, as
described by decendants of the FormatType
class.
LineRenderAttributes,
PlotRenderAttributes,
AxisRenderAttributes,
BackRenderAttributes,
ChartAttributes,
Serialized Form| Field Summary | |
protected java.util.Properties |
M_annotation
Chart annotation properties (may be null). |
protected PaintScale |
M_colorScale
Intervalled coloring. |
protected java.lang.String |
M_dataFormat
Single value format (may be null). |
protected java.lang.Integer |
M_lineSmoothness
Line smoothness setting (integer from 0 to 100) |
protected PaintScale |
M_paintScale
Intervalled painting. |
protected ShapeScale |
M_shapeScale
Intervalled shaping. |
protected java.lang.String |
M_valueFormat
Composite value format (may be null). |
| Fields inherited from class com.davisor.graphics.chart.LineRenderAttributes |
BACK, DEFAULTS, LINE, NROFSETS, POINT, VALUE |
| Fields inherited from class com.davisor.graphics.RenderAttributes |
ANTIALIASINDEX, ANTIALIASWORDS, AUTO, CEILING, CENTER, DIAGONAL, DOWN, FLOOR, FRONT, GRAPHICS, HORIZONTAL, INSIDE, LEFT, LEFTWALL, M_alignment, M_color, M_composite, M_defaultIndex, M_defaults, M_font, M_paint, M_shape, M_size, M_stroke, NE, NONE, NW, OFF, ON, OUTSIDE, RIGHT, RIGHTWALL, SE, SW, TEXT, THROUGH, UNSET, UP, VERTICAL |
| Constructor Summary | |
DataRenderAttributes()
Default constructor. |
|
DataRenderAttributes(DataRenderAttributes dra)
Shallow copy constructor. |
|
DataRenderAttributes(DataRenderAttributes dra,
DataRenderAttributes defaults)
Shallow copy constructor, with explicitly given default values. |
|
DataRenderAttributes(java.awt.Paint[] colors,
java.awt.Paint[] paints,
java.awt.Stroke[] strokes,
java.awt.Shape[] shapes,
java.awt.Font[] fonts,
int[] alignments,
java.awt.Composite[] composites,
RenderAttributes defaults)
Creates a render attributes set with the given initial attribute values. |
|
DataRenderAttributes(java.awt.Paint[] colors,
java.awt.Paint[] paints,
java.awt.Stroke[] strokes,
java.awt.Shape[] shapes,
java.awt.Font[] fonts,
int[] alignments,
java.awt.Composite[] composites,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat)
Deprecated. Creates a render attributes set with the given initial attribute values. A null value array will leave all attributes values as null (or UNSET).
Minimum and maximum shape size values, if set, will define the size range to which the sizes of dynamically scaled shapes will mapped. |
|
DataRenderAttributes(java.awt.Paint[] colors,
java.awt.Paint[] paints,
java.awt.Stroke[] strokes,
java.awt.Shape[] shapes,
java.awt.Font[] fonts,
int[] alignments,
java.awt.Composite[] composites,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat,
PaintScale paintScale,
PaintScale colorScale,
ShapeScale shapeScale)
Creates a render attributes set with the given initial attribute values. |
|
DataRenderAttributes(java.awt.Paint color,
java.awt.Paint paint,
java.awt.Stroke stroke,
java.awt.Shape shape,
java.awt.Font font,
int alignment,
java.awt.Composite composite,
RenderAttributes defaults)
Creates a render attributes set with the given initial default attribute values. |
|
DataRenderAttributes(java.awt.Paint color,
java.awt.Paint paint,
java.awt.Stroke stroke,
java.awt.Shape shape,
java.awt.Font font,
int alignment,
java.awt.Composite composite,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat)
Deprecated. Creates a render attributes set with the given initial default attribute values. All rendering attributes will be installed in slot zero. The default index is also set to zero, and exceptions are disabled. The result is that the attribute set will behave as if it had an equal value initially set for each slot. Minimum and maximum shape size values, if set, will define the size range to which the sizes of dynamically scaled shapes will mapped. |
|
DataRenderAttributes(java.awt.Paint color,
java.awt.Paint paint,
java.awt.Stroke stroke,
java.awt.Shape shape,
java.awt.Font font,
int alignment,
java.awt.Composite composite,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat,
PaintScale paintScale,
PaintScale colorScale,
ShapeScale shapeScale)
Creates a render attributes set with the given initial default attribute values. |
|
| Method Summary | |
com.davisor.core.Dupable |
dup()
Duplicates this object. |
java.util.Properties |
getAnnotationAttributes()
Creates and returns an annotation attribute property set which takes care of defaulting. |
java.util.Properties |
getAnnotationAttributes(boolean defaults)
Creates and returns an annotation attribute property set. |
java.util.HashSet |
getAnnotationNames()
Gets the annotation attribute names. |
java.lang.String |
getAnnotationValue(java.lang.String name)
Gets annotation value for given attribute name. |
PaintScale |
getColorScale()
Returns color scale if defined. |
PaintScale |
getColorScale(boolean defaults)
Returns color scale if defined. |
java.lang.String |
getDataFormat()
Gets single value format. |
java.lang.Integer |
getLineSmoothness()
Return line smoothness value. |
PaintScale |
getPaintScale()
Returns paint scale if defined. |
PaintScale |
getPaintScale(boolean defaults)
Returns paint scale if defined. |
ShapeScale |
getShapeScale()
Returns shape scale if defined. |
ShapeScale |
getShapeScale(boolean defaults)
Returns shape scale if defined. |
java.lang.String |
getValueFormat()
Gets composite value format. |
void |
setAnnotationAttributes(java.util.Properties annotation)
Sets annotation attributes. |
void |
setAnnotationNameValue(java.lang.String name,
java.lang.String value)
Sets annotation attribute value for the given attribute name. |
void |
setColorScale(PaintScale colorScale)
Set color scale for intervalled coloring. |
void |
setDataFormat(java.lang.String dataFormat)
Sets single value format. |
void |
setLineSmoothness(java.lang.Integer smoothness)
Method for setting line smoothness |
void |
setPaintScale(PaintScale paintScale)
Set paint scale for intervalled painting. |
void |
setShapeScale(ShapeScale shapeScale)
Set shape scale for intervalled shaping. |
void |
setValueFormat(java.lang.String valueFormat)
Sets composite value format. |
protected void |
toString(java.lang.StringBuffer xml)
Add specific format attributes and call super class implementation. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected java.util.Properties M_annotation
protected java.lang.String M_dataFormat
protected java.lang.Integer M_lineSmoothness
protected java.lang.String M_valueFormat
protected PaintScale M_paintScale
protected PaintScale M_colorScale
protected ShapeScale M_shapeScale
| Constructor Detail |
public DataRenderAttributes()
RenderAttributes.RenderAttributes(int)public DataRenderAttributes(DataRenderAttributes dra)
dra - render attributes to be copied (may be null)RenderAttributes.RenderAttributes(RenderAttributes)
public DataRenderAttributes(DataRenderAttributes dra,
DataRenderAttributes defaults)
If given defaults are null, given
principal render attributes defaults are used, if available. If
not, default attributes remains unset. In any case, they may be
later set with RenderAttributes.setDefaults(com.davisor.graphics.RenderAttributes).
If given principal render attributes source dra is
null, render attributes set size is copied from
given defaults, if possible. If both arguments are
null, render attribute set size and defaults
remain undetermined.
dra - render attributes to be copied (may be null)defaults - default render attibutes (may be null)RenderAttributes.RenderAttributes(RenderAttributes,RenderAttributes)
public DataRenderAttributes(java.awt.Paint color,
java.awt.Paint paint,
java.awt.Stroke stroke,
java.awt.Shape shape,
java.awt.Font font,
int alignment,
java.awt.Composite composite,
RenderAttributes defaults)
color - initial color attribute values (may be null)paint - initial paint attribute values (may be null)stroke - initial stroke attribute values (may be null)shape - initial shape attribute values (may be null)font - initial font attribute values (may be null)alignment - initial alignment attribute values
(RenderAttributes alignment code)composite - initial composite attribute values (may be null)defaults - default attribute values (may be null)DataRenderAttributes(Paint,Paint,Stroke,Shape,Font,int,
Composite,RenderAttributes,Properties,String,String,PaintScale,
PaintScale,ShapeScale)
public DataRenderAttributes(java.awt.Paint[] colors,
java.awt.Paint[] paints,
java.awt.Stroke[] strokes,
java.awt.Shape[] shapes,
java.awt.Font[] fonts,
int[] alignments,
java.awt.Composite[] composites,
RenderAttributes defaults)
null (or UNSET).
colors - initial color attribute values (may be null)paints - initial paint attribute values (may be null)strokes - initial stroke attribute values (may be null)shapes - initial shape attribute values (may be null)fonts - initial font attribute values (may be null)alignments - initial alignment attribute values
(array of RenderAttributes alignment codes, may be null)composites - initial composite attribute values (may be null)defaults - default attribute values (may be null)DataRenderAttributes(Paint[],Paint[],Stroke[],Shape[],Font[],int[],
Composite[],RenderAttributes,Properties,String,String,PaintScale,
PaintScale,ShapeScale)
public DataRenderAttributes(java.awt.Paint color,
java.awt.Paint paint,
java.awt.Stroke stroke,
java.awt.Shape shape,
java.awt.Font font,
int alignment,
java.awt.Composite composite,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat,
PaintScale paintScale,
PaintScale colorScale,
ShapeScale shapeScale)
Minimum and maximum shape size values, if set, will define the size range to which the sizes of dynamically scaled shapes will mapped.
color - initial color attribute values (may be null)paint - initial paint attribute values (may be null)stroke - initial stroke attribute values (may be null)shape - initial shape attribute values (may be null)font - initial font attribute values (may be null)alignment - initial alignment attribute values
(RenderAttributes alignment code)composite - initial composite attribute values (may be null)defaults - default attribute values (may be null)annotation - annotation attributes (may be null)dataFormat - single value format (may be null)valueFormat - composite value format (may be null)paintScale - intervalled painting (may be null)colorScale - intervalled coloring (may be null)shapeScale - intervalled shaping (may be null)LineRenderAttributes.LineRenderAttributes(Paint,Paint,Stroke,Shape,
Font,int,Composite,
RenderAttributes)
public DataRenderAttributes(java.awt.Paint[] colors,
java.awt.Paint[] paints,
java.awt.Stroke[] strokes,
java.awt.Shape[] shapes,
java.awt.Font[] fonts,
int[] alignments,
java.awt.Composite[] composites,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat,
PaintScale paintScale,
PaintScale colorScale,
ShapeScale shapeScale)
null (or UNSET).
Minimum and maximum shape size values, if set, will define the size range to which the sizes of dynamically scaled shapes will mapped.
colors - initial color attribute values (may be null)paints - initial paint attribute values (may be null)strokes - initial stroke attribute values (may be null)shapes - initial shape attribute values (may be null)fonts - initial font attribute values (may be null)alignments - initial alignment attribute values
(array of (RenderAttributes alignment codes, may be null)composites - initial composite attribute values (may be null)defaults - default attribute values (may be null)annotation - annotation attributes (may be null)dataFormat - single value format (may be null)valueFormat - composite value format (may be null)paintScale - intervalled painting (may be null)colorScale - intervalled coloring (may be null)shapeScale - intervalled shaping (may be null)LineRenderAttributes.LineRenderAttributes(Paint[],Paint[],Stroke[],
Shape[],Font[],int[],
Composite[],
RenderAttributes)
public DataRenderAttributes(java.awt.Paint color,
java.awt.Paint paint,
java.awt.Stroke stroke,
java.awt.Shape shape,
java.awt.Font font,
int alignment,
java.awt.Composite composite,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat)
Minimum and maximum shape size values, if set, will define the size range to which the sizes of dynamically scaled shapes will mapped.
color - initial color attribute values (may be null)paint - initial paint attribute values (may be null)stroke - initial stroke attribute values (may be null)shape - initial shape attribute values (may be null)font - initial font attribute values (may be null)alignment - initial alignment attribute values
(RenderAttributes alignment code)composite - initial composite attribute values (may be null)defaults - default attribute values (may be null)annotation - annotation attributes (may be null)dataFormat - single value format (may be null)valueFormat - composite value format (may be null)LineRenderAttributes.LineRenderAttributes(Paint,Paint,Stroke,Shape,
Font,int,Composite,
RenderAttributes)
public DataRenderAttributes(java.awt.Paint[] colors,
java.awt.Paint[] paints,
java.awt.Stroke[] strokes,
java.awt.Shape[] shapes,
java.awt.Font[] fonts,
int[] alignments,
java.awt.Composite[] composites,
RenderAttributes defaults,
java.util.Properties annotation,
java.lang.String dataFormat,
java.lang.String valueFormat)
null (or UNSET).
Minimum and maximum shape size values, if set, will define the size range to which the sizes of dynamically scaled shapes will mapped.
colors - initial color attribute values (may be null)paints - initial paint attribute values (may be null)strokes - initial stroke attribute values (may be null)shapes - initial shape attribute values (may be null)fonts - initial font attribute values (may be null)alignments - initial alignment attribute values
(array of (RenderAttributes alignment codes, may be null)composites - initial composite attribute values (may be null)defaults - default attribute values (may be null)annotation - annotation attributes (may be null)dataFormat - single value format (may be null)valueFormat - composite value format (may be null)LineRenderAttributes.LineRenderAttributes(Paint[],Paint[],Stroke[],
Shape[],Font[],int[],
Composite[],
RenderAttributes)| Method Detail |
public com.davisor.core.Dupable dup()
dup in interface com.davisor.core.Dupabledup in class LineRenderAttributesprotected void toString(java.lang.StringBuffer xml)
toString in class LineRenderAttributesxml - string buffer to write xml attributes intoRenderAttributes.toString(),
RenderAttributes.toString(int,String)public java.util.Properties getAnnotationAttributes()
null.
public java.util.Properties getAnnotationAttributes(boolean defaults)
null.
defaults - whether defaults are taken into accountpublic java.util.HashSet getAnnotationNames()
public java.lang.String getAnnotationValue(java.lang.String name)
null if unsetpublic PaintScale getColorScale()
null.
public PaintScale getColorScale(boolean defaults)
null.
defaults - whether defaults are taken into accountpublic java.lang.String getDataFormat()
null if unsetsetDataFormat(java.lang.String)public java.lang.Integer getLineSmoothness()
public PaintScale getPaintScale()
null.
public PaintScale getPaintScale(boolean defaults)
null.
defaults - whether defaults are taken into accountpublic ShapeScale getShapeScale()
null.
public ShapeScale getShapeScale(boolean defaults)
null.
defaults - whether defaults are taken into accountpublic java.lang.String getValueFormat()
null if unsetsetValueFormat(java.lang.String)public void setAnnotationAttributes(java.util.Properties annotation)
public void setAnnotationNameValue(java.lang.String name,
java.lang.String value)
setAnnotationAttributes(Properties)public void setColorScale(PaintScale colorScale)
public void setDataFormat(java.lang.String dataFormat)
FormatType class.
dataFormat - new single value formatgetDataFormat()public void setLineSmoothness(java.lang.Integer smoothness)
smoothness - should be integer in range [0,100]public void setPaintScale(PaintScale paintScale)
public void setShapeScale(ShapeScale shapeScale)
public void setValueFormat(java.lang.String valueFormat)
TupleFormat class documentation.
valueFormat - new composite value formatgetValueFormat()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||