[vte] Bug 587463 - "select all"+copy from gnome-terminal includes lines no longer in scrollback
- From: Behdad Esfahbod <behdad src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [vte] Bug 587463 - "select all"+copy from gnome-terminal includes lines no longer in scrollback
- Date: Sat, 24 Oct 2009 01:03:16 +0000 (UTC)
commit 471d90f670416fc2947b73637c549387eddb9435
Author: Behdad Esfahbod <behdad behdad org>
Date: Fri Oct 23 21:01:49 2009 -0400
Bug 587463 - "select all"+copy from gnome-terminal includes lines no longer in scrollback
Previously it used to include lines that have fallen out of the history
buffer. Also, included one extra line at the end.
src/vte.c | 17 +++++++----------
1 files changed, 7 insertions(+), 10 deletions(-)
---
diff --git a/src/vte.c b/src/vte.c
index 902a821..0a6ada8 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -6658,31 +6658,28 @@ vte_terminal_set_selection_block_mode (VteTerminal *terminal,
void
vte_terminal_select_all (VteTerminal *terminal)
{
- long delta;
-
g_return_if_fail (VTE_IS_TERMINAL (terminal));
vte_terminal_deselect_all (terminal);
- delta = terminal->pvt->screen->scroll_delta;
-
terminal->pvt->has_selection = TRUE;
terminal->pvt->selecting_had_delta = TRUE;
terminal->pvt->selecting_restart = FALSE;
+ terminal->pvt->selection_start.row = _vte_ring_delta (terminal->pvt->screen->row_data);
terminal->pvt->selection_start.col = 0;
- terminal->pvt->selection_start.row = 0;
- terminal->pvt->selection_end.col = terminal->column_count;
- terminal->pvt->selection_end.row = delta + terminal->row_count;
+ terminal->pvt->selection_end.row = terminal->pvt->screen->scroll_delta + terminal->row_count;
+ terminal->pvt->selection_end.col = 0;
_vte_debug_print(VTE_DEBUG_SELECTION, "Selecting *all* text.\n");
g_free (terminal->pvt->selection);
terminal->pvt->selection =
vte_terminal_get_text_range (terminal,
- 0, 0,
- delta + terminal->row_count,
- terminal->column_count,
+ terminal->pvt->selection_start.row,
+ terminal->pvt->selection_start.col,
+ terminal->pvt->selection_end.row,
+ terminal->pvt->selection_end.col,
vte_cell_is_selected,
NULL, NULL);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]