gv.getGlyphPositions(gi, len, ret); } else { if ((tmp == null) || (tmp.length < len*2)) tmp = new float[len*2]; gv.getGlyphPositions(gi, len, tmp); System.arraycopy( tmp, 0, ret, i, len * 2 );
gv.getGlyphPositions(gi, len, ret); } else { if ((tmp == null) || (tmp.length < len*2)) tmp = new float[len*2]; gv.getGlyphPositions(gi, len, tmp); System.arraycopy( tmp, 0, ret, i, len * 2 );
gv.getGlyphPositions(gi, len, ret); } else { if ((tmp == null) || (tmp.length < len*2)) tmp = new float[len*2]; gv.getGlyphPositions(gi, len, tmp); System.arraycopy( tmp, 0, ret, i, len * 2 );
int numGlyphs = gv.getNumGlyphs(); float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null); Point2D.Float pos = new Point2D.Float(); for (int i=0; i<=numGlyphs; i++) {
int numGlyphs = gv.getNumGlyphs(); float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null); Point2D.Float pos = new Point2D.Float(); for (int i=0; i<=numGlyphs; i++) {
int numGlyphs = gv.getNumGlyphs(); float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null); Point2D.Float pos = new Point2D.Float(); for (int i=0; i<=numGlyphs; i++) {
public float [] getGlyphAdvances() { if (glyphAdvances != null) return glyphAdvances; if (!spacingApplied) // This will layout the text if needed. adjustTextSpacing(); int numGlyphs = gv.getNumGlyphs(); float [] glyphPos = gv.getGlyphPositions(0, numGlyphs+1, null); glyphAdvances = new float[numGlyphs+1]; int off = 0; if (isVertical()) off = 1; float start = glyphPos[off]; for (int i=0; i<numGlyphs+1; i++) { glyphAdvances[i] = glyphPos[2*i+off]-start; } return glyphAdvances; }
public float [] getGlyphAdvances() { if (glyphAdvances != null) return glyphAdvances; if (!spacingApplied) // This will layout the text if needed. adjustTextSpacing(); int numGlyphs = gv.getNumGlyphs(); float [] glyphPos = gv.getGlyphPositions(0, numGlyphs+1, null); glyphAdvances = new float[numGlyphs+1]; int off = 0; if (isVertical()) off = 1; float start = glyphPos[off]; for (int i=0; i<numGlyphs+1; i++) { glyphAdvances[i] = glyphPos[2*i+off]-start; } return glyphAdvances; }
public float [] getGlyphAdvances() { if (glyphAdvances != null) return glyphAdvances; if (!spacingApplied) // This will layout the text if needed. adjustTextSpacing(); int numGlyphs = gv.getNumGlyphs(); float [] glyphPos = gv.getGlyphPositions(0, numGlyphs+1, null); glyphAdvances = new float[numGlyphs+1]; int off = 0; if (isVertical()) off = 1; float start = glyphPos[off]; for (int i=0; i<numGlyphs+1; i++) { glyphAdvances[i] = glyphPos[2*i+off]-start; } return glyphAdvances; }
float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null);
float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null);
float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null);
Iterator lInfoIter = lineInfos.iterator(); int numGlyphs = gv.getNumGlyphs(); float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null); Point2D.Float lineLoc = null; float lineAdv = 0;
Iterator lInfoIter = lineInfos.iterator(); int numGlyphs = gv.getNumGlyphs(); float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null); Point2D.Float lineLoc = null; float lineAdv = 0;
Iterator lInfoIter = lineInfos.iterator(); int numGlyphs = gv.getNumGlyphs(); float [] gp = gv.getGlyphPositions(0, numGlyphs+1, null); Point2D.Float lineLoc = null; float lineAdv = 0;
public GlyphIterator(AttributedCharacterIterator aci, GVTGlyphVector gv) { this.aci = aci; this.gv = gv; this.idx = 0; this.chIdx = 0; this.lineIdx = 0; this.aciIdx = aci.getBeginIndex(); this.charCount = gv.getCharacterCount(idx, idx); this.ch = aci.first(); this.frc = gv.getFontRenderContext(); this.font = (GVTFont)aci.getAttribute(GVT_FONT); if (font == null) { font = new AWTGVTFont(aci.getAttributes()); } fontStart = aciIdx; this.maxFontSize = -Float.MAX_VALUE; this.maxAscent = -Float.MAX_VALUE; this.maxDescent = -Float.MAX_VALUE; // Figure out where the font size might change again... this.runLimit = aci.getRunLimit(TEXT_COMPOUND_ID); this.lineBreakRunLimit = aci.getRunLimit(FLOW_LINE_BREAK); Object o = aci.getAttribute(FLOW_LINE_BREAK); this.lineBreakCount = (o == null)?0:1; this.numGlyphs = gv.getNumGlyphs(); this.gp = gv.getGlyphPositions(0, this.numGlyphs+1, null); this.gvBase = new Point2D.Float(gp[0], gp[1]); this.adv = getCharWidth(); this.adj = getCharAdvance(); }
public GlyphIterator(AttributedCharacterIterator aci, GVTGlyphVector gv) { this.aci = aci; this.gv = gv; this.idx = 0; this.chIdx = 0; this.lineIdx = 0; this.aciIdx = aci.getBeginIndex(); this.charCount = gv.getCharacterCount(idx, idx); this.ch = aci.first(); this.frc = gv.getFontRenderContext(); this.font = (GVTFont)aci.getAttribute(GVT_FONT); if (font == null) { font = new AWTGVTFont(aci.getAttributes()); } fontStart = aciIdx; this.maxFontSize = -Float.MAX_VALUE; this.maxAscent = -Float.MAX_VALUE; this.maxDescent = -Float.MAX_VALUE; // Figure out where the font size might change again... this.runLimit = aci.getRunLimit(TEXT_COMPOUND_ID); this.lineBreakRunLimit = aci.getRunLimit(FLOW_LINE_BREAK); Object o = aci.getAttribute(FLOW_LINE_BREAK); this.lineBreakCount = (o == null)?0:1; this.numGlyphs = gv.getNumGlyphs(); this.gp = gv.getGlyphPositions(0, this.numGlyphs+1, null); this.gvBase = new Point2D.Float(gp[0], gp[1]); this.adv = getCharWidth(); this.adj = getCharAdvance(); }
public GlyphIterator(AttributedCharacterIterator aci, GVTGlyphVector gv) { this.aci = aci; this.gv = gv; this.idx = 0; this.chIdx = 0; this.lineIdx = 0; this.aciIdx = aci.getBeginIndex(); this.charCount = gv.getCharacterCount(idx, idx); this.ch = aci.first(); this.frc = gv.getFontRenderContext(); this.font = (GVTFont)aci.getAttribute(GVT_FONT); if (font == null) { font = new AWTGVTFont(aci.getAttributes()); } fontStart = aciIdx; this.maxFontSize = -Float.MAX_VALUE; this.maxAscent = -Float.MAX_VALUE; this.maxDescent = -Float.MAX_VALUE; // Figure out where the font size might change again... this.runLimit = aci.getRunLimit(TEXT_COMPOUND_ID); this.lineBreakRunLimit = aci.getRunLimit(FLOW_LINE_BREAK); Object o = aci.getAttribute(FLOW_LINE_BREAK); this.lineBreakCount = (o == null)?0:1; this.numGlyphs = gv.getNumGlyphs(); this.gp = gv.getGlyphPositions(0, this.numGlyphs+1, null); this.gvBase = new Point2D.Float(gp[0], gp[1]); this.adv = getCharWidth(); this.adj = getCharAdvance(); }
boolean [] hide = new boolean[numGlyphs]; boolean [] space = new boolean[numGlyphs]; float [] glyphPos = gv.getGlyphPositions(0, numGlyphs+1, null); for (int i=0; i<numGlyphs; i++) { char pch = ch;
boolean [] hide = new boolean[numGlyphs]; boolean [] space = new boolean[numGlyphs]; float [] glyphPos = gv.getGlyphPositions(0, numGlyphs+1, null); for (int i=0; i<numGlyphs; i++) { char pch = ch;