From 18fa359b481893bf2ef71cfbb676efbd9601204b Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Sat, 24 May 2014 06:42:10 -0700 Subject: Rework the Export dialog The UI design looked too tight in my screen. The explanation texts were a bit inconsistent (and in one case simply wrong). The explanation for the initial selection wasn't shown. Signed-off-by: Dirk Hohndel --- qt-ui/divelogexportdialog.cpp | 16 ++++++++++----- qt-ui/divelogexportdialog.h | 1 + qt-ui/divelogexportdialog.ui | 48 +++++++++++++++++++++---------------------- 3 files changed, 36 insertions(+), 29 deletions(-) diff --git a/qt-ui/divelogexportdialog.cpp b/qt-ui/divelogexportdialog.cpp index 94b9c9fc9..cc59b2e6d 100644 --- a/qt-ui/divelogexportdialog.cpp +++ b/qt-ui/divelogexportdialog.cpp @@ -15,6 +15,7 @@ DiveLogExportDialog::DiveLogExportDialog(QWidget *parent) : QDialog(parent), ui(new Ui::DiveLogExportDialog) { ui->setupUi(this); + showExplanation(); QShortcut *quit = new QShortcut(QKeySequence(Qt::CTRL + Qt::Key_Q), this); connect(quit, SIGNAL(activated()), parent, SLOT(close())); QShortcut *close = new QShortcut(QKeySequence(Qt::CTRL + Qt::Key_W), this); @@ -26,19 +27,24 @@ DiveLogExportDialog::~DiveLogExportDialog() delete ui; } -void DiveLogExportDialog::on_exportGroup_buttonClicked(QAbstractButton *button) +void DiveLogExportDialog::showExplanation() { if (ui->exportUDDF->isChecked()) { - ui->description->setText("UDDF is a generic format that enables communication among many dive computers and computer programs"); + ui->description->setText("Generic format that is used for data exchange between a variety of diving related programs."); } else if (ui->exportCSV->isChecked()) { - ui->description->setText("CSV format, that includes the most critical information of the dive profile."); + ui->description->setText("Comma separated values that include the most relevant information of the dive profile."); } else if (ui->exportDivelogs->isChecked()) { - ui->description->setText("Subsurface XML format. This is the native format used by Subsurface."); + ui->description->setText("Send the dive data to Divelogs.de website."); } else if (ui->exportWorldMap->isChecked()) { - ui->description->setText("Export the currently open dive logbook locations in HTML format and draw these on a world map."); + ui->description->setText("HTML export of the dive locations, visualized on a world map."); } } +void DiveLogExportDialog::on_exportGroup_buttonClicked(QAbstractButton *button) +{ + showExplanation(); +} + void DiveLogExportDialog::on_buttonBox_accepted() { QFileInfo fi(system_default_filename()); diff --git a/qt-ui/divelogexportdialog.h b/qt-ui/divelogexportdialog.h index 8020b481c..92510a7aa 100644 --- a/qt-ui/divelogexportdialog.h +++ b/qt-ui/divelogexportdialog.h @@ -22,6 +22,7 @@ slots: private: Ui::DiveLogExportDialog *ui; + void showExplanation(); }; #endif // DIVELOGEXPORTDIALOG_H diff --git a/qt-ui/divelogexportdialog.ui b/qt-ui/divelogexportdialog.ui index e5dc77083..c937308e1 100644 --- a/qt-ui/divelogexportdialog.ui +++ b/qt-ui/divelogexportdialog.ui @@ -59,10 +59,10 @@ - 30 - 100 - 120 - 141 + 20 + 70 + 161 + 171 @@ -71,8 +71,8 @@ - 0 - 20 + 10 + 30 110 24 @@ -90,14 +90,14 @@ - 0 - 50 - 110 + 10 + 60 + 131 24 - divelogs + divelogs.de exportGroup @@ -106,8 +106,8 @@ - 0 - 80 + 10 + 90 110 24 @@ -122,8 +122,8 @@ - 0 - 110 + 10 + 120 110 24 @@ -140,9 +140,9 @@ 190 - 100 - 151 - 80 + 70 + 191 + 141 @@ -155,8 +155,8 @@ 10 - 20 - 131 + 30 + 151 24 @@ -171,7 +171,7 @@ 10 - 50 + 60 110 24 @@ -197,10 +197,10 @@ - 40 - 270 - 271 - 71 + 30 + 260 + 341 + 91 -- cgit v1.2.3-70-g09d2