MCPcopy Index your code
hub / github.com/cifertech/DisplayKit / initFontList

Function initFontList

app.js:3238–3260  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3236}
3237
3238function initFontList() {
3239 propFont.innerHTML = "";
3240
3241 // Populate fonts based on current driver mode
3242 const mode = getCurrentDriverMode();
3243 if (mode === "tft") {
3244 // TFT_eSPI fonts
3245 TFT_ESPI_FONTS.forEach(font => {
3246 const opt = document.createElement("option");
3247 opt.value = font.value;
3248 opt.textContent = font.label;
3249 propFont.appendChild(opt);
3250 });
3251 } else {
3252 // U8g2 fonts
3253 U8G2_FONTS.forEach(name => {
3254 const opt = document.createElement("option");
3255 opt.value = name;
3256 opt.textContent = name;
3257 propFont.appendChild(opt);
3258 });
3259 }
3260}
3261
3262
3263function updatePreviewSize() {

Callers 3

applyStateSnapshotFunction · 0.85
updatePropsInputsFunction · 0.85
app.jsFile · 0.85

Calls 1

getCurrentDriverModeFunction · 0.85

Tested by

no test coverage detected