bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CDKEntry and CDK MEntry, Bugfix and optimization


From: Aarian P. Aleahmad
Subject: CDKEntry and CDK MEntry, Bugfix and optimization
Date: Thu, 18 Feb 2016 15:04:55 +0330
User-agent: Roundcube Webmail/0.7.2

Dear Thomas

There was a bug in CDKEntry which caused the "Hidden" fields, don't apply the attributes set. Also the attributes wouldn't apply to a place unless you would type a character in there. The former was fixed by adding a simple 'bitwise or'. The later was replaced by calling "wbkgd" function from ncurses. Also in case of hidden entry, the drawCDKEntryField function could be optimized by drawing a line made of "hidden" character instead of printing it character by character.

There was also a bug in Mentry which caused the hidden fields to print a "filler" character instead of "hidden". I fixed it. Also I applied the same wbkgd explained above. I also optimized it a little. When printing "info" finishes, the rest of the field is made by adding the "filler" character, one by one. I optimized it by drawing a horizontal line using "filler" character at once and "breaking" the inner for.

my verison of entry.c and mentry.c are attached.

entry.c:
lines 665,668, and 680

mentry.c:
lines 659, 670, 680-681

Regards,
Aarian

Attachment: entry.c
Description: Text Data

Attachment: mentry.c
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]