summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/divelogexportdialog.cpp
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2019-01-04 22:52:35 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2019-01-26 07:10:29 -0800
commit2d8a8f974bcb4e87ee8754bb965003310bb359be (patch)
treedc55244f6e99884e5299f6ad13d7f7488ecf155c /desktop-widgets/divelogexportdialog.cpp
parentdece8d1ba4447ce0de8f29948358320f4932ce65 (diff)
downloadsubsurface-2d8a8f974bcb4e87ee8754bb965003310bb359be.tar.gz
Include dive time in TeX/LaTeX export
This was missing in the export. We export separate hour and minutes so the template can decide about the time format. Signed-off-by: Robert C. Helling <helling@atdotde.de>
Diffstat (limited to 'desktop-widgets/divelogexportdialog.cpp')
-rw-r--r--desktop-widgets/divelogexportdialog.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/desktop-widgets/divelogexportdialog.cpp b/desktop-widgets/divelogexportdialog.cpp
index 0df71f7ba..3e8bb3584 100644
--- a/desktop-widgets/divelogexportdialog.cpp
+++ b/desktop-widgets/divelogexportdialog.cpp
@@ -327,6 +327,8 @@ void DiveLogExportDialog::export_TeX(const char *filename, const bool selected_o
put_format(&buf, "\n%% Time, Date, and location:\n");
put_format(&buf, "\\def\\%sdate{%04u-%02u-%02u}\n", ssrf,
tm.tm_year, tm.tm_mon+1, tm.tm_mday);
+ put_format(&buf, "\\def\\%shour{%02u}\n", ssrf, tm.tm_hour);
+ put_format(&buf, "\\def\\%sminute{%02u}\n", ssrf, tm.tm_min);
put_format(&buf, "\\def\\%snumber{%d}\n", ssrf, dive->number);
put_format(&buf, "\\def\\%splace{%s}\n", ssrf, site ? site->name : "");
put_format(&buf, "\\def\\%sspot{}\n", ssrf);