[Meter] Remove Bar borders

This is an experiment in Tufte-ism
wilder
Jacopo De Simoi 2 years ago
parent c597c22869
commit d6cd850dbb
  1. 13
      Meter.c

@ -76,18 +76,11 @@ static void BarMeterMode_draw(Meter* this, int x, int y, int w) {
attrset(CRT_colors[METER_TEXT]);
int captionLen = 3;
mvaddnstr(y, x, caption, captionLen);
x += captionLen;
w -= captionLen;
// Draw the bar borders
attrset(CRT_colors[BAR_BORDER]);
mvaddch(y, x, '[');
w--;
mvaddch(y, x + MAXIMUM(w, 0), ']');
w--;
x += captionLen+1;
w -= captionLen+1;
attrset(CRT_colors[RESET_COLOR]);
x++;
if (caption[0] == 0) {
if (w < 1) {
return;

Loading…
Cancel
Save