[vte] emulation: Remove status line support
- From: Egmont Koblinger <egmontkob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte] emulation: Remove status line support
- Date: Sun, 18 May 2014 17:53:41 +0000 (UTC)
commit 462e4ffb6ec3a188a5b3ed76821263f63acacebb
Author: Egmont Koblinger <egmont gmail com>
Date: Sun May 18 19:53:20 2014 +0200
emulation: Remove status line support
doc/reference/vte-sections.txt | 1 -
src/app.vala | 6 ---
src/vte-private.h | 3 -
src/vte.c | 81 ----------------------------------------
src/vteseq-2.gperf | 4 +-
src/vteseq.c | 16 --------
src/vteterminal.h | 4 --
7 files changed, 2 insertions(+), 113 deletions(-)
---
diff --git a/doc/reference/vte-sections.txt b/doc/reference/vte-sections.txt
index 3fc98ec..7068d4f 100644
--- a/doc/reference/vte-sections.txt
+++ b/doc/reference/vte-sections.txt
@@ -70,7 +70,6 @@ vte_terminal_set_emulation
vte_terminal_get_emulation
vte_terminal_set_encoding
vte_terminal_get_encoding
-vte_terminal_get_status_line
vte_terminal_write_contents
vte_terminal_search_find_next
vte_terminal_search_find_previous
diff --git a/src/app.vala b/src/app.vala
index 4c5ca02..9e15667 100644
--- a/src/app.vala
+++ b/src/app.vala
@@ -98,7 +98,6 @@ class Window : Gtk.ApplicationWindow
terminal.resize_window.connect(resize_window_cb);
terminal.restore_window.connect(restore_window_cb);
terminal.selection_changed.connect(selection_changed_cb);
- terminal.status_line_changed.connect(status_line_changed_cb);
terminal.window_title_changed.connect(window_title_changed_cb);
if (App.Options.object_notifications)
terminal.notify.connect(notify_cb);
@@ -502,11 +501,6 @@ class Window : Gtk.ApplicationWindow
update_copy_sensitivity();
}
- private void status_line_changed_cb(Vte.Terminal terminal)
- {
- print("Status: `%s'\n", terminal.get_status_line());
- }
-
private void window_title_changed_cb(Vte.Terminal terminal)
{
set_title(terminal.get_window_title());
diff --git a/src/vte-private.h b/src/vte-private.h
index 4d983e6..ee0f0a5 100644
--- a/src/vte-private.h
+++ b/src/vte-private.h
@@ -240,9 +240,6 @@ struct _VteTerminalPrivate {
fore/back with no
character data */
gboolean alternate_charset;
- gboolean status_line;
- GString *status_line_contents;
- gboolean status_line_changed;
} normal_screen, alternate_screen, *screen;
/* Selection information. */
diff --git a/src/vte.c b/src/vte.c
index 056d915..e0376ec 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -931,16 +931,6 @@ vte_terminal_emit_char_size_changed(VteTerminal *terminal,
/* g_object_notify(G_OBJECT(terminal), "char-size"); */
}
-/* Emit a "status-line-changed" signal. */
-static void
-_vte_terminal_emit_status_line_changed(VteTerminal *terminal)
-{
- _vte_debug_print(VTE_DEBUG_SIGNALS,
- "Emitting `status-line-changed'.\n");
- g_signal_emit_by_name(terminal, "status-line-changed");
-/* g_object_notify(G_OBJECT(terminal), "status-line"); */
-}
-
/* Emit an "increase-font-size" signal. */
static void
vte_terminal_emit_increase_font_size(VteTerminal *terminal)
@@ -3049,13 +3039,6 @@ _vte_terminal_insert_char(VteTerminal *terminal, gunichar c,
c = _vte_iso2022_process_single(terminal->pvt->iso2022, c, '0');
}
- /* If this character is destined for the status line, save it. */
- if (G_UNLIKELY (screen->status_line)) {
- g_string_append_unichar(screen->status_line_contents, c);
- screen->status_line_changed = TRUE;
- return FALSE;
- }
-
/* Figure out how many columns this character should occupy. */
if (G_UNLIKELY (VTE_ISO2022_HAS_ENCODED_WIDTH(c))) {
columns = _vte_iso2022_get_encoded_width(c);
@@ -8120,13 +8103,11 @@ vte_terminal_init(VteTerminal *terminal)
/* Initialize the screens and histories. */
_vte_ring_init (pvt->alternate_screen.row_data, terminal->pvt->row_count);
pvt->alternate_screen.sendrecv_mode = TRUE;
- pvt->alternate_screen.status_line_contents = g_string_new(NULL);
pvt->screen = &terminal->pvt->alternate_screen;
_vte_terminal_set_default_attributes(terminal);
_vte_ring_init (pvt->normal_screen.row_data, VTE_SCROLLBACK_INIT);
pvt->normal_screen.sendrecv_mode = TRUE;
- pvt->normal_screen.status_line_contents = g_string_new(NULL);
pvt->screen = &terminal->pvt->normal_screen;
_vte_terminal_set_default_attributes(terminal);
@@ -8600,12 +8581,6 @@ vte_terminal_finalize(GObject *object)
_vte_ring_fini(terminal->pvt->normal_screen.row_data);
_vte_ring_fini(terminal->pvt->alternate_screen.row_data);
- /* Clear the status lines. */
- g_string_free(terminal->pvt->normal_screen.status_line_contents,
- TRUE);
- g_string_free(terminal->pvt->alternate_screen.status_line_contents,
- TRUE);
-
/* Free conversion descriptors. */
if (terminal->pvt->outgoing_conv != VTE_INVALID_CONV) {
_vte_conv_close(terminal->pvt->outgoing_conv);
@@ -10933,7 +10908,6 @@ vte_terminal_class_init(VteTerminalClass *klass)
klass->selection_changed = NULL;
klass->contents_changed = NULL;
klass->cursor_moved = NULL;
- klass->status_line_changed = NULL;
klass->commit = NULL;
klass->deiconify_window = NULL;
@@ -11323,22 +11297,6 @@ vte_terminal_class_init(VteTerminalClass *klass)
G_TYPE_NONE, 2, G_TYPE_UINT, G_TYPE_UINT);
/**
- * VteTerminal::status-line-changed:
- * @vteterminal: the object which received the signal
- *
- * Emitted whenever the contents of the status line are modified or
- * cleared.
- */
- g_signal_new(I_("status-line-changed"),
- G_OBJECT_CLASS_TYPE(klass),
- G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET(VteTerminalClass, status_line_changed),
- NULL,
- NULL,
- g_cclosure_marshal_VOID__VOID,
- G_TYPE_NONE, 0);
-
- /**
* VteTerminal::increase-font-size:
* @vteterminal: the object which received the signal
*
@@ -12618,21 +12576,6 @@ vte_terminal_reset(VteTerminal *terminal,
pvt->alternate_screen.insert_delta = 0;
_vte_terminal_adjust_adjustments_full (terminal);
}
- /* Clear the status lines. */
- pvt->normal_screen.status_line = FALSE;
- pvt->normal_screen.status_line_changed = FALSE;
- if (pvt->normal_screen.status_line_contents != NULL) {
- g_string_free(pvt->normal_screen.status_line_contents,
- TRUE);
- }
- pvt->normal_screen.status_line_contents = g_string_new(NULL);
- pvt->alternate_screen.status_line = FALSE;
- pvt->alternate_screen.status_line_changed = FALSE;
- if (pvt->alternate_screen.status_line_contents != NULL) {
- g_string_free(pvt->alternate_screen.status_line_contents,
- TRUE);
- }
- pvt->alternate_screen.status_line_contents = g_string_new(NULL);
/* Do more stuff we refer to as a "full" reset. */
if (clear_tabstops) {
vte_terminal_set_default_tabstops(terminal);
@@ -12695,25 +12638,6 @@ vte_terminal_reset(VteTerminal *terminal,
}
/**
- * vte_terminal_get_status_line:
- * @terminal: a #VteTerminal
- *
- * Some terminal emulations specify a status line which is separate from the
- * main display area, and define a means for applications to move the cursor
- * to the status line and back.
- *
- * Returns: (transfer none): the current contents of the terminal's status line.
- * For terminals like "xterm", this will usually be the empty string. The string
- * must not be modified or freed by the caller.
- */
-const char *
-vte_terminal_get_status_line(VteTerminal *terminal)
-{
- g_return_val_if_fail(VTE_IS_TERMINAL(terminal), NULL);
- return terminal->pvt->screen->status_line_contents->str;
-}
-
-/**
* vte_terminal_get_char_width:
* @terminal: a #VteTerminal
*
@@ -13196,11 +13120,6 @@ vte_terminal_emit_pending_signals(VteTerminal *terminal)
vte_terminal_emit_adjustment_changed (terminal);
- if (terminal->pvt->screen->status_line_changed) {
- _vte_terminal_emit_status_line_changed (terminal);
- terminal->pvt->screen->status_line_changed = FALSE;
- }
-
if (terminal->pvt->window_title_changed) {
g_free (terminal->pvt->window_title);
terminal->pvt->window_title = terminal->pvt->window_title_changed;
diff --git a/src/vteseq-2.gperf b/src/vteseq-2.gperf
index e18c2f8..7179159 100644
--- a/src/vteseq-2.gperf
+++ b/src/vteseq-2.gperf
@@ -180,7 +180,7 @@ struct vteseq_2_struct {
"ed", VTE_SEQUENCE_HANDLER(vte_sequence_handler_noop)
"ei", VTE_SEQUENCE_HANDLER(vte_sequence_handler_ei)
"ff", VTE_SEQUENCE_HANDLER(vte_sequence_handler_noop)
-"fs", VTE_SEQUENCE_HANDLER(vte_sequence_handler_fs)
+#"fs", VTE_SEQUENCE_HANDLER_NULL
#"hd", VTE_SEQUENCE_HANDLER_NULL
"ho", VTE_SEQUENCE_HANDLER(vte_sequence_handler_ho)
#"hu", VTE_SEQUENCE_HANDLER_NULL
@@ -279,7 +279,7 @@ struct vteseq_2_struct {
"ta", VTE_SEQUENCE_HANDLER(vte_sequence_handler_ta)
"te", VTE_SEQUENCE_HANDLER(vte_sequence_handler_noop)
"ti", VTE_SEQUENCE_HANDLER(vte_sequence_handler_noop)
-"ts", VTE_SEQUENCE_HANDLER(vte_sequence_handler_ts)
+#"ts", VTE_SEQUENCE_HANDLER_NULL
"uc", VTE_SEQUENCE_HANDLER(vte_sequence_handler_uc)
"ue", VTE_SEQUENCE_HANDLER(vte_sequence_handler_ue)
"up", VTE_SEQUENCE_HANDLER(vte_sequence_handler_up)
diff --git a/src/vteseq.c b/src/vteseq.c
index b404b93..dceb4d5 100644
--- a/src/vteseq.c
+++ b/src/vteseq.c
@@ -1572,13 +1572,6 @@ vte_sequence_handler_form_feed (VteTerminal *terminal, GValueArray *params)
vte_sequence_handler_index (terminal, params);
}
-/* Move from status line. */
-static void
-vte_sequence_handler_fs (VteTerminal *terminal, GValueArray *params)
-{
- terminal->pvt->screen->status_line = FALSE;
-}
-
/* Move the cursor to the home position. */
static void
vte_sequence_handler_ho (VteTerminal *terminal, GValueArray *params)
@@ -2184,15 +2177,6 @@ vte_sequence_handler_tab_clear (VteTerminal *terminal, GValueArray *params)
}
}
-/* Move to status line. */
-static void
-vte_sequence_handler_ts (VteTerminal *terminal, GValueArray *params)
-{
- terminal->pvt->screen->status_line = TRUE;
- terminal->pvt->screen->status_line_changed = TRUE;
- g_string_truncate(terminal->pvt->screen->status_line_contents, 0);
-}
-
/* Underline this character and move right. */
static void
vte_sequence_handler_uc (VteTerminal *terminal, GValueArray *params)
diff --git a/src/vteterminal.h b/src/vteterminal.h
index c7e216a..0cfc25f 100644
--- a/src/vteterminal.h
+++ b/src/vteterminal.h
@@ -78,7 +78,6 @@ struct _VteTerminalClass {
void (*selection_changed)(VteTerminal* terminal);
void (*contents_changed)(VteTerminal* terminal);
void (*cursor_moved)(VteTerminal* terminal);
- void (*status_line_changed)(VteTerminal* terminal);
void (*commit)(VteTerminal* terminal, const gchar *text, guint size);
void (*deiconify_window)(VteTerminal* terminal);
@@ -339,9 +338,6 @@ void vte_terminal_set_cjk_ambiguous_width(VteTerminal *terminal,
int width) _VTE_GNUC_NONNULL(1);
int vte_terminal_get_cjk_ambiguous_width(VteTerminal *terminal) _VTE_GNUC_NONNULL(1);
-/* Get the contents of the status line. */
-const char *vte_terminal_get_status_line(VteTerminal *terminal) _VTE_GNUC_NONNULL(1);
-
void vte_terminal_set_pty(VteTerminal *terminal,
VtePty *pty) _VTE_GNUC_NONNULL(1);
VtePty *vte_terminal_get_pty(VteTerminal *terminal) _VTE_GNUC_NONNULL(1);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]