Differences between revisions 14 and 15
Revision 14 as of 2009-09-10 23:05:37
Size: 4655
Editor: KaiJaeger
Comment:
Revision 15 as of 2017-02-16 18:59:50
Size: 2451
Editor: KaiJaeger
Comment:
Deletions are marked like this. Additions are marked like this.
Line 21: Line 21:
== Using an extended keyboard layout ==
The traditional way of entering special APL symbols is via the keyboard using one of a number of extended keyboard layouts.

For illustration purposes, here is the 'unified' layout which is selected by default in APLX. This is configured as follows (the exact layout will vary according to the country in which you live and the specific model of keyboard):

{{attachment:aplx_keyboard.jpg}}

As you can see, each key is shown with up to four symbols. As with a conventional keyboard, a given character key generates a lower case character and, when depressed in conjunction with the Shift key, the corresponding upper case character. These are shown in black and red on the above diagram, in the lower-left and upper-left positions on each key.

In order to enter the other symbols, you use the Alt key <<FootNote(This is true for APLX, APL+Win & NARS2000; for Dyalog, use the Ctrl key; For APL2, refer to the documentation)>> which acts just like the Shift key in that it modifies the effect of another key. Using the Alt key with another key produces the symbol displayed in green, on the lower right of each key in the diagram above. The remaining symbols (shown in blue, on the top right of each key) are entered by pressing the Alt and Shift keys simultaneously. (Note: On a Macintosh keyboard, use the Alt or Option key instead of Alt).

For example, the key in the upper row of the keyboard, inscribed with the digit 4, produces the following symbols:



 * If pressed by itself, the digit {{{4}}}

 * If pressed with Shift, the dollar sign {{{$}}}

 * If pressed with Alt, the APL less-than-or-equals symbol {{{≤}}}

 * If pressed with Shift and Alt, the APL grade-up (sort) symbol {{{⍋}}}

Most other modern APLs use a similar scheme to APLX, but you should check your vendor's documentation.
Line 55: Line 30:
Some APLs go further and allow complete customisation of which character is obtained for each key combination, so you can tailor the keyboard to suit yourself. Here are examples from [[APLXKeyboardLayouts|APLX]]
Line 60: Line 33:
Some APLs also include facilities to enter APL characters by choosing from a palette of symbols on screen. For example, APLX has a [[http://www.microapl.co.uk/apl/introduction_chapter3.html|QuickSym]] facility. Some APLs also include facilities to enter APL characters by choosing from a palette of symbols on screen.
Line 70: Line 43:
CategoryAboutApl - CategoryAplx CategoryAboutApl

Entering APL Symbols (2 of 14)

APL uses a variety of symbols to represent its built-in functions. Many of these are symbols that do not exist on a standard keyboard. Some of these will be familiar (for example, ÷ for divide, and for greater-than-or-equal). Others are specific to APL (for example for round-up or greater-of, and for finding out if two arrays are exactly the same in shape and contents).

In order to use APL, you need to be able to enter these symbols.

The exact way of doing so will vary from one APL to another, so the following is only a guide. You should consult the documentation which comes with your version of APL.

Choosing the keyboard layout

Two APL keyboard layouts are quite commonly used, and some APLs support both:

  • The Unified APL layout, as shown above. This is similar to an ordinary ASCII keyboard layout for unshifted and shifted keys. Special APL symbols are obtained by using !Alt or Shift-!Alt combinations. If you are learning APL we recommend that you use this layout if available.

  • The Standard or Traditional APL layout. This is based on the traditional APL keyboard where alphabetic keys unshifted give upper-case letters, shifted give APL symbols, and with the Alt key give lower-case letters. It is recommended only for people who are used to programming in APL using a special APL keyboard.

Within these two schemes your APL may also let you choose between different language versions, for example a keyboard layout including all the characters needed to type Danish or French.

Suggestion: If you are learning the APL keyboard, you should check whether your APL includes an on-screen keyboard which you can display for reference purposes.

Other ways of entering APL

Some APLs also include facilities to enter APL characters by choosing from a palette of symbols on screen.


CategoryAboutApl

LearnApl/EnteringAplSymbols (last edited 2017-02-16 18:59:50 by KaiJaeger)