1
0
Fork 0

cosmetics

This commit is contained in:
mfranz 2006-08-01 18:46:59 +00:00
parent 3f1af3334f
commit b1a4fa24d4
2 changed files with 14 additions and 12 deletions

View file

@ -520,7 +520,7 @@ void HUD::Ladder::draw(void)
y_end = y;
if (i == 0) {
// Make zero point wider on left
// make zero point wider
x_ini -= zero_offset;
x_end2 += zero_offset;
@ -531,7 +531,7 @@ void HUD::Ladder::draw(void)
draw_text(x_end2 + 2.0, y, buf, VCENTER|LEFT);
} else if (i > 0) {
//draw climb bar vertical lines
// draw climb bar vertical lines
draw_line(x_ini, y - 5.0, x_ini, y);
draw_line(x_end2, y - 5.0, x_end2, y);

View file

@ -341,14 +341,15 @@ void HUD::Tape::draw(void) // (HUD_scale * pscale)
if (!option_notext()) {
float l, r, b, t;
_hud->_text_list.align(buf, align, &x, &y, &l, &r, &b, &t);
if (b < _y || t > top)
continue;
if (_label_gap == 0.0)
draw_text(x, y, buf);
else if (b < _center_y - _label_gap && t < _center_y - _label_gap)
draw_text(x, y, buf);
else if (b > _center_y + _label_gap && t > _center_y + _label_gap)
if (_label_gap == 0.0
|| b < _center_y - _label_gap && t < _center_y - _label_gap
|| b > _center_y + _label_gap && t > _center_y + _label_gap) {
draw_text(x, y, buf);
}
}
}
}
@ -522,14 +523,15 @@ void HUD::Tape::draw(void) // (HUD_scale * pscale)
if (!option_notext()) {
float l, r, b, t;
_hud->_text_list.align(buf, align, &x, &y, &l, &r, &b, &t);
if (l < _x || r > right)
continue;
if (_label_gap == 0.0)
draw_text(x, y, buf);
else if (l < _center_x - _label_gap && r < _center_x - _label_gap)
draw_text(x, y, buf);
else if (l > _center_x + _label_gap && r > _center_x + _label_gap)
if (_label_gap == 0.0
|| l < _center_x - _label_gap && r < _center_x - _label_gap
|| l > _center_x + _label_gap && r > _center_x + _label_gap) {
draw_text(x, y, buf);
}
}
}
} // end for