summaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Gehad elrobey <gehadelrobey@gmail.com>2015-07-26 14:59:59 +0200
committerGravatar Lubomir I. Ivanov <neolit123@gmail.com>2015-07-28 11:37:49 +0300
commitb37498d35515ba981fe0de1f19f048f5e3dbb975 (patch)
tree7d434da4eb31677d095a6faf687217eda30bee4e /qt-ui
parent61a8ac09b03a47cc728834765f6c652a20ce8a3f (diff)
downloadsubsurface-b37498d35515ba981fe0de1f19f048f5e3dbb975.tar.gz
Printing: add member function to print options
Get the currently selected template. Signed-off-by: Gehad elrobey <gehadelrobey@gmail.com> Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/printoptions.cpp5
-rw-r--r--qt-ui/printoptions.h1
2 files changed, 6 insertions, 0 deletions
diff --git a/qt-ui/printoptions.cpp b/qt-ui/printoptions.cpp
index 223dfab93..6cfbed481 100644
--- a/qt-ui/printoptions.cpp
+++ b/qt-ui/printoptions.cpp
@@ -96,3 +96,8 @@ void PrintOptions::on_editButton_clicked()
te.exec();
setup();
}
+
+QString PrintOptions::getSelectedTemplate()
+{
+ return ui.printTemplate->currentData().toString();
+}
diff --git a/qt-ui/printoptions.h b/qt-ui/printoptions.h
index 326935b8c..b9912d2ed 100644
--- a/qt-ui/printoptions.h
+++ b/qt-ui/printoptions.h
@@ -53,6 +53,7 @@ class PrintOptions : public QWidget {
public:
explicit PrintOptions(QWidget *parent, struct print_options *printOpt, struct template_options *templateOpt);
void setup();
+ QString getSelectedTemplate();
private:
Ui::PrintOptions ui;