|
|
(4 intermediate revisions by 2 users not shown) |
Line 2: |
Line 2: |
|
| |
|
| == How to Set up an APL Keyboard == | | == How to Set up an APL Keyboard == |
|
| |
| === Text editors ===
| |
|
| |
| Keyboard layout extensions exist for several popular [[text editors]] like VS Code, Emacs and Vim. This can be an alternative, or complementary, to system-wide settings.
| |
|
| |
|
| [[File:Adám Brudzewsky's in-browser language bar.png|thumb|right|The in-browser language bar]] | | [[File:Adám Brudzewsky's in-browser language bar.png|thumb|right|The in-browser language bar]] |
Line 12: |
Line 8: |
| [[Adám Brudzewsky]]'s [https://abrudz.github.io/lb/apl in-browser language bar] adds APL keyboard functionality to most web pages on demand. | | [[Adám Brudzewsky]]'s [https://abrudz.github.io/lb/apl in-browser language bar] adds APL keyboard functionality to most web pages on demand. |
|
| |
|
| === Windows === | | === Text editors === |
| | |
| | Keyboard layout extensions exist for several popular [[text editors]] like VS Code, Emacs and Vim. This can be an alternative, or complementary, to system-wide settings. |
|
| |
|
| * [[Adám Brudzewsky]]'s [https://github.com/abrudz/Kbd keyboard layouts for Windows], which uses <kbd>AltGr</kbd>.
| | === Linux === |
| | {{Main|Typing glyphs on Linux}} |
|
| |
|
| * The [https://www.dyalog.com/apl-font-keyboard.htm#tab-1 Dyalog Unicode IME] uses <kbd>Ctrl</kbd>. It is also possible to install the [[wikipedia:Input_method|IME]] alongside a regular [[Dyalog APL]] installation:<br>[[File:Dyalog_APL_Installer.png|frameless|Dyalog APL IME selected in installer]]
| | Most Linux distributions released after mid-2012 have Dyalog keyboard support included with the distribution. |
|
| |
|
| [[File:Hacker's Keyboard + APL language.png|thumb|right|Hacker's Keyboard + APL language]] | | [[File:Hacker's Keyboard + APL language.png|thumb|right|Hacker's Keyboard + APL language]] |
Line 23: |
Line 22: |
| dzaima's [https://github.com/dzaima/hackerskeyboard Hacker's Keyboard + APL language] uses a [[wikipedia:Pointing_device_gesture#Touchpad_and_touchscreen_gestures|long-press]] to access APL glyphs. | | dzaima's [https://github.com/dzaima/hackerskeyboard Hacker's Keyboard + APL language] uses a [[wikipedia:Pointing_device_gesture#Touchpad_and_touchscreen_gestures|long-press]] to access APL glyphs. |
|
| |
|
| === Linux === | | === Windows === |
|
| |
|
| [[Geoff Streeter]] authored a paper, [https://www.dyalog.com/uploads/conference/dyalog10/presentations/P19_Streeter_Keyboards.pdf Supporting APL keyboards on Linux], which was presented at the [https://aplwiki.com/wiki/Dyalog_user_meeting#Dyalog_.2710 Dyalog '10] user meeting. In this paper, Geoff details how APL keyboards can be supported in [[wikipedia:X_Window_System|X11]] using <source lang=console inline>xkb</source>, the [https://www.x.org/wiki/XKB/ X Keyboard Extension]. | | * [[Adám Brudzewsky]]'s [https://github.com/abrudz/Kbd keyboard layouts for Windows], which uses <kbd>AltGr</kbd>. |
|
| |
|
| Most Linux distributions released after mid-2012 have [https://forums.dyalog.com/viewtopic.php?f=20&t=210 Dyalog keyboard support] included with the distribution.
| | * The [https://www.dyalog.com/apl-font-keyboard.htm#tab-1 Dyalog Unicode IME] uses <kbd>Ctrl</kbd>. It is also possible to install the [[wikipedia:Input_method|IME]] alongside a regular [[Dyalog APL]] installation:<br>[[File:Dyalog_APL_Installer.png|frameless|Dyalog APL IME selected in installer]] |
| | |
| ==== setxkbmap ====
| |
| | |
| The simplest way to set up an APL keyboard on Linux is with the following <source lang=console inline>setxkbmap</source> command. Enter the following in your terminal emulator of choice:
| |
| | |
| <source lang=console>
| |
| setxkbmap -layout us,apl -variant ,dyalog -option grp:switch
| |
| </source>
| |
| | |
| An explanation:
| |
| | |
| * <source lang=console inline>-layout us,apl</source> assigns <source lang=console inline>us</source> ([[wikipedia:American_English|U.S. English]]) to be the primary layout, whereas <source lang=console inline>apl</source> is secondary
| |
| | |
| * <source lang=console inline>-option grp:switch</source> assigns <kbd>Right Alt</kbd> to switch to the secondary <source lang=console inline>apl</source> layout when it is pressed, otherwise <source lang=console inline>us</source> is used
| |
| | |
| * <source lang=console inline>-variant ,dyalog</source> assigns the [[Dyalog APL]] variant to the <source lang=console inline>apl</source> layout which contains modifiations unique to the Dyalog language ('''Note the preceding comma''')
| |
| | |
| A full list of keys that can be used to switch layouts is included in <source lang=console inline>/usr/share/X11/xkb/rules/evdev.lst</source> under the <source lang=console inline>option</source> category.
| |
| | |
| '''Note:''' these changes are not permanent; the user will have to select one of a myriad of methods to run the command on startup. Alternatively, if they use one of the [[wikipedia:Desktop_environment|desktop environments]] listed below, they can follow those instructions.
| |
| | |
| ==== GNOME ====
| |
| | |
| ===== GUI =====
| |
| | |
| # Open the Activities menu; this is located in the top-left corner of a default GNOME 3 session (alternatively, use your <kbd>Super</kbd> key to open the Activities overlay):<br>[[File:Gnome-kbd-setup-1.png|frameless|GNOME Keyboard Step 1: Open Activities Menu]]
| |
| # Search for "startup." When the Startup Applications program is highlighted, press the <kbd>Enter</kbd> key to open it: <br>[[File:Gnome-kbd-setup-2.png|frameless|GNOME Keyboard Step 2: Search for Startup Applications]]
| |
| #Select the <kbd>Add</kbd> button on the right-hand side:<br>[[File:Gnome-kbd-setup-3.png|frameless|GNOME Keyboard Step 3: Click the <kbd>Add</kbd> button in Startup Applications window]]
| |
| #Provide a name, enter your <code>setxkbmap</code> command, and click <kbd>Add</kbd> when finished:<br>[[File:Gnome-kbd-setup-4.png|frameless|GNOME Keyboard Step 4: Enter the relevant information for your command]]
| |
| | |
| ===== Terminal =====
| |
| | |
| # Navigate to <code>~/.config/autostart</code> and create a <code>.desktop</code> with any name that will help you remember its function.
| |
| # Add the following to the contents of your file, customizing to suit your needs:<source lang=ini>
| |
| [Desktop Entry] | |
| Type=Application
| |
| Exec=setxkbmap -layout us,apl -variant ,dyalog -option grp:switch
| |
| Hidden=false
| |
| NoDisplay=false
| |
| X-GNOME-Autostart-enabled=true
| |
| Name[en_US]=apl-keyboard
| |
| Name=apl-keyboard
| |
| Comment[en_US]=
| |
| Comment=
| |
| </source>
| |
| | |
| ==== LXDE ====
| |
| | |
| # Prepend an <source lang=console inline>@</source> to the <source lang=console inline>setxkbmap</source> command from above:<br><source lang=console>
| |
| @setxkbmap -layout us,apl -variant ,dyalog -option grp:switch
| |
| </source>
| |
| # Add it as a line in your user's LXDE <source lang=console inline>autostart</source> file, located at:<br><source lang=console>
| |
| ~/.config/lxsession/LXDE/autostart
| |
| </source>
| |
| | |
| For Lubuntu versions up to and including 18.04 (before the LXQt split), the location of <source lang=console inline>autostart</source> is <source lang=console inline>~/.config/lxsession/Lubuntu/autostart</source>.
| |
| | |
| ==== LXQt ====
| |
| | |
| ===== GUI =====
| |
| | |
| # From your LXQt panel, navigate to ''Preferences'' → ''LXQt Settings'' → ''Session Settings''; alternatively, enter <source lang=console inline>lxqt-config-session</source> in your terminal emulator. You will be greeted with the following window:<br>[[File:Lxqt-session-settings.png|frameless|LXQt Autostart menu of Session Settings window]]
| |
| # Select the <source lang=console inline>LXQt Autostart</source> dropdown (it will be highlighted as shown above) and click the <kbd>Add</kbd> button to display the following pop-up window:<br>[[File:Lxqt-add-autostart.png|frameless|LXQt add a new autostart menu item]]
| |
| # Provide a name, enter your <code>setxkbmap</code> command, and click <kbd>OK</kbd> when finished.
| |
| | |
| ===== Terminal =====
| |
| | |
| The above GUI approach merely creates a <source lang=console inline>.desktop</source> file in the user's <source lang=console inline>~/.config/autostart</source>. Create your own file in the <source lang=console inline>autostart</source> directory whose contents are as follows, to replicate the functionality achieved through the GUI:
| |
| | |
| <source lang=ini>
| |
| [Desktop Entry]
| |
| Exec=setxkbmap -layout us,apl -variant ,dyalog -option grp:switch
| |
| Name=apl-keyboard
| |
| OnlyShowIn=LXQt;
| |
| Type=Application
| |
| Version=1.0
| |
| </source>
| |
| | |
| ==== MATE ====
| |
| | |
| ===== GUI =====
| |
| | |
| # Open your MATE menu (in the top-left corner of a default environment) and select ''Control Center'' at the bottom of the window:<br>[[File:Mate-kbb-setup-1.png|frameless|Launch the Control Center from the MATE menu]]
| |
| # Scroll down through the main window, and under the ''Personal'' category, select ''Startup Applications'':<br>[[File:Mate-kbb-setup-2.png|frameless|Scroll down to the Startup Applications option]]
| |
| # Click the <kbd>Add</kbd> button on the right-hand side:<br>[[File:Mate-kbb-setup-3.png|frameless|Click <kbd>Add</kbd> to add a new startup command]]
| |
| # Provide a name, enter your <code>setxkbmap</code> command, and click <kbd>Add</kbd> when finished:<br>[[File:Mate-kbb-setup-4.png|frameless|Enter the setxkbmap command you wish to use]]
| |
| | |
| ===== Terminal =====
| |
| | |
| Navigate to <code>~/.config/autostart</code> and create a <code>.desktop</code> with any name that will help you remember its function.
| |
| | |
| Add the following to the contents of your file, customizing to suit your needs:
| |
| | |
| <source lang=ini>
| |
| [Desktop Entry]
| |
| Type=Application
| |
| Exec=setxkbmap -layout us,apl -variant ,dyalog -option grp:switch
| |
| Hidden=false
| |
| X-MATE-Autostart-enabled=true
| |
| Name[en_US]=apl-keyboard
| |
| Name=apl-keyboard
| |
| Comment[en_US]=
| |
| Comment=
| |
| X-MATE-Autostart-Delay=0
| |
| </source>
| |
| | |
| ==== Xfce ====
| |
| | |
| A tutorial specific to Xfce's config files can be found [https://github.com/hashslingrz/apl-keyboard-xfce at this GitHub repository].
| |
|
| |
|
| == Approaches to Layout and Input == | | == Approaches to Layout and Input == |