Mail Archives: djgpp/1998/12/09/09:02:18
Eli Zaretskii <eliz AT is DOT elta DOT co DOT il> wrote:
> On Tue, 8 Dec 1998, Robert Hoehne wrote:
>
> > The problem here is, that RHIDE uses internally hardcoded the
> > IBM (or PC??) character set for some special characters (like
> > the frame chars). This problem may occour also on DOS, but very
> > seldom, since there is in most cases the font installed, which
> > RHIDE expects.
> >
> > Mayve I will find someday the time to learn a little bit more
> > about all that stuff so I can fix it (or someone else sends me
> > a patch for it :-)
>
> One possible solution is to have an extra level of indirection between
> the characters written by the display code and the actual bytes that
> are sent to the screen. Create a 256-element table, where the X-th
> element holds the byte to be sent to the screen when the display code
> wants to display a character whose 8-bit code is X.
>
> You can initialize the table with "table[X] = X", and then change the
> mapping if the underlying codepage/display system doesn't support
> certain characters, such as IBM box-drawing characters.
Thanks but that's too slow. I managed to do it without needed to slow
down the library. Currently the classes have 2 versions of the strings with
special characters. One is the original (CP437) string and the other is the
currently used copy. When the user choose another code page I translate the
original string and put it in the currently used copy.
> The GNU `recode' program has one example of emulating box-drawing
> characters with ASCII characters.
I already did it for some russian code pages that completly lacks graphic
characters, but I'm sure I can enhance it looking at this example, thanks.
SET
------------------------------------ 0 --------------------------------
Visit my home page: http://set-soft.home.ml.org/
or
http://www.geocities.com/SiliconValley/Vista/6552/
Salvador Eduardo Tropea (SET). (Electronics Engineer)
Alternative e-mail: set-soft AT usa DOT net set AT computer DOT org
ICQ: 2951574
Address: Curapaligue 2124, Caseros, 3 de Febrero
Buenos Aires, (1678), ARGENTINA
TE: +(541) 759 0013
- Raw text -