From 3ea5ebeebfd00c929eb3ea6b211b8288f70adf3a Mon Sep 17 00:00:00 2001 From: YiFang Xiao Date: Sun, 21 May 2023 11:58:24 +0800 Subject: [PATCH] ocr: add how to series doc: move howto to website --- .github/workflows/macos-homebrew-PR-check.yml | 1 + .github/workflows/ubuntu-PR-check.yml | 2 + .github/workflows/windows-PR-check.yml | 2 + howto/how to connect with anki.md | 39 --------------- howto/how to debug html with qtcreator.md | 13 ----- ...How to use ocr together with GoldenDict.md | 0 .../how to build and debug with VS2019.md | 0 .../how to build ffmpeg for visual studio.md | 0 .../docs/howto}/how to compile with cmake.md | 0 .../howto}/how to customize the opencc.md | 0 ... version and module in github qt action.md | 0 ...to use .clang-format to format the code.md | 0 .../how to use breadpad crash analysis.md | 0 website/docs/topic_anki.md | 50 +++++++++++++++++-- website/mkdocs.yml | 9 ++++ 15 files changed, 59 insertions(+), 57 deletions(-) delete mode 100644 howto/how to connect with anki.md delete mode 100644 howto/how to debug html with qtcreator.md rename {howto => website/docs/howto}/How to use ocr together with GoldenDict.md (100%) rename {howto => website/docs/howto}/how to build and debug with VS2019.md (100%) rename {howto => website/docs/howto}/how to build ffmpeg for visual studio.md (100%) rename {howto => website/docs/howto}/how to compile with cmake.md (100%) rename {howto => website/docs/howto}/how to customize the opencc.md (100%) rename {howto => website/docs/howto}/how to find out the latest qt version and module in github qt action.md (100%) rename {howto => website/docs/howto}/how to use .clang-format to format the code.md (100%) rename {howto => website/docs/howto}/how to use breadpad crash analysis.md (100%) diff --git a/.github/workflows/macos-homebrew-PR-check.yml b/.github/workflows/macos-homebrew-PR-check.yml index 99805e93..ca1ce193 100644 --- a/.github/workflows/macos-homebrew-PR-check.yml +++ b/.github/workflows/macos-homebrew-PR-check.yml @@ -17,6 +17,7 @@ on: - "howto/**" - "*.md" - "locale/**" + - "website/**" jobs: build: name: Build diff --git a/.github/workflows/ubuntu-PR-check.yml b/.github/workflows/ubuntu-PR-check.yml index 9bae3f2e..34583b0f 100644 --- a/.github/workflows/ubuntu-PR-check.yml +++ b/.github/workflows/ubuntu-PR-check.yml @@ -17,6 +17,8 @@ on: - "howto/**" - "*.md" - "locale/**" + - "website/**" + jobs: build: name: Build diff --git a/.github/workflows/windows-PR-check.yml b/.github/workflows/windows-PR-check.yml index 76b02de7..b68a207c 100644 --- a/.github/workflows/windows-PR-check.yml +++ b/.github/workflows/windows-PR-check.yml @@ -17,6 +17,8 @@ on: - "howto/**" - "*.md" - "locale/**" + - "website/**" + jobs: build: name: Build diff --git a/howto/how to connect with anki.md b/howto/how to connect with anki.md deleted file mode 100644 index b2953de6..00000000 --- a/howto/how to connect with anki.md +++ /dev/null @@ -1,39 +0,0 @@ -# prerequisite -1. install anki -2. install ankiconnect - -# configure anki - -## 1. create a new model, or use an existing model - -For example, the model could have `Front` and `Back` fields. - -![Snipaste_2022-05-21_14-08-21](https://user-images.githubusercontent.com/105986/169638410-c6aa8038-df03-40de-8731-9f0b9f43bf59.png) -## 2. configure the template -the front template - -![image](https://user-images.githubusercontent.com/105986/169638457-2358d020-0132-469f-a6b4-0fb6d1590fa2.png) -the back template - -![image](https://user-images.githubusercontent.com/105986/169638440-7191fcdd-c338-48a3-a899-7216a5c77425.png) - -# configure goldendict -## 1. through toolbar=>preference=>network -![screenshot](https://user-images.githubusercontent.com/69171671/224496944-dbf31d6e-26be-42c9-98fc-257f70a8428e.png) - -* Word - Vocabulary headword. -* Text - Selected definition. -* Sentence - Search string. You can leave it blank. - -**Example for adding Japanese sentences:** -![screenshot](https://user-images.githubusercontent.com/69171671/224497112-ab027a16-89b2-48d8-8308-a3dbb5b9e1e4.png) - -## 2. action -![image](https://user-images.githubusercontent.com/105986/169638740-abecde84-d33b-45ce-932c-d465c6650334.png) -## 3. result - -**Word and definition:** -![image](https://user-images.githubusercontent.com/105986/169638761-f67c009d-27cd-440d-bafa-ebbdce9577e3.png) - -**Sentence, word, and definition:** -![screenshot](https://user-images.githubusercontent.com/69171671/224497528-889d6393-e04d-4af7-b1a7-816ba010f2b2.png) diff --git a/howto/how to debug html with qtcreator.md b/howto/how to debug html with qtcreator.md deleted file mode 100644 index bb7f327f..00000000 --- a/howto/how to debug html with qtcreator.md +++ /dev/null @@ -1,13 +0,0 @@ -Developers need to check the html occassionly. - -based on qtcreator. - -Steps: -1. set enviroment variable QTWEBENGINE_REMOTE_DEBUGGING=10000 -![image](https://user-images.githubusercontent.com/105986/142788556-f97a6d21-21ea-4e65-862a-5f63bd198bae.png) - -2.run goldendict project - -3.open chrome ,and navigate to http://localhost:10000 - -4.in goldendict ,right mouse menu ,select "Inspect",this will navigate to the corresponding element in the chrome. diff --git a/howto/How to use ocr together with GoldenDict.md b/website/docs/howto/How to use ocr together with GoldenDict.md similarity index 100% rename from howto/How to use ocr together with GoldenDict.md rename to website/docs/howto/How to use ocr together with GoldenDict.md diff --git a/howto/how to build and debug with VS2019.md b/website/docs/howto/how to build and debug with VS2019.md similarity index 100% rename from howto/how to build and debug with VS2019.md rename to website/docs/howto/how to build and debug with VS2019.md diff --git a/howto/how to build ffmpeg for visual studio.md b/website/docs/howto/how to build ffmpeg for visual studio.md similarity index 100% rename from howto/how to build ffmpeg for visual studio.md rename to website/docs/howto/how to build ffmpeg for visual studio.md diff --git a/howto/how to compile with cmake.md b/website/docs/howto/how to compile with cmake.md similarity index 100% rename from howto/how to compile with cmake.md rename to website/docs/howto/how to compile with cmake.md diff --git a/howto/how to customize the opencc.md b/website/docs/howto/how to customize the opencc.md similarity index 100% rename from howto/how to customize the opencc.md rename to website/docs/howto/how to customize the opencc.md diff --git a/howto/how to find out the latest qt version and module in github qt action.md b/website/docs/howto/how to find out the latest qt version and module in github qt action.md similarity index 100% rename from howto/how to find out the latest qt version and module in github qt action.md rename to website/docs/howto/how to find out the latest qt version and module in github qt action.md diff --git a/howto/how to use .clang-format to format the code.md b/website/docs/howto/how to use .clang-format to format the code.md similarity index 100% rename from howto/how to use .clang-format to format the code.md rename to website/docs/howto/how to use .clang-format to format the code.md diff --git a/howto/how to use breadpad crash analysis.md b/website/docs/howto/how to use breadpad crash analysis.md similarity index 100% rename from howto/how to use breadpad crash analysis.md rename to website/docs/howto/how to use breadpad crash analysis.md diff --git a/website/docs/topic_anki.md b/website/docs/topic_anki.md index c1aa2bfd..307e3020 100644 --- a/website/docs/topic_anki.md +++ b/website/docs/topic_anki.md @@ -1,5 +1,49 @@ # Anki Integration + + +# prerequisite +1. install anki +2. install ankiconnect + +# configure anki + +## 1. create a new model, or use an existing model + +For example, the model could have `Front` and `Back` fields. + +![Snipaste_2022-05-21_14-08-21](https://user-images.githubusercontent.com/105986/169638410-c6aa8038-df03-40de-8731-9f0b9f43bf59.png) +## 2. configure the template +the front template + +![image](https://user-images.githubusercontent.com/105986/169638457-2358d020-0132-469f-a6b4-0fb6d1590fa2.png) +the back template + +![image](https://user-images.githubusercontent.com/105986/169638440-7191fcdd-c338-48a3-a899-7216a5c77425.png) + +# configure goldendict +## 1. through toolbar=>preference=>network +![screenshot](https://user-images.githubusercontent.com/69171671/224496944-dbf31d6e-26be-42c9-98fc-257f70a8428e.png) + +* Word - Vocabulary headword. +* Text - Selected definition. +* Sentence - Search string. You can leave it blank. + +**Example for adding Japanese sentences:** +![screenshot](https://user-images.githubusercontent.com/69171671/224497112-ab027a16-89b2-48d8-8308-a3dbb5b9e1e4.png) + +## 2. action +![image](https://user-images.githubusercontent.com/105986/169638740-abecde84-d33b-45ce-932c-d465c6650334.png) +## 3. result + +**Word and definition:** +![image](https://user-images.githubusercontent.com/105986/169638761-f67c009d-27cd-440d-bafa-ebbdce9577e3.png) + +**Sentence, word, and definition:** +![screenshot](https://user-images.githubusercontent.com/69171671/224497528-889d6393-e04d-4af7-b1a7-816ba010f2b2.png) + + + ## Using URI schemes `goldendict://word` link can be use to query a word directly on Goldendict. @@ -10,8 +54,4 @@ On your Anki card's template, you can add the code below to have a "1 click open {{Front}} ``` -Note that this feature doesn't available on macOS - -## AnkiConnects - -See [how to connect with anki.md](https://github.com/xiaoyifang/goldendict/blob/staged/howto/how%20to%20connect%20with%20anki.md) \ No newline at end of file +Note that this feature doesn't available on macOS \ No newline at end of file diff --git a/website/mkdocs.yml b/website/mkdocs.yml index 502f1350..cd36d956 100644 --- a/website/mkdocs.yml +++ b/website/mkdocs.yml @@ -42,7 +42,16 @@ nav: - Portable Mode: topic_portablemode.md - Custom transliteration: topic_transliteration.md - Customize Dictionary Name: custom_dictionary_name.md + - OCR Integration: howto/How to use ocr together with GoldenDict.md - Report Bugs & Feedbacks: feedbacks.md - Contributor Guides: - Developer: developer.md + - How to: + - Build and debug with VS2019: howto/how to build and debug with VS2019.md + - Compile with cmake: howto/how to compile with cmake.md + - Customize the opencc: howto/how to customize the opencc.md + - Qt version and github action: howto/how to find out the latest qt version and module in github qt action.md + - Use .clang-format: howto/how to use .clang-format to format the code.md + - Breadpad crash analysis: howto/how to use breadpad crash analysis.md + - Build ffmpeg on Windows: howto/how to build ffmpeg for visual studio.md - 中文文档: index_cn.md