sat1226 / dmenu-patches Goto Github PK
View Code? Open in Web Editor NEWMy dmenu patches
License: MIT License
My dmenu patches
License: MIT License
I'm not really a programmer, so I'm hoping you can help me understand how the patch for adding C-v
for pasting from primary selection works. By default, C-Y
pastes from primary selection, as defined:
case XK_Y:
XConvertSelection(dpy, (ev->state & ShiftMask) ? clip : XA_PRIMARY,
utf8, utf8, win, CurrentTime);
return;
So I simply assumed creating the same entry for XK_v
would do it:
case XK_v:
XConvertSelection(dpy, (ev->state & ShiftMask) ? clip : XA_PRIMARY,
utf8, utf8, win, CurrentTime);
return;
However, it seems to apply to C-V
instead. Your patch works fine and the difference is at line 27 where you have the exclamation point at !(ev->state & ShiftMask)
. What's the context of that and why is it needed here but not for case XK_Y
? I assume it's something to do with shift key being used for capital Y
vs. not being used for lowercase v
. Also, why is it necessary to create an empty case for `case XK_v?
Much appreciated.
P.S. I'm thinking of changing the binding of C-j
and C-k
for down
/up
for vim-like behavior and C-l
for ~
C-;
for Enter
to stay on home row but am still deciding if it's worth it and if it's trivial to implement it.
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.