diff --git a/usr.sbin/kbdmap/kbdmap.1 b/usr.sbin/kbdmap/kbdmap.1 index dbc2a5a646e6..af193f423802 100644 --- a/usr.sbin/kbdmap/kbdmap.1 +++ b/usr.sbin/kbdmap/kbdmap.1 @@ -34,7 +34,7 @@ .\" .\" E-Mail: Wolfram Schneider .\" -.\" $Id: kbdmap.1,v 1.2 1996/01/30 13:49:17 mpp Exp $ +.\" $Id: kbdmap.1,v 1.3 1996/02/11 22:33:15 mpp Exp $ .\" .Dd Mar 25, 1995 @@ -47,9 +47,12 @@ .Sh SYNOPSIS .Nm kbdmap +.Op Fl K +.Op Fl V .Op Fl d | Fl default .Op Fl h | Fl help .Op Fl l | Fl lang Ar language +.Op Fl p | Fl print .Op Fl r | Fl restore .Op Fl s | Fl show .Op Fl v | Fl verbose @@ -62,8 +65,19 @@ do it for fonts. Both looking in a database for a description. Description is in English (default) or any other language. +It is strongly recommended to not choose MSDOS codepage keymaps +or fonts. Use the ISO standard if available! X11 does not +support MSDOS codepage. + .Sh OPTIONS .Bl -tag -width Ds +.It Fl K +Run as command +.Xr kbdmap 1 . + +.It Fl V +Run as command +.Xr vidfont 1 . .It Fl d , Fl default Use default language. Ignore $LANG. @@ -76,12 +90,16 @@ Use .Ar language for description and menu -.It Fl s , Fl show -Show currently supported languages and exit. +.It Fl p , Fl print +Print description of available keymaps or fonts +to stdout and exit. .It Fl r , Fl restore Load default font from /etc/sysconfig +.It Fl s , Fl show +Show currently supported languages and exit. + .It Fl v , Fl verbose More warnings. diff --git a/usr.sbin/kbdmap/kbdmap.pl b/usr.sbin/kbdmap/kbdmap.pl index 8736d610d27c..35cefab17e85 100644 --- a/usr.sbin/kbdmap/kbdmap.pl +++ b/usr.sbin/kbdmap/kbdmap.pl @@ -35,7 +35,7 @@ # # E-Mail: Wolfram Schneider # -# $Id: kbdmap.pl,v 1.10 1995/04/03 21:13:52 w Exp $ +# $Id: kbdmap.pl,v 1.2 1995/04/05 08:09:24 jkh Exp $ # # simple test if syscons works @@ -45,10 +45,6 @@ if ($x11) { "expect certain strange side-effects\n"; sleep 2; } - -#die "You are on a virtual console?\n" . -# "This program does not work with X11\n" if $?; - sub variables_static { $lang_default = "en"; # set default language @@ -59,9 +55,9 @@ sub variables_static { $fontdir = "/usr/share/syscons/fonts"; $sysconfig = "/etc/sysconfig"; - #$keymapdir = "./syscons/keymaps"; - #$fontdir = "./syscons/fonts"; - #$sysconfig = "./sysconfig"; + # for test only + #$keymapdir = "/tmp/kbdmap/syscons/keymaps"; + #$fontdir = "/tmp/kbdmap/syscons/fonts"; # read current font from sysconfig $font_default = "cp437-8x16.fnt"; @@ -229,6 +225,15 @@ sub menu_read { grep(s/8x8/8x08/, @a); @a = sort @a; grep(s/8x08/8x8/, @a); + + if ($print) { + foreach (@a) { + s/"//g; #" + print "$_\n"; + } + exit; + } + return @a; } @@ -289,8 +294,8 @@ sub dialog { sub usage { warn <