Commit graph

218 commits

Author SHA1 Message Date
YiFang Xiao 5712f63b8e fix: slob truncated file check.
fix #1541
2024-06-14 22:53:45 +08:00
YiFang Xiao 1e37d760e2 fix: slob truncated file check.
fix #1541
2024-06-14 22:53:45 +08:00
Xiao Yi Fang 65e51b2313 fix: stardict unquoted attribute value 2024-06-12 20:09:15 +08:00
autofix-ci[bot] aa3b260c96
[autofix.ci] apply automated fixes 2024-06-12 07:55:57 +00:00
Xiao Yi Fang 5aa3eb13cf opt: remove mimetex.cgi logic 2024-06-12 15:54:04 +08:00
shenleban tongying e21d4c60a2 fix: convert DSL description line ends to <br> for HTML display. 2024-06-10 09:30:34 -04:00
shenleban tongying e6a2be83ae
fix: srcset of <img> in mdx format won't show image (#1536)
Co-authored-by: xiaoyifang <105986+xiaoyifang@users.noreply.github.com>
2024-05-29 09:07:23 -04:00
shenleban tongying 2cd6ed0756 fix: add timeout for sounddir modification scanning for super large
sound dir and/or slow filesystem
2024-05-09 21:04:22 -04:00
shenleban tongying f8c0e8cd17
clean: rename File::Class to what it is really used. 2024-03-23 00:29:51 -04:00
shenleban tongying 48fc8fceff clean: deprecations that won't break Qt5 compatibility 2024-03-21 21:48:43 -04:00
xiaoyifang be22cb22b6
fix: in portable version,the default content dir lost recursive attribute. (#1430)
* fix: allow edit the content path

* fix: portable version ,add default item

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-03-20 22:07:58 +08:00
shenleban tongying e8f3a94541
fix: soundDir index not updating when sounds modified (#1427) 2024-03-20 21:44:17 +08:00
shenleban tongying b9e14f806c
fix: CMake problems found by the openBSD package (#1422)
* fix: CMake problems found by openBSD package

* remove unused WITH_XAPIAN option
* don't link Qt TTS if not requested

* fix: address CMake problems found by openBSD package

* remove unused WITH_XAPIAN option
* don't link Qt TTS if not requested
* Disable some code when TTS is not requested

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-03-20 11:08:17 +08:00
YiFang Xiao 85333df5c2 opt: allow add directory in portable mode 2024-02-01 13:20:51 +08:00
YiFang Xiao 28924b5953 opt:refactor code 2024-01-27 10:56:34 +08:00
YiFang Xiao 0596ed5e45 opt: remove debug info 2024-01-26 15:50:01 +08:00
Xu Jiyong 853130ddb7
opt: add the language variant option for wikipedia dictionaries (#1374)
* opt: add the language variant option for wikipedia dictionaries

* fix:default value for 'lang_' parameter

* [autofix.ci] apply automated fixes

* fix: Should have been 'https' for the wikipedia queries.

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2024-01-26 07:56:17 +08:00
autofix-ci[bot] 6890a952b3
[autofix.ci] apply automated fixes 2023-12-30 10:15:05 +00:00
YiFang Xiao fa7b3db0bc opt: use qtcpsocket signal to implement the dictserver protocol 2023-12-30 18:13:36 +08:00
shenleban tongying cbf5cfee7a
clean: move dict implementations out of headers
class with Q_OBJECT can be defined .cpp file by including .moc
explicitly
2023-12-11 21:21:50 -05:00
YiFang Xiao 9a99b392e9 opt: skip mdx 3.0 dictionary 2023-11-12 19:21:57 +08:00
xiaoyifang b2a8eec2a5
fix: dsl encoding detection enhanced. (#1279)
* fix: detect dsl encoding

* [autofix.ci] apply automated fixes

---------

Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-11-11 16:17:58 +08:00
YiFang Xiao dd4812f086 fix: dictserver connect timeout change to 2 seconds 2023-11-07 20:54:02 +08:00
xiaoyifang 2bcf4890db opt: refactor database retrieve logic (#1272)
* opt: refactor database retrieve logic

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-11-07 20:53:05 +08:00
xiaoyifang 10595ab50e
fix: epwing dictionary parsing error (#1263)
* fix: epwing dictionary parsing error

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-10-29 12:26:58 +08:00
YiFang Xiao bdf5fed904 opt: wikipedia word list optimization 2023-10-27 11:23:52 +08:00
xiaoyifang 22f35dd7ee
opt: remove dictionary debug mode (#1249)
* opt: remove dictionary debug mode

* opt: remove dictionary debug mode
2023-10-19 07:37:42 +08:00
YiFang Xiao f0dcc362fa action: remove qt version from check action 2023-10-16 14:47:31 +08:00
xiaoyifang 5de4690b2d
fix: audio device change handled (#1242)
* fix: audio device change handled

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-10-15 23:15:45 +08:00
YiFang Xiao 5ec6d50167 fix: reduce wait time on socket 2023-10-13 20:18:33 +08:00
xiaoyifang e8a2eadade
opt: indexing dictionary in status bar does not disappear (#1234)
* opt: indexing dictionary name and progress

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-10-13 10:43:52 +08:00
YiFang Xiao 0da578c2a3 fix: dsl dictionary crash when creating full text index.
fix #1230
2023-10-12 14:53:08 +08:00
YiFang Xiao 245923a084 fix: allow video to be dragged around 2023-10-09 23:13:02 +08:00
xiaoyifang b1781b63d6
opt: remove gdpicture & maxPictureWidth which has not been used at all. (#1220)
* opt: remove gdpicture protocol which has lost effect for a long time

* opt: remove maxPictureWidth which has no place to configure this variable value

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

---------

Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-10-09 19:58:16 +08:00
xiaoyifang 64529805ff
fix: dsl max width image (#1217)
* fix: dsl max width image

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-10-09 14:06:38 +08:00
autofix-ci[bot] e3f6a2849c
[autofix.ci] apply automated fixes 2023-10-08 15:36:55 +00:00
YiFang Xiao 7ec51d9453 fix: use more meaningful tag name 2023-10-08 23:35:12 +08:00
YiFang Xiao 6f9fa8eaa7 fix: mdx audio/video html5 tag src value replacement
[autofix.ci] apply automated fixes
2023-10-08 23:35:09 +08:00
xiaoyifang ec2856336c
opt: add option to disable tts component (#1169)
* opt: add tts config option

* opt:[macos] disable tts by default

* [autofix.ci] apply automated fixes

* opt: add build flags to about dialog

---------

Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-09-26 11:09:05 +08:00
xiaoyifang d4f19cf4cd
fix: use wait condition to rewrite datarequest (#1015)
* fix: use wait condition for datarequest

* fix: rewrite byteAvailable

* [autofix.ci] apply automated fixes

* fix: rewrite qwaitcondition

* [autofix.ci] apply automated fixes

* opt: wait condition

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-09-10 19:02:31 +08:00
YiFang Xiao c865896216 fix: code smells 2023-09-02 15:20:30 +08:00
xiaoyifang e1e98a3c71
Merge pull request #1112 from xiaoyifang/opt/string-compare
opt: refactor the compare logic
2023-09-02 12:45:10 +08:00
autofix-ci[bot] c273622851
[autofix.ci] apply automated fixes 2023-09-02 04:24:55 +00:00
YiFang Xiao 4226abf593 opt: refactor the compare logic 2023-09-02 12:23:13 +08:00
YiFang Xiao 74a21e7e26 fix: epwing dictionary reference navigation restrict to certain dictionary 2023-09-02 11:33:53 +08:00
xiaoyifang 8313d93469
opt: refactor a string endswith method (#1110)
* opt: refactor a string endswith method

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-08-31 08:02:57 +08:00
YiFang Xiao 477f22c304 fix: code smells
[autofix.ci] apply automated fixes
2023-08-31 00:04:28 +08:00
YiFang Xiao 791da91645 fix: navigate through epwing dictionary restricted to certain dictionary 2023-08-30 23:10:19 +08:00
xiaoyifang 2dd04207d1
fix: skip invalid headword in some epwing dictionaries (#1096)
* fix: for some epwing dictionaries , skip invalid headword

fix #1095

* [autofix.ci] apply automated fixes

* fix: epwing detect next text block

* [autofix.ci] apply automated fixes

* fix: epwing getFirstHeadword do not need forwardtext

* fix: epwing ,if epwing subbook does not contain headword ,use menu instead

* [autofix.ci] apply automated fixes

* fix: if epwing subbook does not contain headword ,use menu instead

* [autofix.ci] apply automated fixes

* fix:code smells

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-08-30 19:12:59 +08:00
xiaoyifang ccd04e0b51
fix: epwing case sensitive (#1093)
* fix: epwing folder name is casesensitive in Linux

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-08-27 18:30:55 +08:00
xiaoyifang 98af55557e
fix: epwing rebuild issue (#1094)
* fix: epwing rebuild issue

* [autofix.ci] apply automated fixes

* fix: pro project file

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-08-27 10:15:21 +08:00
YiFang Xiao 78ef410b3b opt: ignore non-exist-files when calculate dictionaries files 2023-08-26 22:39:38 +08:00
xiaoyifang d02baad2ed
fix: epwing dictionary index twice (#1089)
* fix: epwing dictionary index twice

If epwing dictionary contain >1 subbooks, the following subbook will
overwrite the previous index which will cause a "duplicateId" warning
and the dictionary can be be queried.

fix #1082

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-08-26 21:41:57 +08:00
YiFang Xiao 60e39dff89 epwing: upgrade epwing index version 2023-08-26 17:26:50 +08:00
xiaoyifang 6ba8b0c16b
feat: add an option to make debug dictionary easier (#1086)
* feat: add an option to make debug dictionary easier

* fix: code smells

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-08-26 13:19:21 +08:00
YiFang Xiao 765cb91828 fix: generate icon name crash with 0 size 2023-08-11 08:41:43 +08:00
YiFang Xiao 82bcbaa8f4 fix: fts progress large than 100 2023-08-07 21:53:13 +08:00
YiFang Xiao e55027b5a0 fix: epwing remove unused method 2023-08-05 20:47:16 +08:00
YiFang Xiao a1de6ce637 opt: optimize the removeDirectory method 2023-08-05 19:36:33 +08:00
autofix-ci[bot] ecdd5166c2 [autofix.ci] apply automated fixes 2023-07-30 16:16:21 +08:00
YiFang Xiao 86eaf18121 opt: optimize the startup speed 2023-07-30 16:13:09 +08:00
YiFang Xiao 840b7ec12c fix: sonar warning about uninitialized variable
fix #1025
2023-07-30 10:48:49 +08:00
YiFang Xiao 03356fdfab fix: code smells 2023-07-30 08:47:54 +08:00
autofix-ci[bot] a90a79bce2
[autofix.ci] apply automated fixes 2023-07-29 16:54:22 +00:00
YiFang Xiao 2f118da828 opt: convert for loop into modern for range 2023-07-30 00:52:31 +08:00
YiFang Xiao fe1fd14e31 opt: optimize loading splash dialog with loading/check information
[autofix.ci] apply automated fixes
2023-07-30 00:52:28 +08:00
xiaoyifang 0585f5daa4
opt: auto-generate dictionary icon with color (#1021)
* opt: auto-generate dictionary icon with color

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-07-29 15:08:53 +08:00
YiFang Xiao 149f2bb7de fix: add handlePath log 2023-07-29 14:06:38 +08:00
YiFang Xiao ea94673a53 opt: remove unnecessary code 2023-07-27 17:26:44 +08:00
xiaoyifang dbb11e293b
opt: optimize the process of audio link which start with double // (#1008)
* opt: optimize the process of audio link which start with double //

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-07-26 23:03:03 +08:00
xiaoyifang 17cd445607
feat: customize dictionary's fullindex option with metadata.toml (#1000)
* feat: customize dictionary's fullindex option with metadata.toml

* [autofix.ci] apply automated fixes

* feat: display fulltext status in the dictionary info dialog

* [autofix.ci] apply automated fixes

* doc: add document about how to enable dictionary's fullindex feature

* Update src/metadata.cc

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update src/ui/dictinfo.ui

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/mkdocs.yml

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/docs/custom_dictionary.md

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/docs/custom_dictionary.md

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/docs/custom_dictionary.md

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/docs/custom_dictionary.md

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/docs/custom_dictionary.md

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* Update website/docs/custom_dictionary.md

Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>

* add images

* feat: show fulltext search status in dictionary info dialog

* Update dictinfo.cc

* [autofix.ci] apply automated fixes

* ui: change layout

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com>
Co-authored-by: shenleban tongying <shenlebantongying@gmail.com>
2023-07-26 10:03:20 +08:00
xiaoyifang d3e6018401
fix: wikipedia open blank page in edge browser (#1003)
* fix: wikipedia open blank page in edge browser

* [autofix.ci] apply automated fixes

---------

Co-authored-by: YiFang Xiao <yifang.xiao@noreply.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-07-25 23:55:41 +08:00
shenleban tongying a4542d8b6c
fix: a few build problems about zim/slob ,epwing (#992)
* fix: a few build problems

* slob should not depends on MAKE_ZIM_SUPPORT
* cmake failed to build when WITH_EPWING disabled.

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2023-07-22 13:50:57 +08:00
YiFang Xiao d25e054a93 opt: replace program dictionary icon 2023-07-21 15:53:53 +08:00
YiFang Xiao 0b087e40f1 opt: replace lsa dictionary icon and zipsound icon 2023-07-21 14:34:09 +08:00
YiFang Xiao 46d62ebf8c opt: replace sounddir dictionary icon 2023-07-21 14:10:40 +08:00
autofix-ci[bot] 0450422959
[autofix.ci] apply automated fixes 2023-07-20 08:05:17 +00:00
shenleban tongying b5349478cf
clean: reformat everything
The next commit will add `.git-blame-ignore-revs`

https://docs.github.com/en/repositories/working-with-files/using-files/viewing-a-file#ignore-commits-in-the-blame-view
2023-07-20 04:02:22 -04:00
shenleban tongying 1180f8bc32
fix: website/program should not appears in "AutoGroupByFolder" 2023-07-17 23:27:46 -04:00
xiaoyifang 55fef3e231
opt: use qcache to hold mdx css file (#970)
* opt: use qcache to hold mdx css file

* 🎨 apply clang-format changes

---------

Co-authored-by: xiaoyifang <xiaoyifang@users.noreply.github.com>
2023-07-17 21:51:56 +08:00
YiFang Xiao 119a5ccb6c fix: treat unknown dsl tags as text 2023-07-15 13:27:12 +08:00
YiFang Xiao 7037694ebc fix: code smell 2023-07-14 22:31:29 +08:00
YiFang Xiao 0dc0c015c7 opt: use seperate slob dictionary object to create the fulltext
🎨 apply clang-format changes
2023-07-12 21:14:57 +08:00
YiFang Xiao 40c890b5ca opt: boost slob fulltext speed
and reduce the impact to normal query when create slob fulltext index

🎨 apply clang-format changes
2023-07-12 20:57:02 +08:00
YiFang Xiao 568efee4c7 fix: unicode regex option support 2023-07-09 18:10:30 +08:00
xiaoyifang aeb98e2e57
Merge pull request #935 from xiaoyifang/fix/stardict-syn
opt: limit the number of stardict's extra synonym (from `.syn`) searching
2023-07-08 10:44:18 +08:00
YiFang Xiao 9ca02a1e23 opt: stardict's findHeadwordsForSynonym method does not seem necessary
🎨 apply clang-format changes

🎨 apply clang-format changes
2023-07-08 00:25:30 +08:00
YiFang Xiao 764ebdde35 fix: sounddir dictionary sound file name
🎨 apply clang-format changes
2023-07-07 21:40:38 +08:00
YiFang Xiao 9bbb23e5d4 fix: when search hypen alone will result too much unnecessary result.
fix #928
2023-07-06 15:24:01 +08:00
YiFang Xiao e971d2be67 opt: dsl target url 2023-07-01 14:08:48 +08:00
shenleban tongying fa27f32146
clean: unify how data added to dataRequestInstant 2023-06-24 17:36:10 -04:00
xiaoyifang 5d3f1a3e3d
Merge pull request #899 from shenlebantongying/datareq_append_str
clean: unify DataRequest string data appends
2023-06-24 14:28:01 +08:00
shenleban tongying e06606ba3c
clean: unify DataRequest string data appends 2023-06-23 12:23:32 -04:00
YiFang Xiao f909413caa fix: code smells 2023-06-23 09:28:35 +08:00
YiFang Xiao 3b935e7660 fix: possible null object
refactor: group widget currentindex logic
2023-06-22 21:30:30 +08:00
xiaoyifang 04a58d6418
opt: dsl remove useless method and refactor langcodes logic (#889)
* opt: dsl remove useless method and refactor langcodes logic

* 🎨 apply clang-format changes

* opt: remove useless code

---------

Co-authored-by: xiaoyifang <xiaoyifang@users.noreply.github.com>
2023-06-21 20:47:49 +08:00
shenleban tongying 4432de9d50
clean: remove duplicated exCantReadFile definitions
Obviously, it is a result of copy-paste programming
2023-06-19 18:54:17 -04:00
shenleban tongying a76ef3dfdd
guard against null img for ZIM 2023-06-19 05:01:27 -04:00
shenleban tongying 1589e14b70
clean: remove redundant dictionaryNativeIcon
`dictionaryNativeIcon` was intended to access the original icon before none-square icons were transformed into squares.

`dictionaryNativeIcon` is only used in dictionaryBar, but according to the intention, it shouldn't.

In reality, `dictionaryNativeIcon` is almost always equal to `dictionaryIcon`.
2023-06-18 22:37:07 -04:00
shenleban tongying feda879a30
feat: load and display ZIM dictionary icon
* Original GD never tries to load zim format's icon
* This leverage the capability provided by libzim
2023-06-18 05:25:38 -04:00