示例#1
0
 public ValueTick(TickType tickType, double value, string label, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
   : base(label, textAnchor, rotationAnchor, angle)
 {
   ValueTick valueTick = this;
   this.value = value;
   this.tickType = tickType;
 }
 public ItemLabelPosition(ItemLabelAnchor itemLabelAnchor, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
 {
   base.\u002Ector();
   ItemLabelPosition itemLabelPosition = this;
   if (itemLabelAnchor == null)
   {
     string str = "Null 'itemLabelAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (textAnchor == null)
   {
     string str = "Null 'textAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (rotationAnchor == null)
   {
     string str = "Null 'rotationAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.itemLabelAnchor = itemLabelAnchor;
     this.textAnchor = textAnchor;
     this.rotationAnchor = rotationAnchor;
     this.angle = angle;
   }
 }
示例#3
0
 public CategoryTick(IComparable category, TextBlock label, TextBlockAnchor labelAnchor, TextAnchor rotationAnchor, double angle)
   : base("", TextAnchor.__\u003C\u003ECENTER, rotationAnchor, angle)
 {
   CategoryTick categoryTick = this;
   this.category = category;
   this.label = label;
   this.labelAnchor = labelAnchor;
 }
 public DialValueIndicator(int datasetIndex)
 {
   DialValueIndicator dialValueIndicator = this;
   this.datasetIndex = datasetIndex;
   this.angle = -90.0;
   this.radius = 0.3;
   this.frameAnchor = RectangleAnchor.__\u003C\u003ECENTER;
   this.templateValue = (Number) new Double(100.0);
   this.formatter = (NumberFormat) new DecimalFormat("0.0");
   this.font = new Font("Dialog", 1, 14);
   this.paint = (Paint) Color.black;
   this.backgroundPaint = (Paint) Color.white;
   this.outlineStroke = (Stroke) new BasicStroke(1f);
   this.outlinePaint = (Paint) Color.blue;
   this.insets = new RectangleInsets(4.0, 4.0, 4.0, 4.0);
   this.valueAnchor = RectangleAnchor.__\u003C\u003ERIGHT;
   this.textAnchor = TextAnchor.__\u003C\u003ECENTER_RIGHT;
 }
 public DialTextAnnotation(string label)
 {
   DialTextAnnotation dialTextAnnotation = this;
   if (label == null)
   {
     string str = "Null 'label' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.angle = -90.0;
     this.radius = 0.3;
     this.font = new Font("Dialog", 1, 14);
     this.paint = (Paint) Color.black;
     this.label = label;
     this.anchor = TextAnchor.__\u003C\u003ETOP_CENTER;
   }
 }
 public CategoryLabelPosition(RectangleAnchor categoryAnchor, TextBlockAnchor labelAnchor, TextAnchor rotationAnchor, double angle, CategoryLabelWidthType widthType, float widthRatio)
 {
   base.\u002Ector();
   CategoryLabelPosition categoryLabelPosition = this;
   if (categoryAnchor == null)
   {
     string str = "Null 'categoryAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (labelAnchor == null)
   {
     string str = "Null 'labelAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (rotationAnchor == null)
   {
     string str = "Null 'rotationAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (widthType == null)
   {
     string str = "Null 'widthType' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.categoryAnchor = categoryAnchor;
     this.labelAnchor = labelAnchor;
     this.rotationAnchor = rotationAnchor;
     this.angle = angle;
     this.widthType = widthType;
     this.widthRatio = widthRatio;
   }
 }
示例#7
0
 public Tick(string text, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
 {
   base.\u002Ector();
   Tick tick = this;
   if (textAnchor == null)
   {
     string str = "Null 'textAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (rotationAnchor == null)
   {
     string str = "Null 'rotationAnchor' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.text = text;
     this.textAnchor = textAnchor;
     this.rotationAnchor = rotationAnchor;
     this.angle = angle;
   }
 }
 public CycleBoundTick(bool mapToLastCycle, Number number, string label, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
 {
   int num = mapToLastCycle ? 1 : 0;
   // ISSUE: explicit constructor call
   base.\u002Ector(number, label, textAnchor, rotationAnchor, angle);
   CyclicNumberAxis.CycleBoundTick cycleBoundTick = this;
   this.mapToLastCycle = num != 0;
 }
示例#9
0
 public NumberTick(TickType tickType, double value, string label, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
   : base(tickType, value, label, textAnchor, rotationAnchor, angle)
 {
   NumberTick numberTick = this;
   this.number = (Number) new Double(value);
 }
示例#10
0
 public NumberTick(Number number, string label, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
   : base(number.doubleValue(), label, textAnchor, rotationAnchor, angle)
 {
   NumberTick numberTick = this;
   this.number = number;
 }
示例#11
0
 protected internal Marker(Paint paint, Stroke stroke, Paint outlinePaint, Stroke outlineStroke, float alpha)
 {
   base.\u002Ector();
   Marker marker = this;
   this.label = (string) null;
   if (paint == null)
   {
     string str = "Null 'paint' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if (stroke == null)
   {
     string str = "Null 'stroke' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else if ((double) alpha < 0.0 || (double) alpha > 1.0)
   {
     string str = "The 'alpha' value must be in the range 0.0f to 1.0f";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.paint = paint;
     this.stroke = stroke;
     this.outlinePaint = outlinePaint;
     this.outlineStroke = outlineStroke;
     this.alpha = alpha;
     this.labelFont = new Font("SansSerif", 0, 9);
     this.labelPaint = (Paint) Color.black;
     this.labelAnchor = RectangleAnchor.__\u003C\u003ETOP_LEFT;
     this.labelOffset = new RectangleInsets(3.0, 3.0, 3.0, 3.0);
     this.labelOffsetType = LengthAdjustmentType.__\u003C\u003ECONTRACT;
     this.labelTextAnchor = TextAnchor.__\u003C\u003ECENTER;
     this.listenerList = new EventListenerList();
   }
 }
 public ItemLabelPosition(ItemLabelAnchor itemLabelAnchor, TextAnchor textAnchor)
   : this(itemLabelAnchor, textAnchor, TextAnchor.__\u003C\u003ECENTER, 0.0)
 {
 }
示例#13
0
 public static Shape calculateRotatedStringBounds(string text, Graphics2D g2, float x, float y, TextAnchor textAnchor, double angle, TextAnchor rotationAnchor)
 {
   if (text == null || String.instancehelper_equals(text, (object) ""))
     return (Shape) null;
   float[] numArray1 = TextUtilities.deriveTextBoundsAnchorOffsets(g2, text, textAnchor);
   if (TextUtilities.__\u003C\u003Elogger.isDebugEnabled())
     TextUtilities.__\u003C\u003Elogger.debug((object) new StringBuffer().append("TextBoundsAnchorOffsets = ").append(numArray1[0]).append(", ").append(numArray1[1]).toString());
   float[] numArray2 = TextUtilities.deriveRotationAnchorOffsets(g2, text, rotationAnchor);
   if (TextUtilities.__\u003C\u003Elogger.isDebugEnabled())
     TextUtilities.__\u003C\u003Elogger.debug((object) new StringBuffer().append("RotationAnchorOffsets = ").append(numArray2[0]).append(", ").append(numArray2[1]).toString());
   return TextUtilities.calculateRotatedStringBounds(text, g2, x + numArray1[0], y + numArray1[1], angle, x + numArray1[0] + numArray2[0], y + numArray1[1] + numArray2[1]);
 }
示例#14
0
 public static void drawRotatedString(string text, Graphics2D g2, float x, float y, TextAnchor textAnchor, double angle, TextAnchor rotationAnchor)
 {
   if (text == null || String.instancehelper_equals(text, (object) ""))
     return;
   float[] numArray1 = TextUtilities.deriveTextBoundsAnchorOffsets(g2, text, textAnchor);
   float[] numArray2 = TextUtilities.deriveRotationAnchorOffsets(g2, text, rotationAnchor);
   TextUtilities.drawRotatedString(text, g2, x + numArray1[0], y + numArray1[1], angle, x + numArray1[0] + numArray2[0], y + numArray1[1] + numArray2[1]);
 }
示例#15
0
 public static Rectangle2D drawAlignedString(string text, Graphics2D g2, float x, float y, TextAnchor anchor)
 {
   Rectangle2D.Double @double = new Rectangle2D.Double();
   float[] numArray = TextUtilities.deriveTextBoundsAnchorOffsets(g2, text, anchor, (Rectangle2D) @double);
   ((Rectangle2D) @double).setRect((double) (x + numArray[0]), (double) (y + numArray[1] + numArray[2]), ((RectangularShape) @double).getWidth(), ((RectangularShape) @double).getHeight());
   g2.drawString(text, x + numArray[0], y + numArray[1]);
   return (Rectangle2D) @double;
 }
示例#16
0
 protected internal TextAnnotation(string text)
 {
   base.\u002Ector();
   TextAnnotation textAnnotation = this;
   if (text == null)
   {
     string str = "Null 'text' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.text = text;
     this.font = TextAnnotation.__\u003C\u003EDEFAULT_FONT;
     this.paint = TextAnnotation.__\u003C\u003EDEFAULT_PAINT;
     this.textAnchor = TextAnnotation.__\u003C\u003EDEFAULT_TEXT_ANCHOR;
     this.rotationAnchor = TextAnnotation.__\u003C\u003EDEFAULT_ROTATION_ANCHOR;
     this.rotationAngle = 0.0;
   }
 }
示例#17
0
 public ValueTick(double value, string label, TextAnchor textAnchor, TextAnchor rotationAnchor, double angle)
   : this(TickType.__\u003C\u003EMAJOR, value, label, textAnchor, rotationAnchor, angle)
 {
   ValueTick valueTick = this;
   this.value = value;
 }
 public XYTextAnnotation(string text, double x, double y)
 {
   XYTextAnnotation xyTextAnnotation = this;
   if (text == null)
   {
     string str = "Null 'text' argument.";
     Throwable.__\u003CsuppressFillInStackTrace\u003E();
     throw new IllegalArgumentException(str);
   }
   else
   {
     this.text = text;
     this.font = XYTextAnnotation.__\u003C\u003EDEFAULT_FONT;
     this.paint = XYTextAnnotation.__\u003C\u003EDEFAULT_PAINT;
     this.x = x;
     this.y = y;
     this.textAnchor = XYTextAnnotation.__\u003C\u003EDEFAULT_TEXT_ANCHOR;
     this.rotationAnchor = XYTextAnnotation.__\u003C\u003EDEFAULT_ROTATION_ANCHOR;
     this.rotationAngle = 0.0;
     this.backgroundPaint = (Paint) null;
     this.outlineVisible = false;
     this.outlinePaint = (Paint) Color.black;
     this.outlineStroke = (Stroke) new BasicStroke(0.5f);
   }
 }