示例#1
0
 public void setLineWidth(float theLinewidth) {
   switch (_myFontRenderingQuality) {
     case FONT_QUALITY_LOW:
       _myLineWidth = theLinewidth;
       _myFont.setLineWidth(_myLineWidth);
       break;
     case FONT_QUALITY_HIGH:
       _myLineWidth = theLinewidth * _myScaleFactor;
       _myFont.setLineWidth(_myLineWidth);
       break;
   }
 }
示例#2
0
 public void setSize(float theSize) {
   switch (_myFontRenderingQuality) {
     case FONT_QUALITY_LOW:
       _myFontSize = theSize;
       _myFont.setSize(_myFontSize);
       break;
     case FONT_QUALITY_HIGH:
       _myFontSize = theSize * _myScaleFactor;
       _myFont.setSize(_myFontSize);
       break;
   }
 }
示例#3
0
 public void setImageBorder(Vector2i theBorder) {
   switch (_myFontRenderingQuality) {
     case FONT_QUALITY_LOW:
       break;
     case FONT_QUALITY_HIGH:
       theBorder.x *= _myScaleFactor;
       theBorder.y *= _myScaleFactor;
       break;
   }
   _myFont.setImageBorder(theBorder);
 }
示例#4
0
 public BufferedImage getImage(String theText) {
   BufferedImage myImage = _myFont.getImage(theText);
   switch (_myFontRenderingQuality) {
     case FONT_QUALITY_LOW:
       break;
     case FONT_QUALITY_HIGH:
       myImage = ImageUtil.blur(myImage, _mySmoothFactor);
       myImage = ImageUtil.scale(myImage, 1.0f / _myScaleFactor);
       break;
   }
   return myImage;
 }
示例#5
0
 public void antialias(boolean theAntialias) {
   _myFont.antialias(theAntialias);
 }
示例#6
0
 public void setAlignment(int theAlignment) {
   _myFont.setAlignment(theAlignment);
 }
示例#7
0
 public void setStyle(int theStyle) {
   _myFontStyle = theStyle;
   _myFont.setStyle(theStyle);
 }
示例#8
0
 public void setFontColor(Color theColor) {
   _myFont.setFontColor(new java.awt.Color(theColor.r, theColor.g, theColor.b, theColor.a));
 }