consistency - sob - simple output bar
 (HTM) git clone git://git.codemadness.org/sob
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit a887d6f07bb03b0d3276485d03b827f6cd908ccd
 (DIR) parent d89e9df43c6b3966fc438d925680ac8ff25f6e2f
 (HTM) Author: Hiltjo Posthuma <hiltjo@codemadness.org>
       Date:   Fri, 10 Oct 2014 14:05:25 +0000
       
       consistency
       
       Diffstat:
         M sob.c                               |      14 ++++++++------
       
       1 file changed, 8 insertions(+), 6 deletions(-)
       ---
 (DIR) diff --git a/sob.c b/sob.c
       @@ -281,8 +281,8 @@ line_cursor_wordnext(void)
        static void
        line_cursor_begin(void)
        {
       -        line.utfpos = 0;
                line.bytepos = 0;
       +        line.utfpos = 0;
                line_cursor_move(line.utfpos);
        }
        
       @@ -346,8 +346,8 @@ line_delcharnext(void)
                        line.bytesiz - line.bytepos - siz);
        
                line.bytesiz -= siz;
       -        line.utflen--;
                line.line[line.bytesiz] = '\0';
       +        line.utflen--;
                line_draw();
        }
        
       @@ -363,11 +363,12 @@ line_delcharprev(void)
        
                memmove(&line.line[line.bytepos - siz], &line.line[line.bytepos],
                        line.bytesiz - line.bytepos);
       -        line.utflen--;
       -        line.utfpos--;
                line.bytepos -= siz;
                line.bytesiz -= siz;
                line.line[line.bytesiz] = '\0';
       +        line.utflen--;
       +        line.utfpos--;
       +
                line_draw();
        }
        
       @@ -378,6 +379,7 @@ line_deltoend(void)
                line.bytesiz = line.bytepos;
                line.utflen = utf8len(line.line);
                line.utfpos = line.utflen;
       +
                line_draw();
        }
        
       @@ -395,9 +397,9 @@ line_delwordcursor(void)
        
                line.bytesiz -= siz;
                line.bytepos -= siz;
       +        line.line[line.bytesiz] = '\0';
                line.utfpos -= len;
                line.utflen -= len;
       -        line.line[line.bytesiz] = '\0';
        
                line_draw();
        }
       @@ -420,9 +422,9 @@ line_delwordprev(void)
        
                line.bytesiz -= siz;
                line.bytepos -= siz;
       +        line.line[line.bytesiz] = '\0';
                line.utfpos -= len;
                line.utflen -= len;
       -        line.line[line.bytesiz] = '\0';
        
                line_draw();
        }