MCPcopy Create free account
hub / github.com/AI-FanGe/OpenAIglasses_for_Navigation / drawStatusText

Method drawStatusText

static/visualizer.js:523–540  ·  view source on GitHub ↗
(mainText, subText, x, y, color)

Source from the content-addressed store, hash-verified

521 }
522
523 drawStatusText(mainText, subText, x, y, color) {
524 const ctx = this.ctx;
525
526 // 主文字(中文)
527 ctx.font = this.fonts.subtitle;
528 ctx.fillStyle = color;
529 ctx.textAlign = 'center';
530 ctx.fillText(mainText, x, y);
531
532 // 副文字(英文)
533 if (subText) {
534 ctx.font = this.fonts.small;
535 ctx.fillStyle = this.colors.textMuted;
536 ctx.fillText(subText, x, y + 20);
537 }
538
539 ctx.textAlign = 'left';
540 }
541}
542
543// 初始化

Callers 3

drawSegmentModeMethod · 0.95
drawFlashModeMethod · 0.95
drawTrackModeMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected