# HG changeset patch # User voroshil # Date 1188408521 0 # Node ID a12f357e8bd023cef9dc58ff9a65215e332d27b6 # Parent 2381f759cbcf7c163bf5ff57193a04aa40e2e2b5 Implement Flash/Steady (swapping foreground/background colors) and Conceal (filling following chars with spaces) control characters. diff -r 2381f759cbcf -r a12f357e8bd0 stream/tvi_vbi.c --- a/stream/tvi_vbi.c Wed Aug 29 15:20:30 2007 +0000 +++ b/stream/tvi_vbi.c Wed Aug 29 17:28:41 2007 +0000 @@ -572,6 +572,7 @@ int bg_color=0; int row,col; int separated=0; + int conceal; for(row=0;row=0x08 && c<=0x0f){ + if(c>=0x08 && c<=0x09){//Flash/Steady + int tmp; + tmp=bg_color; + bg_color=fg_color; + fg_color=tmp; + if(c==0x09){ + p[i].fg=fg_color; + p[i].bg=bg_color; + } + }else if(c>=0x0a && c<=0x0f){ }else if (c<=0x17){ //colors fg_color=c&0x0f; gfx=c>>4; + conceal=0; }else if (c<=0x18){ + conceal=1; }else if (c<=0x1a){ //Contiguous/Separated gfx separated=!(c&1); }else if (c<=0x1b){ @@ -612,7 +625,10 @@ continue; } - if(gfx){ + if(conceal){ + p[i].gfx=0; + p[i].unicode=' '; + }else if(gfx){ p[i].unicode=c-0x20; if (p[i].unicode>0x3f) p[i].unicode-=0x20; }else