jaehyun pushed a commit to branch master.

http://git.enlightenment.org/tools/enventor.git/commit/?id=e940639079c9d73ce03be6333c917a8d1a73a8fa

commit e940639079c9d73ce03be6333c917a8d1a73a8fa
Author: Jaehyun Cho <jae_hyun....@samsung.com>
Date:   Thu Mar 17 14:52:35 2016 +0900

    indent: Check '\r' when indented code line is created on Windows.
    
    On Windows, new line is represented as "\r\n".
    Therefore, '\r' is checked when indented code line is created.
    Otherwise, unnecessary newlines are inserted after indentation on
    Windows.
---
 src/lib/indent.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/lib/indent.c b/src/lib/indent.c
index 3c3648d..1f62bc4 100644
--- a/src/lib/indent.c
+++ b/src/lib/indent.c
@@ -263,7 +263,8 @@ indent_code_lines_create(indent_data *id EINA_UNUSED, const 
char *utf8)
     */
    while (utf8_ptr < utf8_end)
      {
-        if (*utf8_ptr != ' ' && *utf8_ptr != '\t' &&  *utf8_ptr != '\n' )
+        if (*utf8_ptr != ' ' && *utf8_ptr != '\t' &&  *utf8_ptr != '\n' &&
+            *utf8_ptr != '\r')
           {
              //Renew the start position of lexeme.
              if (!keep_lexem_start_pos) utf8_lexem = utf8_ptr;

-- 


Reply via email to