1*80c94c32Suwe.\" $NetBSD: wsfontload.8,v 1.32 2022/06/08 22:38:29 uwe Exp $ 22b294580Sdrochner.\" 32b294580Sdrochner.\" Copyright (c) 1999, 2001 42b294580Sdrochner.\" Matthias Drochner. All rights reserved. 52b294580Sdrochner.\" 62b294580Sdrochner.\" Redistribution and use in source and binary forms, with or without 72b294580Sdrochner.\" modification, are permitted provided that the following conditions 82b294580Sdrochner.\" are met: 92b294580Sdrochner.\" 1. Redistributions of source code must retain the above copyright 102b294580Sdrochner.\" notice, this list of conditions and the following disclaimer. 112b294580Sdrochner.\" 2. Redistributions in binary form must reproduce the above copyright 122b294580Sdrochner.\" notice, this list of conditions and the following disclaimer in the 132b294580Sdrochner.\" documentation and/or other materials provided with the distribution. 142b294580Sdrochner.\" 152b294580Sdrochner.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 162b294580Sdrochner.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 172b294580Sdrochner.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 182b294580Sdrochner.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 192b294580Sdrochner.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 202b294580Sdrochner.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 212b294580Sdrochner.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 222b294580Sdrochner.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 232b294580Sdrochner.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 242b294580Sdrochner.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 252b294580Sdrochner.\" SUCH DAMAGE. 26536eedccSdrochner.\" 27*80c94c32Suwe.Dd June 9, 2022 28536eedccSdrochner.Dt WSFONTLOAD 8 29997634feSjoerg.Os 30536eedccSdrochner.Sh NAME 31536eedccSdrochner.Nm wsfontload 32574575c5Swiz.Nd "load a font bitmap into the wsfont pool or a wscons display device" 33536eedccSdrochner.Sh SYNOPSIS 34990562bfSwiz.Nm 357bdc4b94Swiz.Op Fl Bbv 36d77575d3Smycroft.Op Fl e Ar encoding 377bdc4b94Swiz.Op Fl f Ar wsdev 387bdc4b94Swiz.Op Fl h Ar height 39d77575d3Smycroft.Op Fl N Ar name 407bdc4b94Swiz.Op Fl w Ar width 41536eedccSdrochner.Op Ar fontfile 42*80c94c32Suwe.Nm 43*80c94c32Suwe.Fl l 44536eedccSdrochner.Sh DESCRIPTION 45536eedccSdrochnerThe 46536eedccSdrochner.Nm 47371be6adSdrochnerutility loads a font bitmap into the wsfont font pool 48371be6adSdrochner(or a wscons device if the device driver supports this). 49536eedccSdrochnerThe font gets assigned a name in this process which it can be referred to 50536eedccSdrochnerby later for use on a display screen. 51536eedccSdrochnerThe font is loaded from the specified 52536eedccSdrochner.Ar fontfile , 538c073449Sbjh21or from standard input if 54536eedccSdrochner.Ar fontfile 55536eedccSdrochneris not provided. 56536eedccSdrochner.Pp 57536eedccSdrochnerThe options are: 58*80c94c32Suwe.Bl -tag -width Fl 597bdc4b94Swiz.It Fl B 607bdc4b94SwizSpecifies that the font data is ordered right-to-left byte wise. 617bdc4b94SwizThe default is left-to-right. 627bdc4b94Swiz.It Fl b 637bdc4b94SwizSpecifies that the font data is ordered right-to-left bit wise. 647bdc4b94SwizThe default is left-to-right. 65536eedccSdrochner.It Fl e Ar encoding 66662e5768SgmcgarrySets the encoding of the font. 67*80c94c32SuweThis can be either a symbolic name or a numeric value. 68*80c94c32SuweCurrently recognized names are: 69*80c94c32Suwe.Bl -tag -width Ql 70e4daf4deSdrochner.It Ql iso 71e4daf4deSdrochnerISO-8859-1 encoding 72e4daf4deSdrochner.It Ql ibm 73*80c94c32SuweIBM CP437 encoding 74e4daf4deSdrochner.It Ql pcvt 75e4daf4deSdrochnerthe custom encoding of the supplemental fonts which came with the 76ea46e54fSbjh21.Bx 77536eedccSdrochner.Dq pcvt 78e4daf4deSdrochnerconsole driver 79e4daf4deSdrochner.It Ql iso2 80*80c94c32SuweISO-8859-2 (Eastern European) encoding 81e4daf4deSdrochner.It Ql iso7 82*80c94c32SuweISO-8859-7 (Greek) encoding 83e4daf4deSdrochner.It Ql koi8r 84*80c94c32SuweKOI8-R (Russian) encoding 85e4daf4deSdrochner.El 86*80c94c32Suwe.Pp 87662e5768SgmcgarryPer default, 88ea46e54fSbjh21.Ql iso 89536eedccSdrochneris assumed. 907bdc4b94Swiz.It Fl f Ar wsdev 917bdc4b94SwizSpecify the device to operate on. 927bdc4b94SwizDefault is 937bdc4b94Swiz.Pa /dev/wsfont . 947bdc4b94Swiz.It Fl h Ar height 957bdc4b94SwizSets the height of a font character in pixels. 967bdc4b94SwizDefault is 16. 97ba26bce6Swiz.It Fl l 9807202a29SniaPrint a list of fonts that have been loaded or are built-in to the kernel. 99536eedccSdrochner.It Fl N Ar name 100536eedccSdrochnerSpecifies a name which can be used later to refer to the font. 1016533347dSdsaintyIf none is given, the 102536eedccSdrochner.Ar fontfile 103536eedccSdrochnername is used to create one. 1046c1d54c4Shubertf.It Fl v 1056c1d54c4ShubertfPrints the font's properties before loading it. 1067bdc4b94Swiz.It Fl w Ar width 1077bdc4b94SwizSets the width of a font character in pixels. 1087bdc4b94SwizDefault is 8. 109536eedccSdrochner.El 110719a8b0dSdrochner.Pp 111*80c94c32Suwe.Nm 112*80c94c32Suwesupports 113*80c94c32Suwe.Ql \&.wsf 114*80c94c32Suwefile format that contains the necessary information about the font in 115*80c94c32Suwethe font file itself. 116*80c94c32SuweSuch files can be loaded without specifying any arguments, 117*80c94c32Suwethough 118*80c94c32Suwe.Fl N 119*80c94c32Suwecan be used to override the font name. 120*80c94c32Suwe.Pp 121719a8b0dSdrochnerTypically, the 122719a8b0dSdrochner.Nm 123*80c94c32Suweutility will be executed during system startup by the 124*80c94c32Suwe.Xr rc 8 125*80c94c32Suwescript. 126*80c94c32SuweSee 127*80c94c32Suwe.Xr wscons.conf 5 . 128ea73e839Swiz.Sh FILES 129*80c94c32Suwe.Bl -item -compact 130*80c94c32Suwe.It 131ea73e839Swiz.Pa /usr/share/wscons/fonts 132*80c94c32Suwe.El 133719a8b0dSdrochner.Sh EXAMPLES 134*80c94c32SuweLoad ISO-encoded 20-pixel high Terminus font 135*80c94c32Suweand use it on the current console 136da49546bSnia.Pp 137*80c94c32Suwe.Bd -literal -offset indent 138*80c94c32Suwe# wsfontload /usr/share/wscons/fonts/ter-120n.wsf 139*80c94c32Suwe# wsfontload -l | grep Terminus 140*80c94c32SuweTerminus20-ISO8859-1 10x20 141*80c94c32Suwe# wsconsctl -f `tty` -dw font=Terminus20-ISO8859-1 142*80c94c32Suwe.Ed 143*80c94c32Suwe.Pp 144*80c94c32SuweLoad the ISO-encoded 16\[tmu]32 Spleen font 145*80c94c32Suweand switch the first console screen to use it: 146*80c94c32Suwe.Pp 147*80c94c32Suwe.Bd -literal -offset indent 148*80c94c32Suwe# wsfontload -w 16 -h 32 -e iso -N spleen32 \e 149da49546bSnia /usr/share/wscons/fonts/spleen-16x32.fnt 150da49546bSnia# wsconsctl -dw font=spleen32 151da49546bSnia.Ed 152719a8b0dSdrochner.Pp 153*80c94c32SuweLoad the IBM-encoded 8\[tmu]8-font from the 1543204ca28Swiz.Xr wscons 4 155da49546bSniadistribution: 156da49546bSnia.Pp 157*80c94c32Suwe.Bd -literal -offset indent 158*80c94c32Suwe# wsfontload -N myname -h 8 -e ibm \e 159*80c94c32Suwe /usr/share/wscons/fonts/vt220l.808 160da49546bSnia.Ed 161da49546bSnia.Pp 162*80c94c32SuweThis or another 8\[tmu]8-font is necessary to use the 163719a8b0dSdrochner50-line screen type on 164719a8b0dSdrochner.Xr vga 4 165719a8b0dSdrochnerdisplays. 166b2275072Scgd.Sh SEE ALSO 16774345454Saugustss.Xr wscons 4 , 168*80c94c32Suwe.Xr wsfont 4 , 169*80c94c32Suwe.Xr wscons.conf 5 , 170*80c94c32Suwe.\" XXX: BUGS: not yet 171*80c94c32Suwe.\" .Xr wsf 5 , 17274345454Saugustss.Xr wsconsctl 8 173*80c94c32Suwe.Sh HISTORY 174*80c94c32SuweSupport for 175*80c94c32Suwe.Ql \&.wsf 176*80c94c32Suwefont files appeared in 177*80c94c32Suwe.Nx 10.0 . 1788c073449Sbjh21.Sh BUGS 1798c073449Sbjh21Many features are missing. 1808c073449Sbjh21.Pp 181*80c94c32SuweThe 182*80c94c32Suwe.Ql \&.wsf 183*80c94c32Suwefile format is undocumented. 184*80c94c32Suwe.Pp 1858c073449Sbjh21There is no way to remove a loaded font. 186