Difference between revisions of "OSBYTE &47"

From BeebWiki
Jump to: navigation, search
(Alphabet numbers)
Line 54: Line 54:
  
 
===Alphabet numbers===
 
===Alphabet numbers===
  100 BFont       105 Cyrillic    110 Welsh        115 Latin8
+
100 BFont         105 Cyrillic    110 Welsh        115 Latin8
  101 Latin1       106 Arabic      111 UTF8        116 Latin10
+
101 Latin1       106 Arabic      111 UTF8        116 Latin10
  102 Latin2       107 Greek        112 Latin9   
+
102 Latin2       107 Greek        112 Latin9   
  103 Latin3       108 Hebrew      113 Latin6   
+
103 Latin3       108 Hebrew      113 Latin6   
  104 Latin4       109 Latin5      114 Latin7
+
104 Latin4       109 Latin5      114 Latin7
  
 
===Implementation===
 
===Implementation===

Revision as of 02:41, 29 December 2020

OSBYTE &47 (71) - Set alphabet or keyboard
On entry: X=&00+n - set or read alphabet (font)
          X=&80+n - set or read keyboard
                n=&00     : set to default
                n=&7F     : read current setting
                n=1-99    : Countries
                n=100-126 : Alphabets

On exit,  X=0   - specified alphabet/keyboard not supported
          X<&80 - previous alphabet/keyboard
          X>&7F - OSBYTE call not supported

While OSBYTE &46 sets both the keyboard and alphabet (font) in one action, this call allows each to be set individually.

Selecting an alphabet redefines the font with VDU 23 sequences. The alphabet can be specified with a country number 0-99, the appropriate alphabet for that country is then selected. Or the alphabet can be selected with the specific alphabet number 100-126. Selecting the default alphabet with X=&00 selects the appropriate alphabet for the currently selected country set with OSBYTE &46.

The keyboard can only be selected by specifying a country number, selecting a keyboard with an alphabet makes no sense. Selecting the default keyboard with X=&80 selects the appropriate keyboard for the currently selected country set with OSBYTE &46.

On 8-bit systems the keyboard number is stored in the OSBYTE &AD variable, on 32-bit systems it is stored in a non-OSBYTE variable.

  • *COUNTRY parses the parameter and calls OSBYTE &46,n
  • *ALPHABET parses the parameter and calls OSBYTE &47,&00+n
  • *KEYBOARD parses the parameter and calls OSBYTE &47,&80+n

Country numbers

  1 UK             11 Sweden        21 Arabic        31 Belgium
  2 Master or BBC  12 Finland       22 Ireland       32 Japan
  3 Compact        13 Unused        23 HongKong      33 MiddleEast
  4 Italy          14 Denmark       24 Russia1       34 Netherlands
  5 Spain          15 Norway        25 Russia2       35 Switzerland
  6 France         16 Iceland       26 Israel        36 Wales
  7 Germany        17 Canada1       27 Mexico        37 Maori
  8 Portugal       18 Canada2       28 LatinAm
  9 Esperanto      19 Canada        29 Australia
 10 Greece         20 Turkey        30 Austria
 
 48 USA            50 China         52 SAfrica       54 Taiwan
 49 Wales2         51 Brazil        53 Korea
 
 When selecting a keyboard:
125 A4 internal or PC keyboard
126 Archimedes keyboard

Alphabet numbers

100 BFont         105 Cyrillic     110 Welsh        115 Latin8
101 Latin1        106 Arabic       111 UTF8         116 Latin10
102 Latin2        107 Greek        112 Latin9  
103 Latin3        108 Hebrew       113 Latin6  
104 Latin4        109 Latin5       114 Latin7

Implementation

Implemented in the Master Internationalisation ROM, RISC OS kernel and keyboard handlers, and 8-bit keyboard extensions.

See Also

WikiSysop (talk) 13:32, 8 March 2015 (UTC) Jgharston (talk) 23:32, 18 October 2020 (CEST)