raster pushed a commit to branch master.
commit 6ad334c86433f48c7930588d7a5c97b73fc269ff
Author: Carsten Haitzler (Rasterman) <[email protected]>
Date: Mon Apr 15 23:53:28 2013 +0900
zero out fmt bits for dbl width chars for spare cell.
---
src/bin/termpty.h | 2 ++
src/bin/termptyops.c | 7 +++++--
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/src/bin/termpty.h b/src/bin/termpty.h
index b6840f1..6c49d93 100644
--- a/src/bin/termpty.h
+++ b/src/bin/termpty.h
@@ -190,3 +190,5 @@ extern int _termpty_log_dom;
#define TERMPTY_SCREEN(Tpty, X, Y) \
Tpty->screen[X + (((Y + Tpty->circular_offset) % Tpty->h) * Tpty->w)]
+#define TERMPTY_FMTCLR(Tatt) \
+ (Tatt).autowrapped = (Tatt).newline = (Tatt).tab = 0
diff --git a/src/bin/termptyops.c b/src/bin/termptyops.c
index c102b44..8c3f2b7 100644
--- a/src/bin/termptyops.c
+++ b/src/bin/termptyops.c
@@ -197,8 +197,11 @@ _termpty_text_append(Termpty *ty, const Eina_Unicode
*codepoints, int len)
#if defined(SUPPORT_DBLWIDTH)
cells[ty->state.cx].att.dblwidth = _termpty_is_dblwidth_get(ty, g);
if ((cells[ty->state.cx].att.dblwidth) && (ty->state.cx < (ty->w - 1)))
- termpty_cell_codepoint_att_fill(ty, 0, cells[ty->state.cx].att,
- &(cells[ty->state.cx + 1]), 1);
+ {
+ TERMPTY_FMTCLR(cells[ty->state.cx].att);
+ termpty_cell_codepoint_att_fill(ty, 0, cells[ty->state.cx].att,
+ &(cells[ty->state.cx + 1]), 1);
+ }
#endif
if (ty->state.wrap)
{
--
------------------------------------------------------------------------------
Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
http://www2.precog.com/precogplatform/slashdotnewsletter