noracodes / charpicker Goto Github PK
View Code? Open in Web Editor NEWA fast, simple Emoji and special character picker for X and Wayland
A fast, simple Emoji and special character picker for X and Wayland
The selected unicode character is inserted using xdotool, but xdotool may corrupt some characters (this is ackowledged in its man page, see BUGS section). I also tried xte, from the xautomation package. No more corruption, but then xte silently fails if the Unicode character is not part of the current keymap... In the end I found this trick that works for me (so far):
echo -n "$selected_symbol" | xclip -i
xdotool click 2
The first line put the selected Unicode character in the primary selection clipboard using xclip. The second line insert a middle click, pasting the selection in the current window. This way the complexity of going from a character to X keyboard events is not needed, it's just like a cut and paste.
This works on X11, not tested under Wayland (is middle click paste supported now?). So it may be X11 only, TBC.
I'm pretty new to Wayland, but so far I haven't found a way to set up xdotool
to work on it. With installed both rofi
and xdotool
your charpicker pops up and i select emoji, but it doesn't get pasted in the open app, nor to clipboard.
I've changed the last line instead of using xdotool
to echo -n "$selected_symbol" | wl-copy
. Maybe you can include that in the README.md or you suggest a different approach?
I'll do this when I get home, my laptop doesn't have working color emoji.
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.