--- a/gntentry.c Thu Apr 25 23:50:44 2019 -0400
+++ b/gntentry.c Fri Apr 26 08:21:13 2019 +0000
@@ -389,6 +389,17 @@
+scroll_to_fit(GntEntry *entry) + GntEntryPrivate *priv = gnt_entry_get_instance_private(entry); + while (gnt_util_onscreen_width(priv->scroll, priv->cursor) >= + GNT_WIDGET(entry)->priv.width) { + priv->scroll = g_utf8_find_next_char(priv->scroll, NULL); move_forward(GntBindable *bind, G_GNUC_UNUSED GList *params)
@@ -400,10 +411,7 @@
priv->cursor = g_utf8_find_next_char(priv->cursor, NULL);
- while (gnt_util_onscreen_width(priv->scroll, priv->cursor) >=
- GNT_WIDGET(entry)->priv.width) {
- priv->scroll = g_utf8_find_next_char(priv->scroll, NULL);
update_kill_ring(priv, ENTRY_JAIL, NULL, 0);
entry_redraw(GNT_WIDGET(entry));
@@ -487,10 +495,7 @@
priv->cursor = priv->end;
/* This should be better than this */
- while (gnt_util_onscreen_width(priv->scroll, priv->cursor) >=
- GNT_WIDGET(entry)->priv.width) {
- priv->scroll = g_utf8_find_next_char(priv->scroll, NULL);
entry_redraw(GNT_WIDGET(entry));
update_kill_ring(priv, ENTRY_JAIL, NULL, 0);
@@ -815,10 +820,7 @@
GntEntryPrivate *priv = gnt_entry_get_instance_private(entry);
GntWidget *widget = GNT_WIDGET(bind);
priv->cursor = (char *)next_begin_word(priv->cursor, priv->end);
- while (gnt_util_onscreen_width(priv->scroll, priv->cursor) >=
- priv->scroll = g_utf8_find_next_char(priv->scroll, NULL);
update_kill_ring(priv, ENTRY_JAIL, NULL, 0);
@@ -972,12 +974,7 @@
- while (gnt_util_onscreen_width(priv->scroll,
- priv->scroll = g_utf8_find_next_char(
show_suggest_dropdown(entry);