[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Polish language with openBSD



Mats O Jansson <maja_(_at_)_cntw_(_dot_)_com>:

> On Sun, 7 Jul 2002, Marcin Cylke wrote:
>
>> Hello
>
> Hi!
>
>> I've installed recently openBSD 3.1 
>> I am in great need of adjsting console to display polish fonts. I also
>> don't know how should I set the keyboard for the polish one.
>
> Since you fail to tell us which platform you use i'll assume i386.
>
> There isn't a keyboard map for Polish yet. But I can help you with that.
> It seems like Poland is using ISO 8859-2 as font, is that correct? There is
> no 8859-2 font for console in OpenBSD. But I think most of the characters
> exists so it shouldn't be hard to fix the font. I could help with that
> too.
>
> Microsoft seems to support two different keyboard maps (see
> http://www.microsoft.com/globaldev/keyboards/keyboards.asp). One they call
> Polish (214) and the other is called Polish (Programmers), which do you
> want?
The patches below create support for the Polish Programmers keyboard layout.
I've got a font with ISO 8859-2 downloaded from *somewhere* (no clue
about it's license) and can provide it on request. I've been using that
for quite some time now, without any trouble.

Those patches are based on work for NetBSD by Dawid Szymanski.

Regards,
Kamil Andrusz
-- 
It's just a matter of opinion.

--- sys/dev/ic/vga.c.orig       Mon Jul  8 12:50:50 2002
+++ sys/dev/ic/vga.c    Tue Jul  2 22:54:02 2002
@@ -64,7 +64,7 @@
 } vga_builtinfont = {
        "builtin",
        16,
-       WSDISPLAY_FONTENC_IBM,
+       WSDISPLAY_FONTENC_ISO,
 #ifdef notyet
        0, 256,
 #endif
@@ -855,7 +855,7 @@
 
        if (data->index < 0) {
                for (slot = 0; slot < 8; slot++)
-                       if (!vc->vc_fonts[slot])
+                       if (!vc->vc_fonts[slot] ||
                vc->vc_fonts[slot]->height == data->fontheight)
                                break;
        } else
                slot = data->index;
--- sys/dev/pckbc/wskbdmap_mfii.c.orig  Mon Jul  8 12:50:56 2002
+++ sys/dev/pckbc/wskbdmap_mfii.c       Tue Jul  2 21:38:56 2002
@@ -744,6 +744,20 @@
     KC(115), KS_slash,         KS_question,    KS_degree,
 };
 
+static const keysym_t pckbd_keydesc_pl[] = {
+/*  pos      normal             shifted         altgr
+shift-altgr */
+    KC(18),  KS_e,             KS_E,           KS_ecircumflex,
+KS_Ecircumflex,
+    KC(24),  KS_o,             KS_O,           KS_oacute,
+KS_Oacute,
+    KC(30),  KS_a,             KS_A,           KS_plusminus,
+KS_exclamdown,
+    KC(31),  KS_s,             KS_S,           KS_paragraph,
+KS_brokenbar,
+    KC(38),  KS_l,             KS_L,           KS_threesuperior,
+KS_sterling,
+    KC(44),  KS_z,             KS_Z,           KS_questiondown,
+KS_macron,
+    KC(45),  KS_x,             KS_X,           KS_onequarter,
+KS_notsign,
+    KC(46),  KS_c,             KS_C,           KS_ae,          KS_AE,
+    KC(49),  KS_n,             KS_N,           KS_ntilde,
+KS_Ntilde,
+    KC(184), KS_Mode_switch,   KS_Multi_key,
+};
+
 #define KBD_MAP(name, base, map) \
                        { name, base, sizeof(map)/sizeof(keysym_t), map
                        }
 
@@ -784,6 +798,7 @@
        KBD_MAP(KB_LT,                  KB_US,  pckbd_keydesc_lt),
        KBD_MAP(KB_LA,                  KB_US,  pckbd_keydesc_la),
        KBD_MAP(KB_BR,                  KB_US,  pckbd_keydesc_br),
+       KBD_MAP(KB_PL,                  KB_US,  pckbd_keydesc_pl),
        {0, 0, 0, 0}
 };
--- sys/dev/wscons/wsksymdef.h.orig     Mon Jul  8 12:51:00 2002
+++ sys/dev/wscons/wsksymdef.h  Mon Jul  8 12:49:16 2002
@@ -642,6 +642,7 @@
 #define KB_LT                  0x1300
 #define KB_LA                  0x1400
 #define KB_BR                  0x1500
+#define        KB_PL                   0x1600
 
 #define KB_NODEAD              0x0001
 #define KB_DECLK               0x0002  /* DEC LKnnn layout */
@@ -673,7 +674,8 @@
        { KB_PT,        "pt" }, \
        { KB_LT,        "lt" }, \
        { KB_LA,        "la" }, \
-       { KB_BR,        "br" }
+       { KB_BR,        "br" }, \
+       { KB_PL,        "pl" }
 
 #define KB_VARTAB \
        { KB_NODEAD,    "nodead" }, \



Visit your host, monkey.org