Zren / plasma-applet-lib

Various reuseable files for developing a plasma widget.
10 stars 3 forks source link

kpac localetest not translating applet #4

Open ChrTall opened 1 month ago

ChrTall commented 1 month ago

kpac is a great CLI Tool. I think this should be somehow merged into kde and provide the ability to also generate/scaffold a new plasmoid project. (something like the ng CLI for Angular Projects)

I noticed that when using kpac localetest de the applet is not translated. The buttons in the bottom (plasmoidviewers options) are translated though. If I install my applet and switch language, my applet is translated. Screenshot_20240612_152449

k-donn commented 1 week ago

Hello, I was having this same problem too. I do not know if you found a solution, but I have found something.

If you generate the .mo files for a locale (for example de_DE), then copy them into /usr/share/locale/de_DE/LC_MESSAGES/plasma_applet_[YOUR WIDGET].mo.

Then, doing $ kpac localetest de works, and the underlying LANGUAGE="de_DE:de" LANG="de_DE.UTF8" plasmoidviewer -a ./plasmoid works as well. I found an old mailing list talking about this.

Hope this helps!