summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--help/C/index.docbook30
-rw-r--r--pluma/pluma-window.c4
2 files changed, 34 insertions, 0 deletions
diff --git a/help/C/index.docbook b/help/C/index.docbook
index 5961f617..201a6620 100644
--- a/help/C/index.docbook
+++ b/help/C/index.docbook
@@ -1320,6 +1320,36 @@
</tgroup>
</informaltable>
+ <!-- ============= View ======================= -->
+ <bridgehead>View</bridgehead>
+ <para>Shortcuts for the current view:</para>
+ <informaltable frame="all">
+ <tgroup cols="2" colsep="1" rowsep="1">
+ <colspec colname="COLSPEC0" colwidth="50*"/>
+ <colspec colname="COLSPEC1" colwidth="50*"/>
+ <thead>
+ <row valign="top">
+ <entry colname="COLSPEC0">
+ <para>Shortcut Key</para>
+ </entry>
+ <entry colname="COLSPEC1" align="left">
+ <para>Command</para>
+ </entry>
+ </row>
+ </thead>
+ <tbody>
+ <row valign="top">
+ <entry>
+ <para>Ctrl + Y</para>
+ </entry>
+ <entry>
+ <para>Show/hide line numbers.</para>
+ </entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+
<!-- ============= Panes ======================= -->
<bridgehead>Panes</bridgehead>
<para>Shortcuts for showing and hiding panes:</para>
diff --git a/pluma/pluma-window.c b/pluma/pluma-window.c
index fae01e60..58d3fcf7 100644
--- a/pluma/pluma-window.c
+++ b/pluma/pluma-window.c
@@ -348,6 +348,10 @@ pluma_window_key_press_event (GtkWidget *widget,
g_free (tmp);
}
}
+ else if (event->keyval == GDK_KEY_y)
+ {
+ g_settings_set_boolean (settings, PLUMA_SETTINGS_DISPLAY_LINE_NUMBERS, !g_settings_get_boolean (settings, PLUMA_SETTINGS_DISPLAY_LINE_NUMBERS));
+ }
if (g_settings_get_boolean (settings, PLUMA_SETTINGS_CTRL_TABS_SWITCH_TABS))
{