Added smart copy mode switch to prefs (Steve Boddy, LP#1223129)
This commit is contained in:
parent
2fd279ecf1
commit
78cf6e87ec
@ -16,6 +16,7 @@ terminator trunk:
|
||||
* PuTTY paste mode (Nemilya, LP#1416682) with some alterations
|
||||
(Steve Boddy)
|
||||
* Updated and grouped default shortcuts in man page (Steve Boddy)
|
||||
* Added smart copy mode switch to prefs (Steve Boddy, LP#1223129)
|
||||
* Bug fixes
|
||||
* Fix for those not running IBus, where the IBus workaround caused
|
||||
broken keys in other keymaps set with non-IBus tools (Steve
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 75 KiB After Width: | Height: | Size: 78 KiB |
@ -30,6 +30,8 @@ All contributions and improvements are welcome.
|
||||
| | | | Add Bug handling flow |br| |
|
||||
| | | | Minor changes/corrections |
|
||||
+--------------+------------+-----------------+-----------------------------------+
|
||||
| 0.98, r1667 | 2015-10-01 | Stephen Boddy | Add the new Smart copy mode |br| |
|
||||
+--------------+------------+-----------------+-----------------------------------+
|
||||
|
||||
.. note:: Ideally this documentation should be kept up-to-date with
|
||||
the changes as they go in. This way things don't get missed.
|
||||
|
@ -74,6 +74,11 @@ Behaviour
|
||||
get into an argument over what size the window should
|
||||
be.
|
||||
|
||||
**DBus server** (default: on)
|
||||
|
||||
If a Terminator :ref:`dbus` server is not already on the session
|
||||
bus, try to start one.
|
||||
|
||||
**Mouse focus** (default: Click to focus)
|
||||
|
||||
By what method the mouse pointer sets the focus on a terminal.
|
||||
@ -99,6 +104,14 @@ Behaviour
|
||||
will paste the Primary selection, and ``middle-click`` will open
|
||||
the :ref:`Context Menu <context-menu>`. (For ex-PuTTY users).
|
||||
|
||||
**Smart copy** (default: on)
|
||||
|
||||
If enabled and there is no selection, the shortcut is allowed to
|
||||
pass through. This is useful for overloading ``Ctrl``\ +\ ``C``
|
||||
to copy a selection, or send the SIGINT to the current process if
|
||||
there is no selection. If not enabled the shortcut does not pass
|
||||
through at all, and the SIGINT does not get sent.
|
||||
|
||||
**Re-use profiles for new terminals** (default: off)
|
||||
|
||||
When creating a new terminal with splitting or new tabs, if this is
|
||||
@ -117,10 +130,6 @@ Behaviour
|
||||
If active and set, then URL's will be passed as a command-line parameter
|
||||
to the given command.
|
||||
|
||||
**DBus server** (default: on)
|
||||
|
||||
If a Terminator :ref:`dbus` server is not already on the session
|
||||
bus, try to start one.
|
||||
|
||||
^^^^^^^^^^
|
||||
Appearance
|
||||
|
@ -310,6 +310,11 @@ FAQ for other Terminator <br />
|
||||
Add Bug handling flow <br />
|
||||
Minor changes/corrections</td>
|
||||
</tr>
|
||||
<tr class="row-even"><td>0.98, r1667</td>
|
||||
<td>2015-10-01</td>
|
||||
<td>Stephen Boddy</td>
|
||||
<td>Add the new Smart copy mode <br /></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="admonition note">
|
||||
|
@ -325,6 +325,10 @@ get into an argument over what size the window should
|
||||
be.</p>
|
||||
</div>
|
||||
</div></blockquote>
|
||||
<p><strong>DBus server</strong> (default: on)</p>
|
||||
<blockquote>
|
||||
<div>If a Terminator <a class="reference internal" href="advancedusage.html#dbus"><span>DBus</span></a> server is not already on the session
|
||||
bus, try to start one.</div></blockquote>
|
||||
<p><strong>Mouse focus</strong> (default: Click to focus)</p>
|
||||
<blockquote>
|
||||
<div><p>By what method the mouse pointer sets the focus on a terminal.</p>
|
||||
@ -351,6 +355,13 @@ receive keystrokes.</li>
|
||||
<div>Make the right mouse button operate like in PuTTY, so <code class="docutils literal"><span class="pre">right-click</span></code>
|
||||
will paste the Primary selection, and <code class="docutils literal"><span class="pre">middle-click</span></code> will open
|
||||
the <a class="reference internal" href="gettingstarted.html#context-menu"><span>Context Menu</span></a>. (For ex-PuTTY users).</div></blockquote>
|
||||
<p><strong>Smart copy</strong> (default: on)</p>
|
||||
<blockquote>
|
||||
<div>If enabled and there is no selection, the shortcut is allowed to
|
||||
pass through. This is useful for overloading <code class="docutils literal"><span class="pre">Ctrl</span></code>+<code class="docutils literal"><span class="pre">C</span></code>
|
||||
to copy a selection, or send the SIGINT to the current process if
|
||||
there is no selection. If not enabled the shortcut does not pass
|
||||
through at all, and the SIGINT does not get sent.</div></blockquote>
|
||||
<p><strong>Re-use profiles for new terminals</strong> (default: off)</p>
|
||||
<blockquote>
|
||||
<div>When creating a new terminal with splitting or new tabs, if this is
|
||||
@ -366,10 +377,6 @@ logic.</div></blockquote>
|
||||
<blockquote>
|
||||
<div>If active and set, then URL’s will be passed as a command-line parameter
|
||||
to the given command.</div></blockquote>
|
||||
<p><strong>DBus server</strong> (default: on)</p>
|
||||
<blockquote>
|
||||
<div>If a Terminator <a class="reference internal" href="advancedusage.html#dbus"><span>DBus</span></a> server is not already on the session
|
||||
bus, try to start one.</div></blockquote>
|
||||
</div></blockquote>
|
||||
</div>
|
||||
<div class="section" id="appearance">
|
||||
|
File diff suppressed because one or more lines are too long
@ -30,6 +30,8 @@ All contributions and improvements are welcome.
|
||||
| | | | Add Bug handling flow |br| |
|
||||
| | | | Minor changes/corrections |
|
||||
+--------------+------------+-----------------+-----------------------------------+
|
||||
| 0.98, r1667 | 2015-10-01 | Stephen Boddy | Add the new Smart copy mode |br| |
|
||||
+--------------+------------+-----------------+-----------------------------------+
|
||||
|
||||
.. note:: Ideally this documentation should be kept up-to-date with
|
||||
the changes as they go in. This way things don't get missed.
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 75 KiB After Width: | Height: | Size: 78 KiB |
@ -74,6 +74,11 @@ Behaviour
|
||||
get into an argument over what size the window should
|
||||
be.
|
||||
|
||||
**DBus server** (default: on)
|
||||
|
||||
If a Terminator :ref:`dbus` server is not already on the session
|
||||
bus, try to start one.
|
||||
|
||||
**Mouse focus** (default: Click to focus)
|
||||
|
||||
By what method the mouse pointer sets the focus on a terminal.
|
||||
@ -99,6 +104,14 @@ Behaviour
|
||||
will paste the Primary selection, and ``middle-click`` will open
|
||||
the :ref:`Context Menu <context-menu>`. (For ex-PuTTY users).
|
||||
|
||||
**Smart copy** (default: on)
|
||||
|
||||
If enabled and there is no selection, the shortcut is allowed to
|
||||
pass through. This is useful for overloading ``Ctrl``\ +\ ``C``
|
||||
to copy a selection, or send the SIGINT to the current process if
|
||||
there is no selection. If not enabled the shortcut does not pass
|
||||
through at all, and the SIGINT does not get sent.
|
||||
|
||||
**Re-use profiles for new terminals** (default: off)
|
||||
|
||||
When creating a new terminal with splitting or new tabs, if this is
|
||||
@ -117,10 +130,6 @@ Behaviour
|
||||
If active and set, then URL's will be passed as a command-line parameter
|
||||
to the given command.
|
||||
|
||||
**DBus server** (default: on)
|
||||
|
||||
If a Terminator :ref:`dbus` server is not already on the session
|
||||
bus, try to start one.
|
||||
|
||||
^^^^^^^^^^
|
||||
Appearance
|
||||
|
@ -34,7 +34,7 @@ These are the options Terminator currently supports in the global_config section
|
||||
.TP
|
||||
.B dbus
|
||||
Control whether or not Terminator will load its DBus server. When this server is loaded, running Terminator multiple times will cause the first Terminator process to open additional windows. If this configuration item is set to False, or the python dbus module is unavailable, running Terminator multiple times will run a separate Terminator process for each invocation.
|
||||
Default value: \fBFalse\fR
|
||||
Default value: \fBTrue\fR
|
||||
.TP
|
||||
.B focus
|
||||
Control how focus is given to terminals. 'click' means the focus only moves to a terminal after you click in it. 'sloppy' means the focus will follow the mouse pointer. 'system' means the focus will match that used by a GNOME window manager.
|
||||
@ -46,7 +46,7 @@ Default value: \fB-1\fR
|
||||
.TP
|
||||
.B geometry_hinting
|
||||
If True the window will resize in step with font sizes, if False it will follow pixels
|
||||
Default value: \fBTrue\fR
|
||||
Default value: \fBFalse\fR
|
||||
.TP
|
||||
.B window_state
|
||||
When set to 'normal' the Terminator window opens normally. 'maximise' opens the window in a maximised state, 'fullscreen' in a fullscreen state and 'hidden' will make it not shown by default.
|
||||
@ -140,6 +140,10 @@ Default value: \fBFalse\fR
|
||||
If set to True, right-click will paste the Primary selection, middle-click will popup the context menu.
|
||||
Default value: \fBFalse\fR
|
||||
.TP
|
||||
.B smart_copy \fR(boolean)
|
||||
If set to True, and there is no selection, the shortcut is allowed to pass through. This is useful for overloading Ctrl-C to copy a selection, or send the SIGINT to the current process if there is no selection. If False the shortcut does not pass through at all, and the SIGINT does not get sent.
|
||||
Default value: \fBTrue\fR
|
||||
.TP
|
||||
.B enabled_plugins
|
||||
A list of plugins which should be loaded by default. All other plugin classes will be ignored. The default value includes two
|
||||
plugins related to Launchpad, which are enabled by default to provide continuity with earlier releases where these were the
|
||||
|
@ -122,6 +122,7 @@ DEFAULTS = {
|
||||
'title_use_system_font' : True,
|
||||
'title_font' : 'Sans 9',
|
||||
'putty_paste_style' : False,
|
||||
'smart_copy' : True,
|
||||
},
|
||||
'keybindings': {
|
||||
'zoom_in' : '<Control>plus',
|
||||
|
@ -405,7 +405,7 @@
|
||||
<object class="GtkTable" id="table8">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="n_rows">6</property>
|
||||
<property name="n_rows">7</property>
|
||||
<property name="n_columns">2</property>
|
||||
<property name="column_spacing">12</property>
|
||||
<property name="row_spacing">6</property>
|
||||
@ -536,6 +536,25 @@
|
||||
<property name="y_options"/>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="dbuscheck">
|
||||
<property name="label" translatable="yes">DBus server</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_action_appearance">False</property>
|
||||
<property name="active">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="on_dbuscheck_toggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">6</property>
|
||||
<property name="bottom_attach">7</property>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options"/>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">True</property>
|
||||
@ -636,6 +655,22 @@
|
||||
<property name="bottom_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="smart_copy">
|
||||
<property name="label" translatable="yes">Smart copy</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_action_appearance">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="on_smart_copy_toggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="always_split_with_profile">
|
||||
<property name="label" translatable="yes">Re-use profiles for new terminals</property>
|
||||
@ -649,8 +684,8 @@
|
||||
</object>
|
||||
<packing>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="bottom_attach">4</property>
|
||||
<property name="top_attach">4</property>
|
||||
<property name="bottom_attach">5</property>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options"/>
|
||||
</packing>
|
||||
@ -667,8 +702,8 @@
|
||||
</object>
|
||||
<packing>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">4</property>
|
||||
<property name="bottom_attach">5</property>
|
||||
<property name="top_attach">5</property>
|
||||
<property name="bottom_attach">6</property>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options"/>
|
||||
</packing>
|
||||
@ -717,25 +752,6 @@
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">5</property>
|
||||
<property name="bottom_attach">6</property>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options"/>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="dbuscheck">
|
||||
<property name="label" translatable="yes">DBus server</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_action_appearance">False</property>
|
||||
<property name="active">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="on_dbuscheck_toggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="right_attach">2</property>
|
||||
<property name="top_attach">6</property>
|
||||
|
@ -290,6 +290,12 @@ class PrefsEditor:
|
||||
#Always split with profile
|
||||
widget = guiget('always_split_with_profile')
|
||||
widget.set_active(self.config['always_split_with_profile'])
|
||||
# Putty paste style
|
||||
widget = guiget('putty_paste_style')
|
||||
widget.set_active(self.config['putty_paste_style'])
|
||||
# Smart copy
|
||||
widget = guiget('smart_copy')
|
||||
widget.set_active(self.config['smart_copy'])
|
||||
#Titlebar font selector
|
||||
# Use system font
|
||||
widget = guiget('title_system_font_checkbutton')
|
||||
@ -425,9 +431,6 @@ class PrefsEditor:
|
||||
# Copy on selection
|
||||
widget = guiget('copy_on_selection')
|
||||
widget.set_active(self.config['copy_on_selection'])
|
||||
# Putty paste style
|
||||
widget = guiget('putty_paste_style')
|
||||
widget.set_active(self.config['putty_paste_style'])
|
||||
# Word chars
|
||||
widget = guiget('word_chars_entry')
|
||||
widget.set_text(self.config['word_chars'])
|
||||
@ -730,6 +733,11 @@ class PrefsEditor:
|
||||
self.config['putty_paste_style'] = widget.get_active()
|
||||
self.config.save()
|
||||
|
||||
def on_smart_copy_toggled(self, widget):
|
||||
"""Putty paste style setting changed"""
|
||||
self.config['smart_copy'] = widget.get_active()
|
||||
self.config.save()
|
||||
|
||||
def on_cursor_blink_toggled(self, widget):
|
||||
"""Cursor blink setting changed"""
|
||||
self.config['cursor_blink'] = widget.get_active()
|
||||
|
@ -872,6 +872,8 @@ class Terminal(gtk.VBox):
|
||||
if self.vte.get_has_selection ():
|
||||
getattr(self, "key_" + mapping)()
|
||||
return(True)
|
||||
elif not self.config['smart_copy']:
|
||||
return(True)
|
||||
else:
|
||||
getattr(self, "key_" + mapping)()
|
||||
return(True)
|
||||
|
Loading…
Reference in New Issue
Block a user