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

Scanning & OCRring to PDF: Simple Scan, gimagereader and gscan2pdf v NAPS2 for Windows

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 scanning paper documents to PDF and digitising the scanned text via optical character recognition. Environment & required functionality The scan-and-OCR function needs to run on the following machines: The Linux Mint Xfce 18.3 laptop " Gandalf "; A Linux Mint Xfce 18.3 virtual machine " Gimli "; The Windows 10 laptop " Legolas ". In any modern office - whether at home or at work - some transactional documents and documents from public authorities still arrive by snail-mail. This requires the ability to scan all documents, optionally with the digitisation of scanned text (typically via optical character recognition). The hardware is an old HP OfficeJet Pro 276dw, connected to the LAN instead of directly to a workstation. Alternatives There are two strategies: To use the software pr

Status report: wholesale migration from Windows to Linux is not functionally possible

As at mid-May2019 , it was clear that the path to migration from Windows to Linux was obstructed by a lack of apps that are fit-for-purpose being available in the Linux environment. Since May2019, there has been no change to the apps/functionalities then listed in the section, "Path to migration is obstructed by apps which are incompatible or otherwise unusable."  Developments in the interim have merely confirmed that the apps available for the Linux environment are not fit-for-purpose, and are unlikely to be fit-for-purpose for the foreseeable future . So, it's time for a change of tack.  The time is right to deploy Occam's Razor. In short, the Linux Mint offers a perfect solution to the jaded Windows user.  The only problem with Linux Mint is not of Linux Mint's making.  The problem is a lack of apps that are fit-for-purpose in the Linux environment.  By fit-for-purpose, I mean apps that meet the hygiene requirements of office-based, corporate lackeys who

An attempt at full-disk encryption: Vera Crypt

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 testing full-disk encryption using VeraCrypt . Environment & required functionality Full-disk encryption needs to run on the following machines: The Linux Mint Xfce 18.3 laptop " Gandalf "; The Windows 10 laptop " Legolas ". The objective requirement is to protect user data from the physical theft of the physical machine, to provide an additional line of defence against data loss. This is probably more important for Windows than for Linux Mint.   Even so, in both cases, the operating system is likely to log activity which can reveal personal data and user (meta)data. Full-disk encryption does not mitigate against Microsoft’s sinister telemetry functionality, for which the main solutions seem to be: Either to use tools whose developers are constantly on the prowl, hunting for t