leoyoon-tsaw / rime_collections Goto Github PK
View Code? Open in Web Editor NEWAll collections for Rime IME
All collections for Rime IME
开关中使用options设置多套字符集过滤,请问在key_binder里面应该怎么快捷键?
……
switches:
- name: ascii_mode
reset: 0
states: [ 中文, 西文 ]
- name: full_shape
states: [ 半角, 全角 ]
- options: [ gb2312, gbk, utf-8 ]
states:
- 字集 → GB2312
- 字集 → GBK
- 字集 → UTF-8
reset: 0
……
filters:
- charset_filter@gb2312
- charset_filter@gbk
- charset_filter@utf-8
……
key_binder:
import_preset: default
bindings:
- {accept: semicolon, send: 2, when: has_menu}
- {accept: apostrophe, send: 3, when: has_menu}
- {accept: Control+Shift+g, toggle: gbk, when: always}
这样写在schema文件中无效,请问应该如何设置,谢谢
由于 Rime 不再内置袖珍简化字拼音,我想尝试能否用明月拼音实现简体形码的反查。以 wubi86
为例,我的思路如下:
添加如下条目
engine/segmentors/affix_segmentor@pinyin
engine/translators/script_translator@pinyin
recognizer/patterns/pinyin: "`[a-z]*;?$"
pinyin:
tag: pinyin
prefix: "`"
dictionary: luna_pinyin
tips: 【拼音】
engine/filters:
- simplifier
- reverse_lookup_filter@pinyin_lookup
pinyin_lookup:
tags: [ pinyin ]
dictionary: wubi86
overwrite_comment: true
按照我的设想,当输入反查码时,反查码会打上 pinyin
标签从而由 pinyin
副翻译器翻译,翻译得到的结果首先通过 simplifier
滤镜得到简体字,然后通过 pinyin_lookup
滤镜得到五笔编码。但是实际上按这种方式得到的五笔编码仍然是繁体的,如「体」字的反查结果是繁体编码(memu)而不是简体编码(wsgg),如下:
那么,结果表明 pinyin_lookup
并没有在 simplifier
之后响应,而是在其之前响应,这是否意味着 reverse_lookup_filter
与其他滤镜的行为不同,它不是按 filters
中指定的顺序进行响应,而是在翻译完成后立刻响应?
如果是的话,还有没有其他方式可以实现这个需求?
那 ctrl 或者 command 对应的键位应该怎么写呢?或者 在哪里可以查的到吗?
想参照 easy_en 自己做个小语种的输入方案,但是不知道 dict.yaml 当中的词频 weight 是如何得出的。
求教🙏
我按照 rime/home 提及的这个wiki 中 'key_binder: 下設bindings: ' 进行配置 (在default.custom.yaml
配置,然后在easy_en.schema.yaml
调用的), 但是运行 fcitx5
终端会显示
I20230401 09:54:45.861925 4224 config_data.cc:71] loading config file '/home/czg/.local/share/fcitx5/rime/build/easy_en.schema.yaml'.
E20230401 09:54:45.864711 4224 key_event.cc:72] parse error: unrecognized modifier 'Super_L'
W20230401 09:54:45.864759 4224 key_binder.cc:191] invalid key binding #1.
E20230401 09:54:45.864980 4224 key_event.cc:72] parse error: unrecognized modifier 'Super_L'
W20230401 09:54:45.865005 4224 key_binder.cc:191] invalid key binding #1.
W20230401 09:54:45.865165 4224 punctuator.cc:32] missing punctuation mapping.
version env
$ pacman -Qs rime
local/fcitx5-rime 5.0.16-1
RIME support for Fcitx5
local/librime 1:1.8.5-1
Rime input method engine
local/librime-data 0.0.0.20220409-1
Meta package of preset librime data
...
'default.custom.yaml'
...
key_binder/bindings: # 设置哪些键可以翻页,需要哪个取消注释即可
# - { when: composing, accept: Tab, send: Page_Up } # Tab 翻页
- { when: composing, accept: Tab, send: Right } # Tab 移动光标向右
- { when: composing, accept: Super_L+Shift_L, send: Page_Up }
...
'easy_en.schema.yaml'
...
key_binder:
import_preset: default
...
在教程中看到了key_binder/bindings:中when ,access, send的用法,但是不知道toggle怎么用,可以举个例子么?
Rime_description.md
里提到了 custom_phrase
翻译器实现的自定义短语。自定义短语出现优先级高,可以用于实现置顶字词功能。鉴于置顶字词属于较常见需求,可以考虑在文档内给出明确提示,便于用户参考。
请问下emoji-chinese 映射表有简中版本不,我自己用繁体字转换好像有些结果不太对。当然没有也没关系,非常感谢~
参考 librime 1.7.3 中关于 binding 的实现,目前有以下比较有用的设置项未列出:
由于我在各处接触到的文档大都援引自这里,所以提议作者补充下
我当初是想解决 “找到快速切换到英文输入模式” 的问题,费劲周折才在源码中看到它们!
最后通过这个 绑定 {accept: "Control+F7", set_option: ascii_mode, when: always}
解决
ascii_mode 是中英文轉換開關。預設0爲英文,1爲中文
这里应是0中文,1英文
当你在资源管理器中,按某个字母,本意是快速找到某个文件夹或文件,可是这时输入法弹出来了,你是不是很郁闷,而英文状态,非输入状态,它就不会出现。
这样的情况在Ps等很多软件都存在,你按某个键本想快速跳到某个工具,可这时中文输入法出现了。
……
以前你没在意,从些你不觉得有点不舒坦了
……
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.