fill->base.fill_with_color = fill_hatch;
fill->base.fill_with_fcolor = fill_hatchf;
fill->base.destroy = NULL;
- fill->fg = fg ? *fg : fcolor_to_color(ffg);
- fill->bg = bg ? *bg : fcolor_to_color(fbg);
- fill->ffg = ffg ? *ffg : color_to_fcolor(fg);
- fill->fbg = fbg ? *fbg : color_to_fcolor(bg);
+ /* Some Sun C didn't like the condition expressions that were here.
+ See https://rt.cpan.org/Ticket/Display.html?id=21944
+ */
+ if (fg)
+ fill->fg = *fg;
+ else
+ fill->fg = fcolor_to_color(ffg);
+ if (bg)
+ fill->bg = *bg;
+ else
+ fill->bg = fcolor_to_color(fbg);
+ if (ffg)
+ fill->ffg = *ffg;
+ else
+ fill->ffg = color_to_fcolor(fg);
+ if (fbg)
+ fill->fbg = *fbg;
+ else
+ fill->fbg = color_to_fcolor(bg);
if (combine) {
i_get_combine(combine, &fill->base.combine, &fill->base.combinef);
}
int mask = 128 >> xpos;
while (width-- > 0) {
- *data++ = (byte & mask) ? f->fg : f->bg;
+ if (byte & mask)
+ *data++ = f->fg;
+ else
+ *data++ = f->bg;
if ((mask >>= 1) == 0)
mask = 128;
int mask = 128 >> xpos;
while (width-- > 0) {
- *data++ = (byte & mask) ? f->ffg : f->fbg;
+ if (byte & mask)
+ *data++ = f->ffg;
+ else
+ *data++ = f->fbg;
if ((mask >>= 1) == 0)
mask = 128;