MCPcopy Index your code
hub / github.com/benfry/processing4 / indexActual

Method indexActual

core/src/processing/core/PFont.java:641–653  ·  view source on GitHub ↗
(char c)

Source from the content-addressed store, hash-verified

639
640
641 protected int indexActual(char c) {
642 // degenerate case, but the find function will have trouble
643 // if there are somehow zero chars in the lookup
644 //if (value.length == 0) return -1;
645 if (glyphCount == 0) return -1;
646
647 // quicker lookup for the ascii fellers
648 if (c < 128) return ascii[c];
649
650 // some other unicode char, hunt it out
651 //return index_hunt(c, 0, value.length-1);
652 return indexHunt(c, 0, glyphCount-1);
653 }
654
655
656 protected int indexHunt(int c, int start, int stop) {

Callers 1

indexMethod · 0.95

Calls 1

indexHuntMethod · 0.95

Tested by

no test coverage detected