changeset 26560:09ad3b69711f

Fix drawing for vertical progressbar.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sun, 12 Apr 2009 21:28:59 +0000
parents 1c9bbfcc3687
children 0a5823a58279
files finch/libgnt/gntprogressbar.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/finch/libgnt/gntprogressbar.c	Sun Apr 12 21:11:00 2009 +0000
+++ b/finch/libgnt/gntprogressbar.c	Sun Apr 12 21:28:59 2009 +0000
@@ -92,17 +92,17 @@
 
 			/* background */
 			for (i = 0; i < widget->priv.width; i++)
-				mvwvline (widget->window, 0, i, ' ' | color | A_REVERSE, widget->priv.height);
+				mvwvline (widget->window, 0, i, ' ' | color, widget->priv.height);
 
 			/* foreground */
 			for (i = 0; i < widget->priv.width; i++)
-				mvwvline (widget->window, start, i, ' ' | color, end);
+				mvwvline (widget->window, start, i, ACS_CKBOARD | color | A_REVERSE, end);
 
 			/* text */
 			if (priv->show_value) {
 				pos = widget->priv.height / 2 - strlen (progress) / 2;
 				for (i = 0; i < progress[i]; i++, pos++) {
-					wattrset (widget->window, color | ((pos >= start && pos <= end) ? A_NORMAL : A_REVERSE));
+					wattrset (widget->window, color | ((pos < start || pos > end) ? A_NORMAL : A_REVERSE));
 					mvwprintw (widget->window, pos, widget->priv.width / 2, "%c\n", progress[i]);
 				}
 				wattrset (widget->window, color);