summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkintel <kintel@b57f626f-c46c-0410-a088-ec61d464b74c>2009-12-12 22:19:53 (GMT)
committerkintel <kintel@b57f626f-c46c-0410-a088-ec61d464b74c>2009-12-12 22:19:53 (GMT)
commit63ea5d509ca1432d718806e01d5f6553fa993cd4 (patch)
tree1799a3d4f0fd5d0e32db61dd7040d9aaa3989535
parent4564d9d4a2370bec2da0aca36e192c7d5da472d7 (diff)
Launch manual from Help menu
git-svn-id: http://svn.clifford.at/openscad/trunk@166 b57f626f-c46c-0410-a088-ec61d464b74c
-rw-r--r--MainWindow.h1
-rw-r--r--MainWindow.ui6
-rw-r--r--mainwin.cc8
3 files changed, 15 insertions, 0 deletions
diff --git a/MainWindow.h b/MainWindow.h
index 1019780..c08e369 100644
--- a/MainWindow.h
+++ b/MainWindow.h
@@ -112,6 +112,7 @@ public slots:
void dragEnterEvent(QDragEnterEvent *event);
void dropEvent(QDropEvent *event);
void helpAbout();
+ void helpManual();
};
#endif
diff --git a/MainWindow.ui b/MainWindow.ui
index 962dee6..607c73c 100644
--- a/MainWindow.ui
+++ b/MainWindow.ui
@@ -179,6 +179,7 @@
<string>Help</string>
</property>
<addaction name="helpActionAbout"/>
+ <addaction name="helpActionManual"/>
</widget>
<addaction name="menu_File"/>
<addaction name="menu_Edit"/>
@@ -552,6 +553,11 @@
<string>About</string>
</property>
</action>
+ <action name="helpActionManual">
+ <property name="text">
+ <string>OpenSCAD Manual</string>
+ </property>
+ </action>
</widget>
<customwidgets>
<customwidget>
diff --git a/mainwin.cc b/mainwin.cc
index 9bd6889..3361cc0 100644
--- a/mainwin.cc
+++ b/mainwin.cc
@@ -41,6 +41,7 @@
#include <QUrl>
#include <QTimer>
#include <QMessageBox>
+#include <QDesktopServices>
//for chdir
#include <unistd.h>
@@ -203,6 +204,7 @@ MainWindow::MainWindow(const char *filename)
// Help menu
connect(this->helpActionAbout, SIGNAL(triggered()), this, SLOT(helpAbout()));
+ connect(this->helpActionManual, SIGNAL(triggered()), this, SLOT(helpManual()));
console->setReadOnly(true);
@@ -1337,3 +1339,9 @@ MainWindow::helpAbout()
QMessageBox::information(this, "About OpenSCAD", helptext);
}
+void
+MainWindow::helpManual()
+{
+ QDesktopServices::openUrl(QUrl("http://en.wikibooks.org/wiki/OpenSCAD_User_Manual"));
+}
+
contact: Jan Huwald // Impressum