mirror of
https://github.com/eried/portapack-mayhem.git
synced 2024-10-01 01:26:06 -04:00
use screen_rect for center coordinate
This commit is contained in:
parent
abb4385859
commit
2969a0fec9
@ -169,9 +169,9 @@ void GeoMap::paint(Painter& painter) {
|
||||
display.fill_rectangle({ r.center() - Point(16, 1), { 32, 2 } }, Color::red());
|
||||
display.fill_rectangle({ r.center() - Point(1, 16), { 2, 32 } }, Color::red());
|
||||
} else {
|
||||
//coordinates could probably be calculted off screen_rect()?
|
||||
draw_bearing({ 120, 16 + 48 + 128 }, angle_, 10, Color::red());
|
||||
painter.draw_string({ 120 - ((int)tag_.length() * 8 / 2), 16 + 48 + 128 - 32 }, style(), tag_);
|
||||
draw_bearing(r.center(), angle_, 10, Color::red());
|
||||
//center tag above bearing
|
||||
painter.draw_string(r.center() - Point(((int)tag_.length() * 8 / 2), 2 * 16), style(), tag_);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user