diff --git a/src/ui/ChewingEditor.ui b/src/ui/ChewingEditor.ui
index 9b75637..9eadfba 100644
--- a/src/ui/ChewingEditor.ui
+++ b/src/ui/ChewingEditor.ui
@@ -92,6 +92,7 @@
+
@@ -122,6 +123,14 @@
QAction::AboutQtRole
+
+
+ Documentation
+
+
+ QAction::ApplicationSpecificRole
+
+
E&xit
diff --git a/src/view/ChewingEditor.cpp b/src/view/ChewingEditor.cpp
index 45bcfa1..464c5bd 100644
--- a/src/view/ChewingEditor.cpp
+++ b/src/view/ChewingEditor.cpp
@@ -24,6 +24,7 @@
#include
#include
#include
+#include
#include "ChewingImporter.h"
#include "ChewingExporter.h"
@@ -191,6 +192,10 @@ void ChewingEditor::showAbout()
aboutBox.exec();
}
+void ChewingEditor::showDocumentation(){
+ QDesktopServices::openUrl(QUrl("https://github.com/chewing/chewing-editor/wiki"));
+}
+
void ChewingEditor::showDeleteConfirmWindow()
{
QString text = tr("Do you want to delete this phrase?");
@@ -355,4 +360,7 @@ void ChewingEditor::setupAboutWidget()
connect(
ui_.get()->actionAbout, SIGNAL(triggered()), this, SLOT(showAbout())
);
+ connect(
+ ui_.get()->actionDocumentation, SIGNAL(triggered()), this, SLOT(showDocumentation())
+ );
}
diff --git a/src/view/ChewingEditor.h b/src/view/ChewingEditor.h
index 99ac16a..a4b846d 100644
--- a/src/view/ChewingEditor.h
+++ b/src/view/ChewingEditor.h
@@ -48,6 +48,7 @@ public slots:
void selectExportFile();
void finishFileSelection(const QString& file);
void showAbout();
+ void showDocumentation();
void showDeleteConfirmWindow();
private: