[跨平台 Mac/Win/Linux] 词典APP Medict (开发者预览版)讨论

sorry if you addressed this before, I just want to ask, How is css/html rendered? it uses chrome, or behaves like chrome? put differently, if I open a page in chrome, is that how the same page will look in medict?

Hi, this app is built based on Electron framework, and the core render engine is blink (just same as chrome). Hence, it will show what you see at Chrome browser. Actually, I’ve modified some dictionary content to support page internal jumping function (add some JavaScript code to support play voice and link jumping).

In conclusion, the Medict support latest CSS standard (just like chrome supports). Besides, some HTML tags like a-link or voice play button will be enhanced (but will not affect the look like in the page)

1 Like

nice. I look forward to trying it. css rendering is my biggest concern.

one more thing: does medict support ‘prefers-color-scheme’?

if so, is the preference based on the color scheme setting in medict, or that of the platform such as Windows? this matters to me because a PNG showing black ‘text’ and a transparent background is unreadable in dark mode, so I want it to trigger a filter on the PNG.

I know ‘prefers-color-scheme’ is broken on both MDict’s PC version and its Android app, but am unsure if that’s due to lack of browser support, or due to MDict not having an internal light/dark setting.

As your concerned point, I’ve just tested in my laptop, like this:

And the light or dark mode is decided by environment settings (windows or macOS preference). However, I can add a button to switch the dark or light mode in the content show box.

1 Like

Linux 一开始也是规模很小,但有一堆热心人帮忙提建议、甚至写代码。

GoldenDict 所用的软件架构时间久远,现在缺少维护。
我是希望 Medict 在发展的过程中,能略微统一一下对mdx开源格式的规范,减少兼容性问题。
例如我手头的GoldenDict不支持 古辞辨(增订本)白话反查文言 mdd所用的tif图片,所以要解包–把tif转为jpg等格式–把jpg后缀改为tif–打包回mdd,甚是麻烦。要是有规范明说不能用这种压缩算法的tif,那大家制作mdd时就不会使用这种格式的图片。

1 Like

Thank you for your work on this. It is no easy task!

In terms of core functionality, right now medict’s handling of @@@link is unexpected.
In my mdx, I have “滋” (U+6ECB, which does not have its own entry)redirected to both “滋”(U+2F90B)and (U+FA99):



in medict, the (redirected) target entries show up blank:

The above issue seems to be when a single search word redirects to more than one target.

Another scenario:



medict handles the search word “见” by only showing “見b” (basically, 见@見b, while skipping the 見 entry). The proper behavior is for 见 to redirect to 見, which is a headword. in this situation, medict’s sidebar does not show the 見 entry.

If I directly look up the 見 entry, “@@@LINK=見b” actually appears as text at the bottom of the entry (instead of being treated as a redirect).

Ideally, all the relevant entries should be shown together in the search results, instead of having to select the individual tabs. In other words, it should replicate MDict’s ‘union dictionary’ behavior. (I understand this is a core design issue, and cannot be easily achieved.)

Lastly, right now medict doesn’t have ‘zoom’, either by pressing CTRL +/- or using Mouse wheel +/-. In this respect, medict does not behave like Chrome (or FireFox and IE). I often use zoom on my browser and MDict. While I design all my mdx dictionaries to display text at the default “1em” size, this is in most cases too small for me to read comfortably, so zoom is essential. Also, images that depict text often require zoom, since the displayed ‘text’ appears in various sizes, depending on the dictionary and the image.

There are also issues involving font-face, but this is a thorny problem not just for medict but for all dictionary programs.


mdd 规范方面,
我自己也遇到过发音文件格式的问题,老的mdd文件有windows专属的音频格式文件,medict 也无法解析播放,和 tif 图片的问题是一样的,medict 本身希望能够推动词典格式的不断发展和规范化。但是目前medict还有很多问题,现阶段恐难以得到大家认可,我会在业余时间不断完善Medict,等到有一定可用性和一些用户了了会尝试推动这件事情。



  1. 很多词典都会卡死,祝早日搞定。
  2. 添加词典太繁琐了,名称、别名,这些信息都可以从MDX读取填充吧,最不济,也可以用文件名来作为默认名称,而不是必须用户手工输入。比如欧陆词典,只要拖曳、确定即可。虽然Medict就多了两步,我觉得体验特别不好。完全可以直接添加,配置里给一个界面可以修改相关信息。
  3. 编辑CSS也是大家经常会用到的,希望能增加一个右键直接编辑CSS,如果能实时预览CSS就更棒了。 Preview - 修改MDX CSS的神器,支持CSSJS实时预览
  4. 某些词条结构异常复杂,希望可以直接保存当前词典的html代码段为文件,同样便于调试。
  5. 直接集成MDX打包、解包。或单独出一个Medict专用的MDX打包工具,兼容其他词典。
  6. 从目录添加字典,nowill的GD mac版是支持的。
  7. 对英文各种变形、中文简繁、异体字的支持。为什么需要可以参考 :joy: 异体字害死人!看帖子《“這蚤晚”与“這蚤晩”相同吗?》,联想到我查询《漢語大詞典》词头时的奇葩事……


1 Like



1 Like

Medict 可以支持编辑CSS并实时生效的,可以看下面的图,不知道是不是这样的需求:
Kapture 2021-10-26 at 19.55.58

1 Like

是点bug图标吗,哈哈,和chrome调试一样,非常棒 :+1: 后面加个右键吧



这些 feature 一步一步增加吧,久久为功。



This is actually a bug, in the next version, I’ll fix word indexing problem firstly, and after this, please try to review this problem again, thanks very much.

This point has just discussed by someone, just shown as below:

In the next version, the most top-priority things is to solve the word-indexing problem and dictionaries group feature. I think those features can end up your problems which just mentioned.

Finally, the ‘Zoom-In/Zoom-Out’ function is a tiny problem, and I am planning to fix this at a later version.

1 Like

这个我觉得可以同全文索引一同支持,因为本身就是一个分词的过程,完成分词之后就可以实现倒排索引,先加到 TODO-list 中

1 Like



Can you make it for iOS and Android?

Technically, it’s possible, but I have to resolve Medict’s bugs first, and the js-mdict can integrated into react-native framework, which can support building IOS and Android app.

反馈两个问题:1. 词条列表中,目前上下键控制的是滚动条,期待的是切换词条,快速浏览。 2. 一个词条有多个entry时,不能正确显示,期待的是像其他词典那样显示为一个词条,合并释义。

1 Like