Browse Source

Call lcd_setFont only when needed

Scott Lahteine 8 years ago
parent
commit
026ae8f2f0
1 changed files with 3 additions and 4 deletions
  1. 3
    4
      Marlin/dogm_lcd_implementation.h

+ 3
- 4
Marlin/dogm_lcd_implementation.h View File

340
     #endif
340
     #endif
341
   );
341
   );
342
 
342
 
343
+  // Status Menu Font for SD info, Heater status, Fan, XYZ
344
+  lcd_setFont(FONT_STATUSMENU);
345
+
343
   #if ENABLED(SDSUPPORT)
346
   #if ENABLED(SDSUPPORT)
344
     // SD Card Symbol
347
     // SD Card Symbol
345
     u8g.drawBox(42, 42 - (TALL_FONT_CORRECTION), 8, 7);
348
     u8g.drawBox(42, 42 - (TALL_FONT_CORRECTION), 8, 7);
351
     u8g.drawFrame(54, 49, 73, 4 - (TALL_FONT_CORRECTION));
354
     u8g.drawFrame(54, 49, 73, 4 - (TALL_FONT_CORRECTION));
352
 
355
 
353
     // SD Card Progress bar and clock
356
     // SD Card Progress bar and clock
354
-    lcd_setFont(FONT_STATUSMENU);
355
-
356
     if (IS_SD_PRINTING) {
357
     if (IS_SD_PRINTING) {
357
       // Progress bar solid part
358
       // Progress bar solid part
358
       u8g.drawBox(55, 50, (unsigned int)(71.f * card.percentDone() / 100.f), 2 - (TALL_FONT_CORRECTION));
359
       u8g.drawBox(55, 50, (unsigned int)(71.f * card.percentDone() / 100.f), 2 - (TALL_FONT_CORRECTION));
376
   #endif
377
   #endif
377
 
378
 
378
   // Fan
379
   // Fan
379
-  lcd_setFont(FONT_STATUSMENU);
380
   u8g.setPrintPos(104, 27);
380
   u8g.setPrintPos(104, 27);
381
   #if HAS_FAN0
381
   #if HAS_FAN0
382
     int per = ((fanSpeeds[0] + 1) * 100) / 256;
382
     int per = ((fanSpeeds[0] + 1) * 100) / 256;
391
   // When axis is homed but axis_known_position is false the axis letters are blinking 'X' <-> ' '.
391
   // When axis is homed but axis_known_position is false the axis letters are blinking 'X' <-> ' '.
392
   // When everything is ok you see a constant 'X'.
392
   // When everything is ok you see a constant 'X'.
393
   #define XYZ_BASELINE 38
393
   #define XYZ_BASELINE 38
394
-  lcd_setFont(FONT_STATUSMENU);
395
 
394
 
396
   #if ENABLED(USE_SMALL_INFOFONT)
395
   #if ENABLED(USE_SMALL_INFOFONT)
397
     u8g.drawBox(0, 30, LCD_PIXEL_WIDTH, 10);
396
     u8g.drawBox(0, 30, LCD_PIXEL_WIDTH, 10);

Loading…
Cancel
Save