| 805 | /// |
| 806 | /// - `textDecoration`: Text decoration bitmask (See Style's TEXT_DECORATION_* constants) |
| 807 | public void drawString(String str, int x, int y, int textDecoration) { |
| 808 | // remove a commonly used trick to create a spacer label from the paint queue |
| 809 | if (str.length() == 0 || (str.length() == 1 && str.charAt(0) == ' ')) { |
| 810 | return; |
| 811 | } |
| 812 | |
| 813 | Object nativeFont = null; |
| 814 | if (current != null) { |
| 815 | nativeFont = current.getNativeFont(); |
| 816 | } |
| 817 | if (current instanceof CustomFont) { |
| 818 | current.drawString(this, str, x, y); |
| 819 | } else { |
| 820 | impl.drawString(nativeGraphics, nativeFont, str, x + xTranslate, y + yTranslate, textDecoration); |
| 821 | } |
| 822 | } |
| 823 | |
| 824 | /// Draws a string using baseline coordinates. |
| 825 | /// |