mirror of
https://github.com/Cloudef/bemenu
synced 2025-01-18 08:20:41 +00:00
Clipboard: Don't use "text/plain"
On X11, not all programs offer this target, e.g. some terminals like XTerm. The target "UTF8_STRING" has worked fine for many years and it is what dmenu uses. On Wayland, wl-paste supports the special type "text", which attempts to autodetect a suitable type (in case there is no exact match for "text/plain").
This commit is contained in:
parent
5b462ad76d
commit
75122a023a
@ -1155,11 +1155,11 @@ bm_menu_run_with_key(struct bm_menu *menu, enum bm_key key, uint32_t unicode)
|
||||
{
|
||||
char *paster[2] = {NULL, NULL};
|
||||
if (key == BM_KEY_PASTE_PRIMARY) {
|
||||
paster[0] = "wl-paste -t text/plain -p";
|
||||
paster[1] = "xclip -t text/plain -out";
|
||||
paster[0] = "wl-paste -t text -p";
|
||||
paster[1] = "xclip -t UTF8_STRING -out";
|
||||
} else {
|
||||
paster[0] = "wl-paste -t text/plain";
|
||||
paster[1] = "xclip -t text/plain -out -selection clipboard";
|
||||
paster[0] = "wl-paste -t text";
|
||||
paster[1] = "xclip -t UTF8_STRING -out -selection clipboard";
|
||||
}
|
||||
|
||||
for (size_t paster_i = 0; paster_i < sizeof paster / sizeof paster[0]; paster_i++) {
|
||||
|
Loading…
Reference in New Issue
Block a user