// redraw one or more characters
// seek to the beginning of wide characters
- while (stp[col] == NOCHAR && col > 0)
+ while (expect_false (stp[col] == NOCHAR && col > 0))
--col;
rend_t rend = srp[col]; /* screen rendition (target rendtion) */
count -= i; /* dump any matching trailing chars */
// sometimes we optimize away the trailing NOCHAR's, add them back
- while (i && text[count] == NOCHAR)
+ while (expect_false (i && text[count] == NOCHAR))
count++, i--;
/*
int back = bgcolor_of (rend); // desired background
// only do special processing if any attributes are set, which is unlikely
- if (rend & (RS_Bold | RS_Italic | RS_Uline | RS_RVid | RS_Blink | RS_Careful))
+ if (expect_false (rend & (RS_Bold | RS_Italic | RS_Uline | RS_RVid | RS_Blink | RS_Careful)))
{
bool invert = rend & RS_RVid;
*/
rxvt_font *font = (*fontset[GET_STYLE (rend)])[GET_FONT (rend)];
- if (have_bg && back == Color_bg)
+ if (expect_true (have_bg && back == Color_bg))
{
// this is very ugly, maybe push it into ->draw?
else
font->draw (*drawable, xpixel, ypixel, text, count, fore, back);
- if (rend & RS_Uline && font->descent > 1 && fore != back)
+ if (expect_false (rend & RS_Uline && font->descent > 1 && fore != back))
{
#if ENABLE_FRILLS
if (ISSET_PIXCOLOR (Color_underline))