diff options
author | geronet <geronet@3ae390bd-cb1e-0410-b409-cd5a39f66f1f> | 2006-02-24 13:07:10 +0000 |
---|---|---|
committer | geronet <geronet@3ae390bd-cb1e-0410-b409-cd5a39f66f1f> | 2006-02-24 13:07:10 +0000 |
commit | c5130183e05c6dcb274b6341a05f496acf64aa1f (patch) | |
tree | 9076ac46b28633a403513dec8943db2f955d2008 | |
parent | 78a25bb299daa004f0be1a906b2b63e3bbeaa17b (diff) | |
download | lcd4linux-c5130183e05c6dcb274b6341a05f496acf64aa1f.tar.gz |
[lcd4linux @ 2006-02-24 13:07:10 by geronet]
hollow bars for graphic lcd's
git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@646 3ae390bd-cb1e-0410-b409-cd5a39f66f1f
-rw-r--r-- | drv_generic_graphic.c | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/drv_generic_graphic.c b/drv_generic_graphic.c index 1836a34..8609bef 100644 --- a/drv_generic_graphic.c +++ b/drv_generic_graphic.c @@ -23,6 +23,9 @@ * * * $Log: drv_generic_graphic.c,v $ + * Revision 1.22 2006/02/24 13:07:10 geronet + * hollow bars for graphic lcd's + * * Revision 1.21 2006/02/19 07:20:53 reinelt * image support nearly finished * @@ -437,11 +440,13 @@ int drv_generic_graphic_bar_draw(WIDGET * W) int layer, row, col, len, res, rev, max, val1, val2; int x, y; DIRECTION dir; + STYLE style; layer = W->layer; row = YRES * W->row; col = XRES * W->col; dir = Bar->direction; + style = Bar->style; len = Bar->length; fg = W->fg_valid ? W->fg_color : FG_COL; @@ -491,6 +496,15 @@ int drv_generic_graphic_bar_draw(WIDGET * W) drv_generic_graphic_FB[layer][(row + y) * LCOLS + col + x] = rev ? bg : fg; else drv_generic_graphic_FB[layer][(row + y) * LCOLS + col + x] = rev ? fg : bg; + + if (style) { + drv_generic_graphic_FB[layer][(row) * LCOLS + col + x] = fg; + drv_generic_graphic_FB[layer][(row + YRES - 1) * LCOLS + col + x] = fg; + } + } + if (style) { + drv_generic_graphic_FB[layer][(row + y) * LCOLS + col] = fg; + drv_generic_graphic_FB[layer][(row + y) * LCOLS + col + max - 1] = fg; } } break; @@ -565,7 +579,7 @@ int drv_generic_graphic_image_draw(WIDGET * W) } } } - + /* flush area */ drv_generic_graphic_blit(row, col, height, width); |