Browse Source

Revert "Removed now unneded FONT_STATUSMENU"

This reverts commit 8c5bb38748.
AnHardt 9 years ago
parent
commit
b00a531df8
1 changed files with 14 additions and 4 deletions
  1. 14
    4
      Marlin/dogm_lcd_implementation.h

+ 14
- 4
Marlin/dogm_lcd_implementation.h View File

74
   #endif
74
   #endif
75
 #endif // SIMULATE_ROMFONT
75
 #endif // SIMULATE_ROMFONT
76
 
76
 
77
-#define FONT_MENU 1
77
+#define FONT_STATUSMENU_NAME FONT_MENU_NAME
78
+
79
+#define FONT_STATUSMENU 1
78
 #define FONT_SPECIAL 2
80
 #define FONT_SPECIAL 2
79
 #define FONT_MENU_EDIT 3
81
 #define FONT_MENU_EDIT 3
82
+#define FONT_MENU 4
80
 
83
 
81
 // DOGM parameters (size in pixels)
84
 // DOGM parameters (size in pixels)
82
 #define DOG_CHAR_WIDTH         6
85
 #define DOG_CHAR_WIDTH         6
134
 
137
 
135
 static void lcd_setFont(char font_nr) {
138
 static void lcd_setFont(char font_nr) {
136
   switch(font_nr) {
139
   switch(font_nr) {
140
+    case FONT_STATUSMENU : {u8g.setFont(FONT_STATUSMENU_NAME); currentfont = FONT_STATUSMENU;}; break;
137
     case FONT_MENU       : {u8g.setFont(FONT_MENU_NAME); currentfont = FONT_MENU;}; break;
141
     case FONT_MENU       : {u8g.setFont(FONT_MENU_NAME); currentfont = FONT_MENU;}; break;
138
     case FONT_SPECIAL    : {u8g.setFont(FONT_SPECIAL_NAME); currentfont = FONT_SPECIAL;}; break;
142
     case FONT_SPECIAL    : {u8g.setFont(FONT_SPECIAL_NAME); currentfont = FONT_SPECIAL;}; break;
139
     case FONT_MENU_EDIT  : {u8g.setFont(FONT_MENU_EDIT_NAME); currentfont = FONT_MENU_EDIT;}; break;
143
     case FONT_MENU_EDIT  : {u8g.setFont(FONT_MENU_EDIT_NAME); currentfont = FONT_MENU_EDIT;}; break;
223
   bool isBed = heater < 0;
227
   bool isBed = heater < 0;
224
   int y = 17 + (isBed ? 1 : 0);
228
   int y = 17 + (isBed ? 1 : 0);
225
 
229
 
226
-  lcd_setFont(FONT_MENU);
230
+  lcd_setFont(FONT_STATUSMENU);
227
   u8g.setPrintPos(x,7);
231
   u8g.setPrintPos(x,7);
228
   lcd_print(itostr3(int((heater >= 0 ? degTargetHotend(heater) : degTargetBed()) + 0.5)));
232
   lcd_print(itostr3(int((heater >= 0 ? degTargetHotend(heater) : degTargetBed()) + 0.5)));
229
   lcd_printPGM(PSTR(LCD_STR_DEGREE " "));
233
   lcd_printPGM(PSTR(LCD_STR_DEGREE " "));
248
 
252
 
249
   // Symbols menu graphics, animated fan
253
   // Symbols menu graphics, animated fan
250
   u8g.drawBitmapP(9,1,STATUS_SCREENBYTEWIDTH,STATUS_SCREENHEIGHT, (blink % 2) && fanSpeed ? status_screen0_bmp : status_screen1_bmp);
254
   u8g.drawBitmapP(9,1,STATUS_SCREENBYTEWIDTH,STATUS_SCREENHEIGHT, (blink % 2) && fanSpeed ? status_screen0_bmp : status_screen1_bmp);
251
-  lcd_setFont(FONT_MENU);
252
-
255
+ 
253
   #ifdef SDSUPPORT
256
   #ifdef SDSUPPORT
254
     // SD Card Symbol
257
     // SD Card Symbol
255
     u8g.drawBox(42,42,8,7);
258
     u8g.drawBox(42,42,8,7);
261
     u8g.drawFrame(54,49,73,4);
264
     u8g.drawFrame(54,49,73,4);
262
 
265
 
263
     // SD Card Progress bar and clock
266
     // SD Card Progress bar and clock
267
+    lcd_setFont(FONT_STATUSMENU);
268
+ 
264
     if (IS_SD_PRINTING) {
269
     if (IS_SD_PRINTING) {
265
       // Progress bar solid part
270
       // Progress bar solid part
266
       u8g.drawBox(55, 50, (unsigned int)(71.f * card.percentDone() / 100.f), 2);
271
       u8g.drawBox(55, 50, (unsigned int)(71.f * card.percentDone() / 100.f), 2);
285
   if (EXTRUDERS < 4) _draw_heater_status(81, -1);
290
   if (EXTRUDERS < 4) _draw_heater_status(81, -1);
286
  
291
  
287
   // Fan
292
   // Fan
293
+  lcd_setFont(FONT_STATUSMENU);
288
   u8g.setPrintPos(104,27);
294
   u8g.setPrintPos(104,27);
289
   #if defined(FAN_PIN) && FAN_PIN > -1
295
   #if defined(FAN_PIN) && FAN_PIN > -1
290
     int per = ((fanSpeed + 1) * 100) / 256;
296
     int per = ((fanSpeed + 1) * 100) / 256;
301
 
307
 
302
   // X, Y, Z-Coordinates
308
   // X, Y, Z-Coordinates
303
   #define XYZ_BASELINE 38
309
   #define XYZ_BASELINE 38
310
+  u8g.setFont(FONT_STATUSMENU);
304
   u8g.drawBox(0,30,128,9);
311
   u8g.drawBox(0,30,128,9);
305
   u8g.setColorIndex(0); // white on black
312
   u8g.setColorIndex(0); // white on black
306
   u8g.setPrintPos(2,XYZ_BASELINE);
313
   u8g.setPrintPos(2,XYZ_BASELINE);
324
   u8g.setColorIndex(1); // black on white
331
   u8g.setColorIndex(1); // black on white
325
  
332
  
326
   // Feedrate
333
   // Feedrate
334
+  lcd_setFont(FONT_MENU);
327
   u8g.setPrintPos(3,49);
335
   u8g.setPrintPos(3,49);
328
   lcd_print(LCD_STR_FEEDRATE[0]);
336
   lcd_print(LCD_STR_FEEDRATE[0]);
337
+  u8g.setFont(FONT_STATUSMENU);
329
   u8g.setPrintPos(12,49);
338
   u8g.setPrintPos(12,49);
330
   lcd_print(itostr3(feedmultiply));
339
   lcd_print(itostr3(feedmultiply));
331
   lcd_print('%');
340
   lcd_print('%');
332
 
341
 
333
   // Status line
342
   // Status line
343
+  u8g.setFont(FONT_STATUSMENU);
334
   u8g.setPrintPos(0,63);
344
   u8g.setPrintPos(0,63);
335
   #ifndef FILAMENT_LCD_DISPLAY
345
   #ifndef FILAMENT_LCD_DISPLAY
336
     lcd_print(lcd_status_message);
346
     lcd_print(lcd_status_message);

Loading…
Cancel
Save