Notes
Exit the default fcitx5 and then run fcitx5 -d –verbose=*=5 or –verbose={categoryname}=5,{categoryname}=5
Use with care that category:keytrace will output my passwords inputting to browser etc to error logs. On last resort, hook into imconfig’s run im script usr/share/im-config/data??_fcitx5.rc or /usr/bin/fcitx5.
As a desktop app following the standard, data should better be loaded from subdir for this component only under XDG_DATA_HOME for personal dictionary and XDG_DATA_DIRS for static common dictionary. Although, emacs + SKK users tend to share dictionary file among ddskk and IME so this might have to be fixed to be configurable in the future.
Putting Fcitx in class name may seem redundant, but it helps distinguish this fcitx5-cskk addon from cskk the library. Put ‘FcitxCskk’ as prefix for class names.
See src/lib/fcitx/icontheme.h and related. Fcitx5 supports svg, png, xpm. Supports XDG icon specification. https://www.freedesktop.org/wiki/Specifications/icon-theme-spec/ but theme fallback in original way. Fcitx5 converts icon filename fcitx-foo to org.fcitx.Fcitx5.fcitx-foo automatically when built for flatpak and search the converted filename only as of fcitx v5.0.17 Although, flatpak since v0.8.8 can use system icons, so this addon will workaround by ignoring that naming prefix.
TODO for this project is to prepare a svg icon to accept scalable icons.
Should update these files and then create a deploy on github
- org.fcitx.Fcitx5.Addon.Cskk.metainfo.xml.in
- CMakeLists.txt
Following semver rule but with tweak same as rust lang’s cargo. Initial development releases starting with “0.y.z” can treat changes in “y” as a major release, and “z” as a minor release.
Fcitx5 finds addon from FCITX_ADDON_DIRS env var, a colon (‘:’) separated dir list. fallbacks to FCITX_INSTALL_ADDONDIR configured on build. e.g. FCITX_ADDON_DIRS=build/src:/usr/lib/x86_64-linux-gnu/fcitx5 fcitx5 –verbose=*=5
Create Option class. Create a Configuration class. Override setConfig, getConfig. Set configurable on conf file.
Keeping lib binary interface same, access all data via d_ptr. Same reason, access all methods via q_ptr. Probably same as Qt library.
What is Addon entry? name of lib? filename? fedora metainfo like name? What option is configurable here? fcitx5/src/lib/fcitx/addoninfo.cpp’s list is addon.conf
metainfo project group == Fcitx?? https://docs.fedoraproject.org/en-US/packaging-guidelines/AppData/ doesn’t define what each field means.