hamwaves.com
;

Lesser-Known gedit Keyboard Shortcuts

Serge Y. Stroobandt

Copyright 2013-2014, licensed under Creative Commons BY-NC-SA

Introduction

I really like GNOME’s gedit text editor, even though I have become an XFCE desktop user since the advent of the spoon-fed (i.e. nonforked) GNOME 3 debacle. Anyhow, gedit 3 works just fine in XFCE 4.10 regardless of the fact that gedit 3 employs version 3 of the GIMP toolkit (GTK+), whereas XFCE 4.10 still relies on GTK+ version 2.

Its plugins, both “official” and “less official” (LaTeX, collaboration,…) are what make gedit a truly complete editor; yet in a very unobtrusive way. As for eye candy, I can wholeheartedly recommend gedit’s dark, relaxing Oblivion colour scheme.

Screenshot of gedit 3.8.3 with its Oblivion colour scheme whilst writing this text in Pandoc Markdown. [Full screen]

Screenshot of gedit 3.8.3 with its Oblivion colour scheme whilst writing this text in Pandoc Markdown. [Full screen]

Shortcuts to speed

As a matter of fact, gedit happens to be the editor which I use for writing the Markdown documents that end up being converted to these web pages. I also use gedit for preparing LaTeX and ConTeXt documents.

Once one starts using gedit extensively for writing content, it becomes inevitable to learn a handful of keyboard shortcuts. Doing so will tremendously speed up work. This happens because keyboard typing is essentially a two-hands undertaking; when one hand leaves the keyboard to grab a computer mouse, the other hand will mostly remain idle. Use of the computer mouse seriously disrupts the flow of creative electronic writing.

Dispersed documentation

One might ask: “Why bother writing about gedit keyboard shortcuts? Are those items not documented?” Well, not quite. Here is where things start to get interesting. For sure, GNOME’s gedit wiki will direct you to a page with “official” keyboard shortcuts.

However, there is more to this story. As Craig Russell brilliantly pointed out, gedit uses the GtkTextView widget to display and edit text. This means there are more keyboard shortcuts at play than those documented in the gedit wiki.

Keyboard shortcuts

Here is my attempt at compiling an all-encompassing gedit keyboard shortcut list. Some key combinations were never published before. Other combinations were reordered for better comprehension. However, by no means I pretend this list to be complete. For example, there is this specification of GtkTextIter, which is a component of GtkTextView providing text manipulation. In it, sentence navigation gets mentioned. Unfortunately, key-bindings for these sentence functions are nowhere to be found… Finally, I did not include published shortcuts that failed to work in gedit 3.8.3, nor shortcuts that are specific to optionally installed plugins, unless otherwise stated.

Cursor navigation

Cursor navigation [Ctrl]+
shortcut action
[Ctrl]+[→] Move the cursor forward by one word.
[Ctrl]+[←] Move the cursor backwards by one word.
[Ctrl]+[PageUp] Move the cursor to the beginning of the line.[Home]
[Ctrl]+[PageDn] Move the cursor to the end of the line.[End]
[Ctrl]+[↑] Move the cursor to the beginning of the previous line.
[Ctrl]+[↓] Move the cursor to the end of the next line.
[Ctrl]+[I] Move the cursor to a specific line number.
[Ctrl]+[Home] Move the cursor to the beginning of the document.
[Ctrl]+[End] Move the cursor to the end of the document.
[Ctrl]+[Alt]+[PageUp] Switch to the document/side pane tab to the left.
[Ctrl]+[Alt]+[PageDn] Switch to the document/side pane tab to the right.
[Alt]+[1][9],[0]* Jump to the 1st… 10th document tab.
[Alt]+[Tab] Switch to the workspace application to the right.
[Shift]+[Alt]+[Tab] Switch to the workspace application to the left.
[Ctrl]+[Alt]+[→] Switch to the workspace to the right.
[Ctrl]+[Alt]+[←] Switch to the workspace to the left.

Notes:

Selecting

Selecting [Shift]+
shortcut action
[Shift]+[Ctrl]+[→] Select forward by words.
[Shift]+[Ctrl]+[←] Select backwards by words.
[Shift]+[Ctrl]+[PageUp] Select to the beginning of the line.
[Shift]+[Ctrl]+[PageDn] Select to the end of the line.
[Shift]+[Ctrl]+[↑] Select forward by lines.
[Shift]+[Ctrl]+[↓] Select backwards by lines.
[Shift]+[Ctrl]+[Home] Select to the beginning of the document.
[Shift]+[Ctrl]+[End] Select to the end of the document.
[Ctrl]+[A] Select all.

Moving

Moving [Alt]+
shortcut action
[Alt]+[→] Move the selected word forward by one word.
[Alt]+[←] Move the selected word backwards by one word.
[Alt]+[↑] Move the selected line up by one line.
[Alt]+[↓] Move the selected line down by one line.

Deleting

Deleting
shortcut action
[Ctrl]+[BkSpce] Delete the word behind the cursor.
[Ctrl]+[Del] Delete the word ahead of the cursor.
[Shift]+[Ctrl]+[BkSpce] Delete from the cursor to the beginning of the line.
[Shift]+[Ctrl]+[Del] Delete from the cursor to the end of the line.
[Ctrl]+[D] Delete the current line.

Editing

Editing
shortcut action
[Ctrl]+[X] Cut the selected text or region and place it on the clipboard.
[Ctrl]+[C] Copy the selected text or region onto the clipboard.
[Ctrl]+[V] Paste the contents of the clipboard.
[Ctrl]+[Z] Undo the last action.
[Shift]+[Ctrl]+[Z] Redo the last undone action.
[Shift+F7] Check spelling.

Special characters

Special characters
shortcut action
[Shift]+[Ctrl]+[U] Enter a character by Unicode. Finish off with [Enter] or [Space].
some common examples
[Shift]+[Ctrl]+[U],00B6 or [AltGr]+[R] Pilcrow ¶, for use with footnotes*
[Shift]+[Ctrl]+[U],00E6 or [AltGr]+[A] Latin small ligature æ
[Shift]+[Ctrl]+[U],2011 Non-breaking hyphen ‑
[Shift]+[Ctrl]+[U],2016 Double vertical line ‖, for use with footnotes*
[Shift]+[Ctrl]+[U],2020 Dagger †, for use with footnotes*
[Shift]+[Ctrl]+[U],2021 Double dagger ‡, for use with footnotes*
[Shift]+[Ctrl]+[U],2060 Word joiner or zero-width no-break space
[Shift]+[Ctrl]+[U],2113 Ell ℓ
[Shift]+[Ctrl]+[U],2116 Numero sign
[Shift]+[Ctrl]+[U],2126 or [Shift]+[AltGr]+[Q] Ohm Ω
[Shift]+[Ctrl]+[U],2A2F or [Shift]+[AltGr]+[,] Vector or cross product ⨯

Note:

Searching

Searching
shortcut action
[Ctrl]+[F] Find a string.
[Ctrl]+[G] Find the next instance of the searched string.
[Shift]+[Ctrl]+[G] Find the previous instance of the searched string.
[Shift]+[Ctrl]+[K] Clear the search result highlighting.
[Ctrl]+[H] Search and replace.

Document operations

Document operations
shortcut action
[Ctrl]+[N] Create a new document.
[Ctrl]+[O] Open a document.
[Ctrl]+[Alt]+[O] Quickly open a document.*
[Ctrl]+[S] Save the current document.
[Shift]+[Ctrl]+[S] Save as a new file.
[Shift]+[Ctrl]+[L] Save all open documents.
[Ctrl]+[P] Print the current document.
[Shift]+[Ctrl]+[P] Print preview.
[Ctrl]+[W] Close the current document.
[Shift]+[Ctrl]+[W] Close all open documents.

Note:

Application

Application
shortcut action
[F1] Open the gedit user guide.
[F9] Show/hide the side pane.
[F11] View fullscreen.
[Ctrl]+[Q] Quit gedit.
5
Creative Commons Licence
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License.
Other licensing available on request.
GNU GPL v3
Unless otherwise stated, all originally authored software on this site is licensed under the GNU GPL version 3.
This domain does not set any first party cookies.
However, Google AdSense may set third party cookies. Policies and control options can be found here.
This page includes an open-source client-side script, written in Python and
transcoded by Brython to let it run as JavaScript in the browser.
Static XHTML generated from Markdown by Pandoc and
the GNU/Linux make, sed and gpp commands.
LaTeXmath markup rendered with MathJax.
CSS typesetting by Prince.
This work is published at http://hamwaves.com/gedit/en/.
Last update: Monday, July 7, 2014.