Text selection using Ctrl+Shift+Cursor Keys in Linux.

twinkle

New Member
Joined
Jan 20, 2022
Messages
6
Reaction score
2
Credits
60
Hello everyone. I'm very used to 'Windows'-based text selection using Ctrl + Shift + Cursor Keys (to select text 'word by word').
The problem is that on Windows I used Ctrl + Shift keys to switch keyboard layouts, and text selection was working just fine.
But in Linux I noticed that if I choose Ctrl + Shift as a shortcut to change the language, I can no longer use text selection with these buttons, that is I can't use text selection and switching over layouts simultaneously. I've searched for solutions on many forums, and all such "solutions" come down to replacing the shortcut to change the language with something like Ctrl + Win, but I'm not a clown to put up with this crutch.
I am sure that Linux with all it's power is wise enough to handle these problem, but I can't come up with a solution on my own. Could you help me, please?
 


Yea, configure it yourself.
 
G'day frezario, Welcome to Linux.org

I must admit I have little to zero knowledge about your topic

However......does this link help at all ?


As of Linux Mint 18.2, this now seems to require selecting the following two options under "System Settings" -> "Keyboard" -> "Layouts" -> "Options":

"NumLock on: digits, Shift switches to arrow keys, Numlock off: always arrow keys (as in MS Windows)"

"Shift does not cancel Num Lock, chooses 3rd level instead"
 
G'day frezario, Welcome to Linux.org

I must admit I have little to zero knowledge about your topic

However......does this link help at all ?


As of Linux Mint 18.2, this now seems to require selecting the following two options under "System Settings" -> "Keyboard" -> "Layouts" -> "Options":

"NumLock on: digits, Shift switches to arrow keys, Numlock off: always arrow keys (as in MS Windows)"

"Shift does not cancel Num Lock, chooses 3rd level instead"
Thanks for reply, but unfortunately it didn't come in handy (I've already followed that advice before). I am using KDE Plasma, so I jumped to "Keyboard Settings -> Advanced -> Compatibility" and chose these two options, just as you said:

screen3.png

But nothing happened, and the problem is still there. When I'm trying to select text using
Ctrl + Shift, Linux simply changes my language =(.
P.S And still, if I chose Ctrl+Win to switch layouts, I can select text using Ctrl + Shift + Arrows.
 
In that case, if you want the text selection to keep working without the system changing your keyboard language, then why don't you simply change the keybind for the keyboard language switcher instead?!

That way your keybinds won't conflict with each other. You'll be able to select text in the way that you're used to and you can still switch keyboard language - albeit with a slightly different keybind!
 
In that case, if you want the text selection to keep working without the system changing your keyboard language, then why don't you simply change the keybind for the keyboard language switcher instead?!
Because it's ridiculous. Why can't I use Ctrl + Shift to do both?
 
Last edited:
But when you press the key-bind, how is the DE/WM supposed to know which of the two actions to take?

You could say "If the terminal window is active - I obviously want to select text!".
To which my response would be - "IF things worked that way, What happens when you're working in the terminal and you want to change the keyboard layout?"

Your only option in that instance would be to switch to the desktop, or another application - to take the focus away from the terminal; before pressing your keybind to switch keyboard layouts. And then you'd have to re-select the terminal window to continue working. And surely that would be even more of a ball-ache than having a slightly different keybind!

I haven't used KDE/Plasma for a while, but as I understand things:
If you bind the same keybind to multiple events; then internally, most DE's/WM's will either:
A: Perform the action that has higher precedence.
So, if one of the actions is a global, DE-wide bind and the other is an application bind - it will perform the global, DE-wide one, instead of the application one.
OR
B: Perform the first action it finds.

As I see it, you have two options.
1. You can simply change one of the key-binds and try to learn to live with it!
OR
2. You can complain about it endlessly and ultimately achieve nothing (other than perhaps prolonging your "suffering"!)

Incidentally - I wouldn't say you're "suffering" because of this problem. I'd say you're "mildly inconvenienced" by it.

Linux based OSes are great. They aren't perfect, but you have a lot more customisability options than you have in a lot of other OSes.

And at the end of the day Linux is NOT Windows. Don't expect things to be exactly the same. Sometimes you might need to use an annoying workaround for something, or adopt a slightly different workflow. That's just the way things are.
Sometimes there are quirks and mild inconveniences.

Also, Linux based OSes are FREE in every meaning of the word. When you use free software YOU are directly responsible for your own experience.

Unless you've paid a company an expensive fee for dedicated Linux support - you literally have nobody to complain to. And no real right to complain. We're standing on the backs of giants here.

In fact we're standing on the backs of giants, that are standing on the backs of other giants. It's like an immense pyramid of giants, reaching for the sky... It's the combined work of many thousands of programmers, for the last 39 years. And it's completely free and open source!

And before anybody jumps on me and says "Aha, Linux has only been around since 1991, that's no more than 32 years ago!".
That's true. But the GNU project has been in existence since 1983. Linux based OSes use a lot of GNU software. And a number of their software components have been in active development since '83. Many of those initial components weren't released until a few years after that date, because obviously it takes time to develop them. But still!

Anyway, getting back on point - Instead of whining about it - do something positive about it instead!

If you really feel that this is a bug - try making a bug report to the KDE/plasma developers.

You might have a bit of a wait before anything gets done about it. Purely because the development team will set their own priorities when deciding which bugs/features to tackle. Also, they may not view the behaviour you're seeing as a bug and may choose NOT to do anything at all about it.

So whilst you're waiting, you might just have to bite the bullet and simply change one of your conflicting keyboard shortcuts! Ha ha!
 
But when you press the key-bind, how is the DE/WM supposed to know which of the two actions to take?

You could say "If the terminal window is active - I obviously want to select text!".
To which my response would be - "IF things worked that way, What happens when you're working in the terminal and you want to change the keyboard layout?"

Your only option in that instance would be to switch to the desktop, or another application - to take the focus away from the terminal; before pressing your keybind to switch keyboard layouts. And then you'd have to re-select the terminal window to continue working. And surely that would be even more of a ball-ache than having a slightly different keybind!

I haven't used KDE/Plasma for a while, but as I understand things:
If you bind the same keybind to multiple events; then internally, most DE's/WM's will either:
A: Perform the action that has higher precedence.
So, if one of the actions is a global, DE-wide bind and the other is an application bind - it will perform the global, DE-wide one, instead of the application one.
OR
B: Perform the first action it finds.

As I see it, you have two options.
1. You can simply change one of the key-binds and try to learn to live with it!
OR
2. You can complain about it endlessly and ultimately achieve nothing (other than perhaps prolonging your "suffering"!)

Incidentally - I wouldn't say you're "suffering" because of this problem. I'd say you're "mildly inconvenienced" by it.

ОС на базі Linux чудові. Вони не ідеальні, але у вас є набагато більше можливостей налаштування, ніж у багатьох інших ОС.

І, зрештою, Linux – це НЕ Windows. Не очікуйте, що все буде точно так само. Іноді вам може знадобитися використовувати дратівливий обхідний шлях для чогось або прийняти дещо інший робочий процес. Просто так йдуть справи.
Іноді виникають примхи та легкі незручності.

Крім того, ОС на базі Linux БЕЗКОШТОВНІ у кожному значенні цього слова. Коли ви використовуєте безкоштовне програмне забезпечення, ВИ несете безпосередню відповідальність за власний досвід.

Якщо ви не заплатили компанії дорогу плату за виділену підтримку Linux - вам буквально нема кому поскаржитися. І немає реального права скаржитися. Ми стоїмо тут на спинах гігантів.

Насправді ми стоїмо на спинах гігантів, які стоять на спинах інших гігантів. Це як величезна піраміда гігантів, що тягнеться до неба... Це спільна робота багатьох тисяч програмістів за останні 39 років. І це абсолютно безкоштовно та з відкритим кодом!

І перш ніж хтось наскочить на мене і скаже: «Ага, Linux існує лише з 1991 року, це не більше 32 років тому!».
Це правда. Але проект GNU існує з 1983 року. ОС на базі Linux використовує багато програмного забезпечення GNU. І ряд їх програмних компонентів активно розробляються з 83 року. Багато з цих початкових компонентів були випущені лише через кілька років після цієї дати, тому що, очевидно, потрібен час, щоб їх розробити. Але все ж!

У всякому разі, повертаючись до справи – замість того, щоб скиглити про це, зробіть щось позитивне з цього приводу!

Якщо ви дійсно вважаєте, що це помилка, спробуйте повідомити про помилку розробникам KDE/plasma.

Можливо, вам доведеться трохи почекати, перш ніж щось з цим зробити. Чисто тому, що команда розробників встановлюватиме власні пріоритети, вирішуючи, які помилки/функції вирішувати. Крім того, вони можуть не розглядати поведінку, яку ви бачите, як помилку, і можуть вирішити НЕ робити нічого з цим.

Отже, поки ви чекаєте, вам, можливо, доведеться просто пережити і просто змінити одне з конфліктуючих комбінацій клавіш! Ха-ха!
Ok, I got you.
 
Why can't I use Ctrl + Shift to do both?
I'm in the process of switching to Linux (Manjaro+KDE) after having used Windows for nearly 30 years and I have encountered exactly the same problem as you have. For now I have settled for Shift+CapsLk and RCtrl+RShift, but this still has some side effects:
  • when pressing LShift+RCtrl+R/L, the word selection still doesn't work properly, but it works fine when pressing either RCtrl+LShift+R/L, or LShift+LCtrl+R/L.
  • if a portion of text is selected, pressing either Shift+CapsLk or RShift+Ctrl deletes the selection.
While usable, this behaviour is pretty annoying and I would love to see a proper solution for this.

But when you press the key-bind, how is the DE/WM supposed to know which of the two actions to take?
It seems Linux behaves differently compared to both Windows and MacOS in that regard: it registers the input switch action on key press, while Windows/MacOS register the action on key release. If this Linux behaviour can be changed, my guess is this would alleviate all the issues described above.

why don't you simply change the keybind for the keyboard language switcher instead
Twinkle's point is entirely valid in my opinion: one reason Linux is so great is because it's infinitely customizeable and tweakable to fit the user, something which is only possible in Windows to some extent, and basically impossible in MacOS. I have been using a company issued Macbook for the last 1.5 years and it's pure torture. If we choose to adapt our behaviour and habits to the interface instead of adapting the interface to suit our needs, then why use Linux at all (except for FOSS)?

"You are holding it wrong!" — Steve Jobs​
 
It seems we have to fill a bug for this issue. But for what component?

It' s not KDE/Gnome issue, it's the same under Wayland and X. So it should be some other component.
Kernel?

Any advice?
 

Members online


Top