Expose cursor blinking and colour in the prefs editor
This commit is contained in:
parent
8307951001
commit
eb7fcf5189
@ -162,7 +162,7 @@ DEFAULTS = {
|
||||
'color_scheme' : 'grey_on_black',
|
||||
'cursor_blink' : True,
|
||||
'cursor_shape' : 'block',
|
||||
'cursor_color' : '',
|
||||
'cursor_color' : '#aaaaaaaaaaaa',
|
||||
'emulation' : 'xterm',
|
||||
'font' : 'Mono 10',
|
||||
'foreground_color' : '#aaaaaaaaaaaa',
|
||||
|
@ -821,7 +821,7 @@
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="visual-bell-checkbutton">
|
||||
<property name="label" translatable="yes">Visual terminal _bell</property>
|
||||
<property name="label" translatable="yes">Visual terminal bell</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
@ -836,7 +836,7 @@
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="audible-bell-checkbutton">
|
||||
<property name="label" translatable="yes">Audible terminal _bell</property>
|
||||
<property name="label" translatable="yes">Audible terminal bell</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
@ -851,7 +851,7 @@
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="urgent-bell-checkbutton">
|
||||
<property name="label" translatable="yes">WM_URGENT terminal _bell</property>
|
||||
<property name="label" translatable="yes">Window manager bell</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
@ -864,46 +864,6 @@
|
||||
<property name="position">5</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkHBox" id="hbox140">
|
||||
<property name="visible">True</property>
|
||||
<property name="spacing">12</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label480">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Cursor _shape:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">cursor-shape-combobox</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkComboBox" id="cursor-shape-combobox">
|
||||
<property name="visible">True</property>
|
||||
<property name="model">CursorShapeListStore</property>
|
||||
<property name="active">0</property>
|
||||
<child>
|
||||
<object class="GtkCellRendererText" id="cellrenderertext4"/>
|
||||
<attributes>
|
||||
<attribute name="text">0</attribute>
|
||||
</attributes>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">6</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkHBox" id="hbox136">
|
||||
<property name="visible">True</property>
|
||||
@ -936,6 +896,134 @@
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">6</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkVBox" id="vbox8">
|
||||
<property name="visible">True</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<property name="spacing">6</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label21">
|
||||
<property name="visible">True</property>
|
||||
<property name="xalign">0</property>
|
||||
<property name="label" translatable="yes"><b>Cursor</b></property>
|
||||
<property name="use_markup">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkAlignment" id="alignment5">
|
||||
<property name="visible">True</property>
|
||||
<property name="left_padding">12</property>
|
||||
<child>
|
||||
<object class="GtkVBox" id="vbox9">
|
||||
<property name="visible">True</property>
|
||||
<property name="orientation">vertical</property>
|
||||
<child>
|
||||
<object class="GtkHBox" id="hbox140">
|
||||
<property name="visible">True</property>
|
||||
<property name="spacing">12</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label480">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Cursor _shape:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">cursor-shape-combobox</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkComboBox" id="cursor-shape-combobox">
|
||||
<property name="visible">True</property>
|
||||
<property name="model">CursorShapeListStore</property>
|
||||
<property name="active">0</property>
|
||||
<child>
|
||||
<object class="GtkCellRendererText" id="cellrenderertext4"/>
|
||||
<attributes>
|
||||
<attribute name="text">0</attribute>
|
||||
</attributes>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="cursor_blink">
|
||||
<property name="label" translatable="yes">Cursor blink</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkHBox" id="hbox4">
|
||||
<property name="visible">True</property>
|
||||
<property name="spacing">6</property>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label22">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes">Cursor colour:</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkColorButton" id="cursor_color">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
<property name="color">#000000000000</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="position">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="fill">False</property>
|
||||
<property name="position">7</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
@ -318,6 +318,9 @@ class PrefsEditor:
|
||||
# WM_URGENT terminal bell
|
||||
widget = guiget('urgent-bell-checkbutton')
|
||||
widget.set_active(self.config['urgent_bell'])
|
||||
# Word chars
|
||||
widget = guiget('word-chars-entry')
|
||||
widget.set_text(self.config['word_chars'])
|
||||
# Cursor shape
|
||||
widget = guiget('cursor-shape-combobox')
|
||||
if self.config['cursor_shape'] == 'underline':
|
||||
@ -327,9 +330,12 @@ class PrefsEditor:
|
||||
else:
|
||||
active = 0
|
||||
widget.set_active(active)
|
||||
# Word chars
|
||||
widget = guiget('word-chars-entry')
|
||||
widget.set_text(self.config['word_chars'])
|
||||
# Cursor blink
|
||||
widget = guiget('cursor_blink')
|
||||
widget.set_active(self.config['cursor_blink'])
|
||||
# Cursor colour
|
||||
widget = guiget('cursor_color')
|
||||
widget.set_color(gtk.gdk.Color(self.config['cursor_color']))
|
||||
|
||||
## Command tab
|
||||
# Login shell
|
||||
@ -480,6 +486,9 @@ class PrefsEditor:
|
||||
# Urgent Bell
|
||||
widget = guiget('urgent-bell-checkbutton')
|
||||
self.config['urgent_bell'] = widget.get_active()
|
||||
# Word chars
|
||||
widget = guiget('word-chars-entry')
|
||||
self.config['word_chars'] = widget.get_text()
|
||||
# Cursor Shape
|
||||
widget = guiget('cursor-shape-combobox')
|
||||
selected = widget.get_active()
|
||||
@ -490,9 +499,12 @@ class PrefsEditor:
|
||||
elif selected == 2:
|
||||
value = 'ibeam'
|
||||
self.config['cursor_shape'] = value
|
||||
# Word chars
|
||||
widget = guiget('word-chars-entry')
|
||||
self.config['word_chars'] = widget.get_text()
|
||||
# Cursor Blink
|
||||
widget = guiget('cursor_blink')
|
||||
self.config['cursor_blink'] = widget.get_active()
|
||||
# Cursor Colour
|
||||
widget = guiget('cursor_color')
|
||||
self.config['cursor_color'] = widget.get_color().to_string()
|
||||
|
||||
## Command tab
|
||||
# Login shell
|
||||
|
Loading…
Reference in New Issue
Block a user