MCPcopy Create free account
hub / github.com/BruceDevices/firmware / drawTitle

Method drawTitle

include/MenuItemInterface.h:98–106  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96 }
97
98 void drawTitle(float scale = 1) {
99 int titleY = iconCenterY + iconAreaH / 2 + FG;
100
101 tft.setTextSize(FM);
102 tft.drawPixel(0, 0, 0);
103 tft.fillRect(arrowAreaX, titleY, tftWidth - 2 * arrowAreaX, LH * FM, bruceConfig.bgColor);
104 int nchars = (tftWidth - 16) / (LW * FM);
105 tft.drawCentreString(getName().substring(0, nchars), iconCenterX, titleY, 1);
106 }
107
108protected:
109 String _name = "";

Callers

nothing calls this directly

Calls 4

setTextSizeMethod · 0.45
drawPixelMethod · 0.45
fillRectMethod · 0.45
drawCentreStringMethod · 0.45

Tested by

no test coverage detected