>>M$ has solved this nice in Office 97, but then it uses Unicode anyime it lik
es
>, and VFP doesn't. Maybe we could use some API to do it?
>
>Dragan, have you studied the structure of a windows font file?
>It would be possible to make copy of this file, change
>name e.q. Arial to some other and
>move some othger scipt to English codepage place.
>Then you can select it from foxpro.
>It seems to be only solution. Do you know, is
>the structure of font file available somewhere?
>Or are such fonts available?
There are fonts from Win 3.11 CE - they had 1250 versions of some
Arial, Courier and Times New Roman. Funny, they didn't have
cyrillic, but Hungarian Win3.11 had it (?).
Extracting such fonts from current multipage fonts seems to be a
step back to me - single codepage fonts existed in 3.11, and are
abandoned with the advent of W95. OTOH, many of the apps available
know how to extract desired codepage from a multipage font. I think
there must be some API call which does that, and I'll write this
into my to-do list (with a pretty low priority, though, because if
VFP6 will be Unicode, then why bother).
Besides, carrying fonts around is not what I find fit for a W95 app
- most of the apps function without introducing their own fonts,
right?
Anyway, I've succeeded in one thing: I run
regedit \w95\cp1250.reg
from my autoexec.bat, and there's an option to run cp1251 instead.
I've tried the conditional #defines in form's init I've described
yesterday, and voila! it works - my labels show in cyrillic after
recompile, and in latinic again after another boot and recompile,
and so does the status bar. What doesn't work is form's caption -
there's simply no way to tell W95 to use any particular codepage for
this, and it obviously doesn't use system's codepage. Here's the
cp1251.reg, if you want to try:
REGEDIT4
[HKEY_LOCAL_MACHINE\System\CurrentControlSet\control\Nls\Codepage]
"1250"="cp_1250.nls"
"1251"="cp_1251.nls"
"1252"="cp_1252.nls"
"1253"=""
"1254"=""
"1255"=""
"1256"=""
"1257"=""
"1361"=""
"437"="cp_437.nls"
"737"=""
"775"=""
"850"="cp_850.nls"
"852"="cp_852.nls"
"857"=""
"855"=""
"862"=""
"864"=""
"866"=""
"869"=""
"874"=""
"932"=""
"936"=""
"949"=""
"950"=""
"20866"="cp_20866.nls"
"28592"="cp_28592.nls"
"28593"="cp_28593.nls"
"28594"="cp_28594.nls"
"28597"="cp_28597.nls"
"ACP"="1251"
"OEMCP"="850"
Just prior to booting with such a .reg file, make sure you have all
the .nls files really installed - once I was missing the cp_852.nls,
and the machine hung up in a most misterious way, leaving desktop
designed by Picasso.