Subject: Re: terminal does not reverse, highlight text
To: Michael Lorenz <macallan@netbsd.org>
From: leon zadorin <leonleon77@gmail.com>
List: port-macppc
Date: 02/10/2007 12:09:42
On 2/8/07, Michael Lorenz <macallan@netbsd.org> wrote:
> There was no radeonfb in 3.x, I'm sure you noticed the speed difference
> :)

ah - yes indeed, the speedup is rather amazing :-)

> cvs update dev/pci/radeonfb.c at some point tomorrow ;)

in the meantime, i had a cursive look into the aforementioned file and
somethin similar to the following patch works for me
(the only thing is, i am not sure how it will deal with underline
attributes if such exist?):

2286a2287
> 	int const reverse_display = attr >> 8 & WSATTR_REVERSE;
2297,2298c2298,2299
< 	bg = ri->ri_devcmap[(attr >> 16) & 0xf];
< 	fg = ri->ri_devcmap[(attr >> 24) & 0xf];
---
> 	bg = ri->ri_devcmap[attr >> (reverse_display ? 24 : 16) & 0xf];
> 	fg = ri->ri_devcmap[attr >> (reverse_display ? 16 : 24) & 0xf];

(it is in the "radeonfb_putchar" call, and the attr seems to be passed
and set (for screen reversal) in radeonfb_allocattr call)...