[geany/geany] e083c8: reflow: Use plain ASCII space instead of `GDK_space`
Colomban Wendling
git-noreply at xxxxx
Mon Jan 4 21:30:32 UTC 2016
Branch: refs/heads/master
Author: Colomban Wendling <ban at herbesfolles.org>
Committer: Colomban Wendling <ban at herbesfolles.org>
Date: Mon, 04 Jan 2016 21:30:32 UTC
Commit: e083c8d1c933aadc7b5c8892810902e99de5f752
https://github.com/geany/geany/commit/e083c8d1c933aadc7b5c8892810902e99de5f752
Log Message:
-----------
reflow: Use plain ASCII space instead of `GDK_space`
`GDK_space` is not guaranteed to have the value of an ASCII space
(although it does in practice), and using a GDK constant does not make
sense inside a text manipulation function.
Modified Paths:
--------------
src/keybindings.c
Modified: src/keybindings.c
8 lines changed, 4 insertions(+), 4 deletions(-)
===================================================================
@@ -2216,7 +2216,7 @@ static gint split_line(GeanyEditor *editor, gint column)
gint pos;
/* don't split on a trailing space of a line */
- if (sci_get_char_at(sci, lend - 1) == GDK_space)
+ if (sci_get_char_at(sci, lend - 1) == ' ')
lend--;
/* detect when the line is short enough and no more splitting is needed */
@@ -2227,7 +2227,7 @@ static gint split_line(GeanyEditor *editor, gint column)
found = FALSE;
for (pos = edge - 1; pos > lstart; pos--)
{
- if (sci_get_char_at(sci, pos) == GDK_space)
+ if (sci_get_char_at(sci, pos) == ' ')
{
found = TRUE;
break;
@@ -2237,7 +2237,7 @@ static gint split_line(GeanyEditor *editor, gint column)
{
for (pos = edge; pos < lend; pos++)
{
- if (sci_get_char_at(sci, pos) == GDK_space)
+ if (sci_get_char_at(sci, pos) == ' ')
{
found = TRUE;
break;
@@ -2245,7 +2245,7 @@ static gint split_line(GeanyEditor *editor, gint column)
}
}
/* don't split right before a space */
- while (pos + 1 <= lend && sci_get_char_at(sci, pos + 1) == GDK_space)
+ while (pos + 1 <= lend && sci_get_char_at(sci, pos + 1) == ' ')
pos++;
if (!found || pos >= lend)
--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).
More information about the Commits
mailing list