aboutsummaryrefslogtreecommitdiffstats
path: root/src/jogl
diff options
context:
space:
mode:
Diffstat (limited to 'src/jogl')
-rw-r--r--src/jogl/classes/com/jogamp/graph/font/Font.java7
-rw-r--r--src/jogl/classes/jogamp/graph/font/typecast/TypecastFont.java9
2 files changed, 10 insertions, 6 deletions
diff --git a/src/jogl/classes/com/jogamp/graph/font/Font.java b/src/jogl/classes/com/jogamp/graph/font/Font.java
index 96e0cc523..314040adf 100644
--- a/src/jogl/classes/com/jogamp/graph/font/Font.java
+++ b/src/jogl/classes/com/jogamp/graph/font/Font.java
@@ -458,13 +458,16 @@ public interface Font {
* <p>
* This method is only exposed to validate the produced {@link OutlineShape} against {@link #getGlyphBounds(CharSequence)}.
* </p>
+ * @param transform optional given transform
* @param string string text
+ * @param tmp1 temp {@link AffineTransform} to be reused
+ * @param tmp2 temp {@link AffineTransform} to be reused
* @return the bounding box of the given string in font-units [0..1]
- * @see #getGlyphShapeBounds(AffineTransform, CharSequence)
+ * @see #getGlyphShapeBounds(CharSequence)
* @see #getGlyphBounds(CharSequence)
* @see #getMetricBounds(CharSequence)
*/
- AABBox getGlyphShapeBounds(final CharSequence string);
+ AABBox getGlyphShapeBounds(final AffineTransform transform, final CharSequence string, final AffineTransform tmp1, final AffineTransform tmp2);
boolean isPrintableChar(final char c);
diff --git a/src/jogl/classes/jogamp/graph/font/typecast/TypecastFont.java b/src/jogl/classes/jogamp/graph/font/typecast/TypecastFont.java
index f7c10c335..7cf520bf3 100644
--- a/src/jogl/classes/jogamp/graph/font/typecast/TypecastFont.java
+++ b/src/jogl/classes/jogamp/graph/font/typecast/TypecastFont.java
@@ -364,11 +364,12 @@ class TypecastFont implements Font {
}
@Override
- public AABBox getGlyphShapeBounds(final CharSequence string) {
- return getGlyphShapeBounds(null, string);
+ public AABBox getGlyphShapeBounds(final AffineTransform transform, final CharSequence string) {
+ return getGlyphShapeBounds(transform, string, new AffineTransform(), new AffineTransform());
}
+
@Override
- public AABBox getGlyphShapeBounds(final AffineTransform transform, final CharSequence string) {
+ public AABBox getGlyphShapeBounds(final AffineTransform transform, final CharSequence string, final AffineTransform temp1, final AffineTransform temp2) {
if (null == string || 0 == string.length() ) {
return new AABBox();
}
@@ -377,7 +378,7 @@ class TypecastFont implements Font {
public final void visit(final char symbol, final Font.Glyph shape, final AffineTransform t) {
// nop
} };
- return processString(visitor, transform, string);
+ return processString(visitor, transform, string, temp1, temp2);
}
@Override