MCPcopy Index your code
hub / github.com/processing/processing / drawChar

Method drawChar

core/src/processing/core/PShapeSVG.java:1864–1872  ·  view source on GitHub ↗
(PGraphics g, char c, float x, float y, float size)

Source from the content-addressed store, hash-verified

1862
1863
1864 public void drawChar(PGraphics g, char c, float x, float y, float size) {
1865 g.pushMatrix();
1866 float s = size / face.unitsPerEm;
1867 g.translate(x, y);
1868 g.scale(s, -s);
1869 FontGlyph fg = unicodeGlyphs.get(Character.valueOf(c));
1870 if (fg != null) g.shape(fg);
1871 g.popMatrix();
1872 }
1873
1874
1875 public float textWidth(String str, float size) {

Callers

nothing calls this directly

Calls 6

translateMethod · 0.65
scaleMethod · 0.65
getMethod · 0.65
pushMatrixMethod · 0.45
shapeMethod · 0.45
popMatrixMethod · 0.45

Tested by

no test coverage detected