ATTENTION: A perfect solution for Win95/98/Me would be using KOI8-R<->CP1251 translation tables at the system level or inside each Internet or HTML related program (even this solution have some disadvantages, but nothing more fancy can be done in Win95/98/Me at this moment). Until this is implemented (I guess, after some critical mass of decoding programs is reached), a temporary solution is available here.
It is commendable that some programs support KOI8-R<->CP1251 translation automatically, but:
- Such programs are relatively rare (for example, Mozilla 1.7.3 , Opera 12 , MS Internet Explorer and MS Outlook Express Mail/News do it), a lot of interesting Internet software is unaware about the necessary decoding.
- Emulating KOI8-R via CP1251 can't be complete because character repertoires are different. Properly done, this would require UNICODE intermediation.
As a matter of fact, we don't need KOI8-R fonts at all,
as .TTF fonts from Microsoft are always in
and we only need to make use of them.
The only thing to do is to add KOI8-R -> UNICODE translation
table as a resource to
This resource is a simple array with 256
entries of word size: index is the ANSI code of character,
value is the Unicode code.
its name is stored in the
corresponding string resource
Step-by-step instructions for creating the KOI8-R translation resource
Choose one of
already patched files:
Windows Me (Russian Edition):
Windows Me (Standard):
Win98 SE (Second Edition), American or PanEuropean:
Win98 SE (Second Edition), Russian:
Win98 Standard (American) or PanEuropean:
gdi.exesize must be 312,208 bytes)
gdi.exe, Zip (it works with OSR2 too)
gdi.exemust be 312,496 bytes)
gdi.exemust be 312,464 bytes)
gdi.exemust be 312,336 bytes)
- Windows Me (Russian Edition):
If your system's
gdi.exesize or type don't match any of the above, you need to patch your
gdi.exeyourself using instructions from step 5 onwards. If you've got a successful result, please send me your patched
gdi.exezipped copy and I'll add it to those listed above.
Reload Win95/98/Me in "command prompt only" (plain MS-DOS) mode,
backup your old
\Windows\System\gdi.exeand move the unpacked
gdi.exefrom temporary directory to
\Windows\System\(you can't just overwrite
gdi.exefrom inside Win95/98/Me because the file is in use or protected with PCHealth).
WARNING: for WinMe you need to boot from Startup Diskette to get the "command line" prompt!
- Reboot the system again in Win95/98/Me mode and jump to step 10.
Make a copy of your
\Windows\System\gdi.exeand open this copy in Visual C++ 4.0 or Borland Resource Workshop 4.5.
238 (Central European). Using this particular
IDallows KOI8-R fonts to appear as Central European fonts (font names with
CEsuffix will be later changed to
Font Name KOI8-R) for older programs such as
Microsoft Word 6.0.
- Overwrite this resource with the resource data below: RFC 1489)
Each Data ID has a corresponding string in the string table with
ID + 1000(for
1238). That's what is shown in programs' font selection boxes, usually under the title of Script for Win95/98/Me Standard Edition or Набор символов for Win95 Russian Edition. Change the string to
Russian (KOI8-R)for Win95/98/Me Standard Edition or to
Русский (KOI8-R)for Win95 Russian Edition. You can download Borland Resource Workshop data (Script name) for Win95/98/Me Standard Edition or Borland Resource Workshop data (Набор символов name) for Win95/98/Me Russian Edition and paste it into the
Save, backup your
\Windows\System\gdi.exe, restart the system in command prompt mode (this step is important), rename just saved copy to
\Windows\System\gdi.exeand reboot your PC back to Win95/98/Me.
[FontSubstitutes]section (or add one, if it's not present). Check all
CEsuffixes, this entries should look like:
Arial CE,238=Arial,238 Arial CE,0=Arial,238 Courier New CE,238=Courier New,238 Courier New CE,0=Courier New,238 Times New Roman CE,238=Times New Roman,238 Times New Roman CE,0=Times New Roman,238 Arial Black CE,238=Arial Black,238 Arial Black CE,0=Arial Black,238 Impact CE,238=Impact,238 Impact CE,0=Impact,238 Verdana CE,238=Verdana,238 Verdana CE,0=Verdana,238 Lucida Sans Unicode CE,238=Lucida Sans Unicode,238 Lucida Sans Unicode CE,0=Lucida Sans Unicode,238 Haettenschweiler CE,238=Haettenschweiler,238 Haettenschweiler CE,0=Haettenschweiler,238(not all of them may be present in your case).
This provides access to KOI8-R fonts for old (Win3) programs that are unaware about font Scripts. Now you should remember that the
CEsuffix in the font list points to a KOI8-R font. E.g., choosing
Times New Roman CEin WinWord will allow you to work with KOI8-R texts.
WARNING for programmers: don't change
CEsuffix to something more appropriate (such as
KOI8-R), some programs (e.g. WinWord) check if this suffix belongs to the list of known suffixes, so
CEmust remain in place as a provision for such (rare) cases.
- Save the file and reboot.
Now launch any program with a font selection box, you'll
Russian (KOI8-R)Script there, select it and enjoy.
- It's time now to set up the native Win95/98/Me keyboard driver for KOI8-R.
Great help on these matters was provided by Walter Kondrashov <Walt@gecko.crec.mipt.ru>, Alexander Smundak <firstname.lastname@example.org>, and Vadim Burtyansky <email@example.com>, thanks.