mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-30 22:20:21 +00:00
Add dive computer name to the dive plot
I want to have some way to show multiple dive computers, so start off by adding the name of the current one. So if we change dive computers, we'll see it. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
3a7f3ba880
commit
22aa6fa4ef
1 changed files with 6 additions and 0 deletions
|
@ -2017,6 +2017,12 @@ void plot(struct graphics_context *gc, struct dive *dive, scale_mode_t scale)
|
|||
cairo_close_path(gc->cr);
|
||||
cairo_stroke(gc->cr);
|
||||
|
||||
/* Put the dive computer name in the lower left corner */
|
||||
if (dc->model) {
|
||||
static const text_render_options_t computer = {10, TIME_TEXT, LEFT, MIDDLE};
|
||||
plot_text(gc, &computer, 0, 1, "%s", dc->model);
|
||||
}
|
||||
|
||||
if (GRAPHS_ENABLED) {
|
||||
plot_pp_gas_profile(gc, pi);
|
||||
plot_pp_text(gc, pi);
|
||||
|
|
Loading…
Reference in a new issue