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

Method indexActual

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

Source from the content-addressed store, hash-verified

632
633
634 protected int indexActual(char c) {
635 // degenerate case, but the find function will have trouble
636 // if there are somehow zero chars in the lookup
637 //if (value.length == 0) return -1;
638 if (glyphCount == 0) return -1;
639
640 // quicker lookup for the ascii fellers
641 if (c < 128) return ascii[c];
642
643 // some other unicode char, hunt it out
644 //return index_hunt(c, 0, value.length-1);
645 return indexHunt(c, 0, glyphCount-1);
646 }
647
648
649 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