Skip to main content

Selecting text SHIFT+HOME and SHIFT+END

All Windows users, whether a power-user or an average-user, will natively select a line of text in Windows by using SHIFT+HOME and SHIFT+END.

Linux Mint Xfce supports this keyboard combination, but not by default.  The user needs to choose the option.  The command to do so is:

setxkbmap -option numpad:microsoft
(source)

But this works only for the current user's current session.

There are two choices for setting this option:

  1. run the option command automatically on log in of each user on the machine;
  2. run the option command automatically upon machine startup.
It makes perfect sense for Linux Mint to assume the option as off.  Not all Linux Mint users will be Windows users migrating to Linux Mint: others will migrate from other Unix-based or Linux-based environments, so defaulting the option to on out-of-the-box would probably drive them nuts.

Option 1: user settings via graphical interface (Xfce)

Mint/Start > "Session and Startup" > "Application Autostart" > "Add" > ...


Do for the current user, then repeat for every other user on the same machine.

Linux Mint Cinnamon provides the support within its GUI, described here.  This option is not available in Linux Mint Xfce "Sylvia".

Option 1: user settings via command line prompt

For each user, the location of commands on startup  is
~/.config/autostart (source)

Sub-option A - from CLI via GUI (uses an understandable text editor (xed))

cd ~/.config/autostart
xed KeyboardWinTextSelect.desktop

In the resulting GUI text editor, paste:

[Desktop Entry]
Encoding=UTF-8
Version=0.9.4
Type=Application
Name=KeyboardWinTextSelect
Comment=To enable SHIFT+HOME and SHIFT+END to select text
Exec=setxkbmap -option numpad:microsoft
OnlyShowIn=XFCE;
StartupNotify=false
Terminal=false
Hidden=false


Then save & close the file.

Sub-option B - stays in CLI (uses an incomprehensible text editor (vi))

cd ~/.config/autostart
vi KeyboardWinTextSelect.desktop

Learn how to use vi.  Enjoy the pain.

Type up the paste text as above, save the file, exit vi.  Hope it works first time.  Good luck with all of that.

If it fails, delete the file and start again from scratch, using sub-option 2 above.

Option 2: machine settings via command line prompt

This option is untested so is theoretical only!

According to the Linux Mint Forum, the location of commands to be run on machine start-up is
 /etc/init.d/rc.local

Thus, from within the admin user's account:
gksudo xed /etc/init.d/rc.local 

Then, above "exit 0", paste the command:
setxkbmap -option numpad:microsoft

Save & exit.

Supporting discussion about the function of /etc/init.d is here and here.

Completion date

April 2018.

Comments

Popular posts from this blog

Downgrading of the project: Calc has a fatal bug - it cannot reliably link workbooks

The project is to build a Linux Mint machine to have the identical functionality and ergonomics as the existing Windows 10 machine. This stage relates to on-going work to make LibreOffice Calc workable. Unfortunately, it turns out that LibreOffice isn't fit for purpose.  Specifically, it cannot reliably link workbooks, even in its own native workbooks. As a consequence, the project is now downgraded.  My time is now better spent doing other, more productive things, with a greater chance of success. Background On 29Jul2018, I complied a detailed test using fresh, sample data created specifically for the purpose, in Excel on Windows 10, then had a virtual machine running LibreCalc on Linux Mint to import it. The basic spreadsheet functionality of linked workbooks failed haphazardly. I logged the test results on 29Jul2018 on AskLibreOffice  and, to date, have yet to see any evidence of anybody taking ownership of recognising the issue and thus fixing it. The s...

The Big Bang: Microsoft Windows goes for good, positive adaptations required

On 27Mar2021, Linux Mint ate Microsoft Windows 10 on Legolas. Three months on, I conclude beyond any doubt that wiping out Windows was the best decision I ever made. The second best decision I ever made was to test Linux Mint in Virtual Box five years ago. The third best decision I ever made was to take ownership of the learning curve that migrating in Windows really entails. A quick reminder: what’s Microsoft Windows like nowadays? I still need to use Windows at work. I cannot easily describe how painful it now is to use Windows. So I’ll try to describe it difficultly. My work machine is a powerful beast, but it exhibits constant latency. For a keyboard-orientated power user, this means that some keystrokes go walkabouts when other services on the Windows machine go to nuclear war with each other, scrambling to feed their narcissistic self-importance for besieged system resources wholly at the user’s expense. Something on Windows tends to clear the keyboard buffer randomly, resulting ...

Deployment of Wine

The project is to build a Linux Mint machine to have the identical functionality and ergonomics as the existing Windows 10 machine. Having established that there is no way to migrate fully from Windows to Linux , the project now needs to consider running Windows apps in Linux.   This is a big change to the strategy of the project.   This is a big change to the deployment of a Linux workstation, a crushing admission of failure, and the opening of a whole new world of risks to an otherwise secure operating system. Environment & required functionality For this blog post, Wine was tested on: The Linux Mint Xfce 19 virtual machine " Bilbo ", on host Windows 10 laptop " Saruman " The Linux Mint Xfce 18.3 virtual machine " Gimli ", on host Windows 10 host " Legolas ". Alternatives There are alternatives to Wine/PlayOnLinux, notably the paid software Crossover. Software selection Wine and PlayOnLinux are present in L...