public TextElement() { \r
}\r
\r
+ public double getTextDeltaX() {\r
+ return 0.0;\r
+ }\r
+ \r
+ public double getTextDeltaY() {\r
+ return 0.0;\r
+ }\r
+ \r
public TextElement(String label, double x, double y) {\r
this.label = label;\r
this.posX = x;\r
textBounds.getHeight()*FONT_SCALE\r
);\r
\r
- textX = posX-textBounds.getCenterX();\r
- textY = posY-textBounds.getCenterY();\r
+ textX = posX+getTextDeltaX()-textBounds.getCenterX();\r
+ textY = posY+getTextDeltaY()-textBounds.getCenterY();\r
bounds.setFrame(\r
- posX-textBounds.getWidth()*0.5-XPADDING,\r
- posY-textBounds.getHeight()*0.5-YPADDING,\r
+ posX+getTextDeltaX()-textBounds.getWidth()*0.5-XPADDING,\r
+ posY+getTextDeltaY()-textBounds.getHeight()*0.5-YPADDING,\r
textBounds.getWidth()+XPADDING*2,\r
textBounds.getHeight()+YPADDING*2\r
); \r