[vte/vte-next: 162/223] Don't make is_word_char public
- From: Christian Persch <chpe src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte/vte-next: 162/223] Don't make is_word_char public
- Date: Wed, 22 Jun 2011 21:02:12 +0000 (UTC)
commit 0f1ae6c4b520edd70efd80d3a1273b321508674b
Author: Christian Persch <chpe gnome org>
Date: Sat Jun 11 23:28:05 2011 +0200
Don't make is_word_char public
doc/reference/vte-sections.txt | 1 -
src/vte-private.h | 1 +
src/vte.c | 11 +++++------
src/vte.h | 1 -
src/vteaccess.c | 32 ++++++++++++++++----------------
5 files changed, 22 insertions(+), 24 deletions(-)
---
diff --git a/doc/reference/vte-sections.txt b/doc/reference/vte-sections.txt
index f76536e..8cda4c4 100644
--- a/doc/reference/vte-sections.txt
+++ b/doc/reference/vte-sections.txt
@@ -27,7 +27,6 @@ vte_terminal_set_scroll_on_output
vte_terminal_set_scroll_on_keystroke
vte_terminal_get_has_selection
vte_terminal_set_word_chars
-vte_terminal_is_word_char
vte_terminal_set_mouse_autohide
vte_terminal_get_mouse_autohide
vte_terminal_match_add_gregex
diff --git a/src/vte-private.h b/src/vte-private.h
index 0cade1f..28f091f 100644
--- a/src/vte-private.h
+++ b/src/vte-private.h
@@ -464,6 +464,7 @@ void _vte_terminal_set_effect_color(VteTerminal *terminal,
VteTerminalEffect effect,
gboolean override);
+gboolean _vte_terminal_is_word_char(VteTerminal *terminal, gunichar c);
/* private VteBuffer methods */
diff --git a/src/vte.c b/src/vte.c
index dbd61a0..22e799d 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -4999,8 +4999,8 @@ vte_terminal_key_release(GtkWidget *widget, GdkEventKey *event)
&& gtk_im_context_filter_keypress (terminal->term_pvt->im_context, event);
}
-/**
- * vte_terminal_is_word_char:
+/*
+ * __vte_terminal_is_word_char:
* @terminal: a #VteTerminal
* @c: a candidate Unicode code point
*
@@ -5010,11 +5010,10 @@ vte_terminal_key_release(GtkWidget *widget, GdkEventKey *event)
* Returns: %TRUE if the character is considered to be part of a word
*/
gboolean
-vte_terminal_is_word_char(VteTerminal *terminal, gunichar c)
+_vte_terminal_is_word_char(VteTerminal *terminal, gunichar c)
{
guint i;
VteWordCharRange *range;
- g_return_val_if_fail(VTE_IS_TERMINAL(terminal), FALSE);
if (terminal->pvt->word_chars != NULL) {
/* Go through each range and check if c is included. */
@@ -5047,7 +5046,7 @@ vte_same_class(VteTerminal *terminal, glong acol, glong arow,
const VteCell *pcell = NULL;
gboolean word_char;
if ((pcell = vte_screen_find_charcell(terminal->pvt->screen, acol, arow)) != NULL && pcell->c != 0) {
- word_char = vte_terminal_is_word_char(terminal, _vte_unistr_get_base (pcell->c));
+ word_char = _vte_terminal_is_word_char(terminal, _vte_unistr_get_base (pcell->c));
/* Lets not group non-wordchars together (bug #25290) */
if (!word_char)
@@ -5057,7 +5056,7 @@ vte_same_class(VteTerminal *terminal, glong acol, glong arow,
if (pcell == NULL || pcell->c == 0) {
return FALSE;
}
- if (word_char != vte_terminal_is_word_char(terminal, _vte_unistr_get_base (pcell->c))) {
+ if (word_char != _vte_terminal_is_word_char(terminal, _vte_unistr_get_base (pcell->c))) {
return FALSE;
}
return TRUE;
diff --git a/src/vte.h b/src/vte.h
index 896f3ec..7fd46fb 100644
--- a/src/vte.h
+++ b/src/vte.h
@@ -147,7 +147,6 @@ gboolean vte_terminal_get_has_selection(VteTerminal *terminal);
* (to get a hyphen, place it first), and check if a character is in the
* range. */
void vte_terminal_set_word_chars(VteTerminal *terminal, const char *spec);
-gboolean vte_terminal_is_word_char(VteTerminal *terminal, gunichar c);
/* Manipulate the autohide setting. */
void vte_terminal_set_mouse_autohide(VteTerminal *terminal, gboolean setting);
diff --git a/src/vteaccess.c b/src/vteaccess.c
index 0897a05..1d7c49a 100644
--- a/src/vteaccess.c
+++ b/src/vteaccess.c
@@ -1046,7 +1046,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
/* Back up to the previous non-word-word transition. */
while (offset > 0) {
prev = vte_terminal_accessible_get_character_at_offset(text, offset - 1);
- if (vte_terminal_is_word_char(terminal, prev)) {
+ if (_vte_terminal_is_word_char(terminal, prev)) {
offset--;
} else {
break;
@@ -1060,7 +1060,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
if (direction == direction_previous) {
while (offset > 0) {
prev = vte_terminal_accessible_get_character_at_offset(text, offset - 1);
- if (!vte_terminal_is_word_char(terminal, prev)) {
+ if (!_vte_terminal_is_word_char(terminal, prev)) {
offset--;
} else {
break;
@@ -1068,7 +1068,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
}
while (offset > 0) {
prev = vte_terminal_accessible_get_character_at_offset(text, offset - 1);
- if (vte_terminal_is_word_char(terminal, prev)) {
+ if (_vte_terminal_is_word_char(terminal, prev)) {
offset--;
} else {
break;
@@ -1083,7 +1083,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
if (direction == direction_next) {
while (offset < (int) priv->snapshot_characters->len) {
next = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (vte_terminal_is_word_char(terminal, next)) {
+ if (_vte_terminal_is_word_char(terminal, next)) {
offset++;
} else {
break;
@@ -1091,7 +1091,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
}
while (offset < (int) priv->snapshot_characters->len) {
next = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (!vte_terminal_is_word_char(terminal, next)) {
+ if (!_vte_terminal_is_word_char(terminal, next)) {
offset++;
} else {
break;
@@ -1102,7 +1102,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
/* Now find the end of this word. */
while (offset < (int) priv->snapshot_characters->len) {
current = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (vte_terminal_is_word_char(terminal, current)) {
+ if (_vte_terminal_is_word_char(terminal, current)) {
offset++;
} else {
break;
@@ -1112,7 +1112,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
/* Now find the next non-word-word transition */
while (offset < (int) priv->snapshot_characters->len) {
next = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (!vte_terminal_is_word_char(terminal, next)) {
+ if (!_vte_terminal_is_word_char(terminal, next)) {
offset++;
} else {
break;
@@ -1125,8 +1125,8 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
current = vte_terminal_accessible_get_character_at_offset(text, offset);
while (offset > 0) {
prev = vte_terminal_accessible_get_character_at_offset(text, offset - 1);
- if (vte_terminal_is_word_char(terminal, prev) &&
- !vte_terminal_is_word_char(terminal, current)) {
+ if (_vte_terminal_is_word_char(terminal, prev) &&
+ !_vte_terminal_is_word_char(terminal, current)) {
break;
} else {
offset--;
@@ -1141,7 +1141,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
if (direction == direction_previous) {
while (offset > 0) {
prev = vte_terminal_accessible_get_character_at_offset(text, offset - 1);
- if (vte_terminal_is_word_char(terminal, prev)) {
+ if (_vte_terminal_is_word_char(terminal, prev)) {
offset--;
} else {
break;
@@ -1150,8 +1150,8 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
current = vte_terminal_accessible_get_character_at_offset(text, offset);
while (offset > 0) {
prev = vte_terminal_accessible_get_character_at_offset(text, offset - 1);
- if (vte_terminal_is_word_char(terminal, prev) &&
- !vte_terminal_is_word_char(terminal, current)) {
+ if (_vte_terminal_is_word_char(terminal, prev) &&
+ !_vte_terminal_is_word_char(terminal, current)) {
break;
} else {
offset--;
@@ -1167,7 +1167,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
if (direction == direction_next) {
while (offset < (int) priv->snapshot_characters->len) {
current = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (!vte_terminal_is_word_char(terminal, current)) {
+ if (!_vte_terminal_is_word_char(terminal, current)) {
offset++;
} else {
break;
@@ -1175,7 +1175,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
}
while (offset < (int) priv->snapshot_characters->len) {
current = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (vte_terminal_is_word_char(terminal, current)) {
+ if (_vte_terminal_is_word_char(terminal, current)) {
offset++;
} else {
break;
@@ -1186,7 +1186,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
/* Now find the next word end. */
while (offset < (int) priv->snapshot_characters->len) {
current = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (!vte_terminal_is_word_char(terminal, current)) {
+ if (!_vte_terminal_is_word_char(terminal, current)) {
offset++;
} else {
break;
@@ -1194,7 +1194,7 @@ vte_terminal_accessible_get_text_somewhere(AtkText *text,
}
while (offset < (int) priv->snapshot_characters->len) {
current = vte_terminal_accessible_get_character_at_offset(text, offset);
- if (vte_terminal_is_word_char(terminal, current)) {
+ if (_vte_terminal_is_word_char(terminal, current)) {
offset++;
} else {
break;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]