aboutsummaryrefslogtreecommitdiffstats
path: root/src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2023-08-28 22:57:53 +0200
committerSven Gothel <[email protected]>2023-08-28 22:57:53 +0200
commit920e529516bb264f04138ed1caca80d4925e3773 (patch)
tree498bce9425f880cab2cd36b4251eaa4e231e912c /src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java
parent733cc5272cfed10fa07b707e29fd756f44581508 (diff)
Graph Font + Glyph: More robust detetection and API definition of non-contour/whitespace Glyphs (detect and allow to skip 'em)
We also drop shapes for both, but for id 0 (unknown).
Diffstat (limited to 'src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java')
-rw-r--r--src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java b/src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java
index 19791d099..76e454c12 100644
--- a/src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java
+++ b/src/graphui/classes/com/jogamp/graph/ui/shapes/GlyphShape.java
@@ -71,7 +71,7 @@ public class GlyphShape extends GraphShape {
this.symbol = symbol;
this.glyph = glyph;
this.origPos = new Vec3f(x, y, 0f);
- if( glyph.isWhiteSpace() || null == glyph.getShape() ) {
+ if( glyph.isNonContour() ) {
setEnabled(false);
}
final int[/*2*/] vertIndexCount = Region.countOutlineShape(glyph.getShape(), new int[2]);
@@ -139,7 +139,7 @@ public class GlyphShape extends GraphShape {
final Font.GlyphVisitor fgv = new Font.GlyphVisitor() {
@Override
public void visit(final char symbol, final Glyph glyph, final AffineTransform t) {
- if( !glyph.isWhiteSpace() && null != glyph.getShape() ) {
+ if( !glyph.isNonContour() ) {
res.add( new GlyphShape(renderModes, symbol, glyph, t.getTranslateX(), t.getTranslateY()) );
}
}