[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Re: XyShell Clipboard and conversion of ANSI characters



** Reply to message from fenda@xxxxxxxx on Sat, 24 Aug 2002 09:09:14 +0200

Manuel:

> why I get the right characters in XyWrite if I use the standard
> Windows clipboard?

Window on Desktop:
I don't know -- that doesn't work here, under Win2K. Look, there are different
defaults for different national and regional editions of Windows; North
America, Western Europe, Russia, Japan etc are all different, I think. In
fact, from what I know, the Windows default (at least in N.America) is that the
DOS console font (the font used to display a DOS program in a Desktop window,
also known as OEM) must be Ascii 437, not ANSI (ANSI itself is a
variously-defined term, we should really be talking about ISO char sets, and
the ISO 8859 set is, I believe, what is true ANSI, whereas "Windows ANSI" is a
nonconforming bastard that breaks the rules, e.g. in the area <32 -- M$ refers
to this creature as CodePage1252 or Latin-1). In Spain the Windows DOS box
default is probably 850, and 1252 in windowed GUI apps. They do this because
the broadest universe of professional applications, e.g. ftp, doesn't
understand ANSI (moreover many such apps are restricted to 7-bit chars).

But, Manuel, you can change that behavior simply by CHanging the Code Page:
open an empty DOS box, go to Properties and set Font to Lucida Console, command
CHCP 1252 at DOS, and then launch EDITOR -- you're gonna see your
bloody ANSI characters and diacritics, including A acute, the whole ball of wax
(you could set up a BAT file to perform these steps in sequence, or actually
you can probably just shell to DOS -- DOS/NV in XyWrite -- and issue the
CHCP 1252 command). Your problem would be solved, at least in a window (DOS
box) displayed on the Desktop. Only thing I'm unsure about is whether the CHCP
command exists in Win98 -- does it? After all, Win98 is just a pocket
calculator -- you need a real OpSys. But if CHCP works, this is your easiest
option. I seem to remember some MODE CON CODEPAGE command that needed to be
used to set up the video before calling CHCP -- but everything may be different
in the Spanish version, I just don't know, and I hardly ever played with Win98,
so...

Full screen:
I once wrote my own bitmapped Full screen font, consisting neither of Ascii nor
ANSI but of the "Holmgren character set" (trademarked and copyrighted, of
course, me me me my my my property! an absolutely disgusting discussion thread,
that one) -- this font enabled all the diacritical chars (many) required to
transliterate Sanskrit and Old Javanese using Roman chars, plus it had special
chars such as a compass rose. It worked great under OS/2 (XyWrite) and Linux,
but Windows would never swallow it. Last time I investigated (several years
ago), I reached the conclusion that Windows didn't want to allow me to replace
the Full screen font, period.

But: it ain't true. Check this guy out:
 http://www.chebucto.ns.ca/~af380/Tips.html#Tip019
Here's what you want to do:
DL this: http://www.chebucto.ns.ca/~af380/cp1252.zip
DL this: ftp://ftp.bu.edu/pub/mirrors/simtelnet/msdos/vga/fpman220.zip
Now, UnZIP both those files into the same temporary directory. Open a *Full
screen* DOS session. Navigate to the temporary directory. Command:
 vga FONT cp1252.fnt
Navigate to your XyWrite4-DOS directory, and command:
 EDITOR.EXE
Voilà: you've got a Full Screen 80x25 session displaying ANSI, with the Euro
sign and everything. Pretty good looking, too. If you want more lines than 25
(why bother?), I suppose you could roll your own font with FONTMAN, in the same
package. Unfortunately, this font doesn't work in a DOS box on the Desktop.
For that, well, I'm not sure -- in fact, I'm not sure about most of this,
because I am running W2K.

Another option: XyWin and NBWin enable TrueType fonts for both display and
printing, which ought to allow you to use ANSI fonts. But then you're stuck
with XyWin or NBWin -- happy landings.

Let me know if any of this works for you. Curious about Win98 quirks.

-----------------------------
Robert Holmgren
holmgren@xxxxxxxx
-----------------------------