From 4cd3114c5013aeccd790582f6cd1dd2760be9dd0 Mon Sep 17 00:00:00 2001 From: james <> Date: Fri, 7 Mar 2008 12:37:04 +0000 Subject: *** empty log message *** --- src/crt.c | 43 +++++++++++++++++++++---------------------- 1 file changed, 21 insertions(+), 22 deletions(-) (limited to 'src/crt.c') diff --git a/src/crt.c b/src/crt.c index 8caca0c..2a5feaf 100644 --- a/src/crt.c +++ b/src/crt.c @@ -1,4 +1,4 @@ -/* +/* * crt.c: * * Copyright (c) 2008 James McKenzie , @@ -8,8 +8,11 @@ static char rcsid[] = "$Id$"; -/* +/* * $Log$ + * Revision 1.18 2008/03/07 12:37:04 james + * *** empty log message *** + * * Revision 1.17 2008/03/03 06:04:42 james * *** empty log message *** * @@ -71,16 +74,14 @@ crt_erase (CRT * c, CRT_Pos s, CRT_Pos e, int ea, int color) CRT_CA *ps = &c->screen[CRT_ADDR_POS (&s)]; CRT_CA *pe = &c->screen[CRT_ADDR_POS (&e)]; - while (ps <= pe) - { - ps->chr = ' '; - if (ea) - { - ps->attr = CRT_ATTR_NORMAL; - ps->color = color; - } - ps++; + while (ps <= pe) { + ps->chr = ' '; + if (ea) { + ps->attr = CRT_ATTR_NORMAL; + ps->color = color; } + ps++; + } } @@ -122,11 +123,10 @@ crt_scroll_up (CRT * c, CRT_Pos s, CRT_Pos e, int ea, int color) p = CRT_ADDR_POS (&s); - while (n--) - { - memcpy (&c->screen[p], &c->screen[p + CRT_COLS], l); - p += CRT_COLS; - } + while (n--) { + memcpy (&c->screen[p], &c->screen[p + CRT_COLS], l); + p += CRT_COLS; + } s.y = e.y; crt_erase (c, s, e, ea, color); @@ -153,15 +153,14 @@ crt_scroll_down (CRT * c, CRT_Pos s, CRT_Pos e, int ea, int color) l *= sizeof (CRT_CA); n = e.y - s.y; - //n++; + // n++; p = CRT_ADDR_POS (&e); - while (n--) - { - p -= CRT_COLS; - memcpy (&c->screen[p], &c->screen[p - CRT_COLS], l); - } + while (n--) { + p -= CRT_COLS; + memcpy (&c->screen[p], &c->screen[p - CRT_COLS], l); + } e.y = s.y; crt_erase (c, s, e, ea, color); -- cgit v1.2.3