diff options
Diffstat (limited to 'docs/editors')
| -rw-r--r-- | docs/editors/index.html | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/docs/editors/index.html b/docs/editors/index.html index 882525c6..a787eeeb 100644 --- a/docs/editors/index.html +++ b/docs/editors/index.html @@ -4,7 +4,7 @@ <title>BQN: Editor support</title> </head> <div class="nav">(<a href="https://github.com/mlochbaum/BQN">github</a>) / <a href="../index.html">BQN</a></div> -<h1 id="editor-support">Editor support</h1> +<h1 id="editor-support"><a class="header" href="#editor-support">Editor support</a></h1> <style>.Comment,.Function,.Number,.String { color: inherit; }</style> <p>Editor plugins and other tools for allowing BQN input are in <a href="https://github.com/mlochbaum/BQN/tree/master/editors">this folder</a>. Input is always performed with a backslash <code><span class='Value'>\</span></code> prefix by default, using the layout shown <a href="https://mlochbaum.github.io/BQN/keymap.html">here</a>. To type an actual backslash, hit the backslash key twice.</p> <p><a href="https://abrudz.github.io/lb/bqn">This bookmarklet</a> enables BQN input in any webpage in your <strong>browser</strong>.</p> @@ -12,29 +12,29 @@ <p>For <strong>Android</strong>, <a href="https://github.com/dzaima/hackerskeyboard/releases/latest">this fork</a> adds APL and BQN to Hacker's Keyboard.</p> <p>The file <a href="https://github.com/mlochbaum/BQN/blob/master/editors/inputrc">inputrc</a> can be copied or appended to <code><span class='Value'>~</span><span class='Function'>/</span><span class='Value'>.inputrc</span></code> to enable backslash input in <strong>bash</strong>, BQN with <strong>rlwrap</strong>, and other software that uses GNU Readline.</p> <p>If you'd like to contribute files for another editor I'd gladly accept them!</p> -<h2 id="system-wide">System-wide</h2> -<h3 id="xkb-unix">XKB (Unix)</h3> +<h2 id="system-wide"><a class="header" href="#system-wide">System-wide</a></h2> +<h3 id="xkb-unix"><a class="header" href="#xkb-unix">XKB (Unix)</a></h3> <p>The file <a href="https://github.com/mlochbaum/BQN/blob/master/editors/bqn">bqn</a> is for configuring XKB on Linux, or other systems using X11. To use, copy it to <code><span class='Function'>/</span><span class='Value'>usr</span><span class='Function'>/</span><span class='Value'>share</span><span class='Function'>/X11/</span><span class='Value'>xkb</span><span class='Function'>/</span><span class='Value'>symbols</span><span class='Function'>/</span></code>, then run</p> <pre><span class='Value'>$</span> <span class='Value'>setxkbmap</span> <span class='Function'>-</span><span class='Value'>layout</span> <span class='Value'>us</span><span class='Separator'>,</span><span class='Value'>bqn</span> <span class='Function'>-</span><span class='Value'>option</span> <span class='Value'>grp:switch</span> </pre> <p>replacing <code><span class='Value'>us</span></code> with your ordinary keyboard layout. <code><span class='Value'>switch</span></code> indicates the right alt key and can be replaced with <code><span class='Value'>lswitch</span></code> for left alt or other codes. The setting will go away on shutdown so you will probably want to configure it to run every time you start up. The way to do this depends on your desktop environment. For further discussion, see <a href="https://en.wikipedia.org/wiki/X_keyboard_extension">Wikipedia</a> or the <a href="https://aplwiki.com/wiki/Typing_glyphs_on_Linux">APL Wiki</a>.</p> <p>Another XKB option, if you have a compose key enabled, is to place <a href="https://github.com/mlochbaum/BQN/blob/master/editors/XCompose">XCompose</a> (possibly with adjustments) in <code><span class='Value'>~</span><span class='Function'>/</span><span class='Value'>.</span><span class='Function'>XCompose</span></code>.</p> -<h3 id="windows">Windows</h3> +<h3 id="windows"><a class="header" href="#windows">Windows</a></h3> <p>Folder <a href="https://github.com/mlochbaum/BQN/tree/master/editors/autohotkey-win">autohotkey-win</a> contains an <a href="https://en.wikipedia.org/wiki/AutoHotKey">AutoHotKey</a> script and the generated .exe file. It runs as an ordinary program that recognizes BQN key combinations system-wide, using the right alt key (to change this, replace <code><span class='Function'>RAlt</span></code> in the script and rebuild). Move it to the startup folder if you'd like to have it running all the time. You can right-click its icon in the system tray to disable it temporarily.</p> <p>The <a href="https://github.com/mlochbaum/BQN/blob/master/editors/XCompose">XCompose</a> file, although created for XKB, should also be usable with <a href="https://github.com/samhocevar/wincompose">WinCompose</a> (but as far as I know this hasn't been tested).</p> -<h2 id="text-editors">Text editors</h2> -<h3 id="vim">Vim</h3> +<h2 id="text-editors"><a class="header" href="#text-editors">Text editors</a></h2> +<h3 id="vim"><a class="header" href="#vim">Vim</a></h3> <p>Copy or symlink all files into the corresponding directories in <code><span class='Value'>~</span><span class='Function'>/</span><span class='Value'>.vim</span></code>. Add the following two lines to <code><span class='Value'>~</span><span class='Function'>/</span><span class='Value'>.vim</span><span class='Function'>/</span><span class='Value'>filetype.vim</span></code>:</p> <pre> <span class='Value'>au</span><span class='Function'>!</span> <span class='Function'>BufRead</span><span class='Separator'>,</span><span class='Function'>BufNewFile</span> <span class='Value'>*.bqn</span> <span class='Value'>setf</span> <span class='Value'>bqn</span> <span class='Value'>au</span><span class='Function'>!</span> <span class='Function'>BufRead</span><span class='Separator'>,</span><span class='Function'>BufNewFile</span> <span class='Value'>*</span> <span class='Value'>if</span> <span class='Value'>getline</span><span class='Paren'>(</span><span class='Number'>1</span><span class='Paren'>)</span> <span class='Function'>=</span><span class='Value'>~</span> <span class='String'>'</span><span class='Value'>^</span><span class='Comment'>#!.*bqn$' | setf bqn | endif </span></pre> <p>Include <code><span class='Value'>syntax</span> <span class='Value'>on</span></code> in your .vimrc for syntax highlighting and <code><span class='Value'>filetype</span> <span class='Value'>plugin</span> <span class='Value'>on</span></code> for keyboard input.</p> -<h3 id="emacs">Emacs</h3> +<h3 id="emacs"><a class="header" href="#emacs">Emacs</a></h3> <p>Add the following two lines to <code><span class='Value'>init.el</span></code> (usually <code><span class='Value'>~</span><span class='Function'>/</span><span class='Value'>.emacs.d</span><span class='Function'>/</span><span class='Value'>init.el</span></code>), replacing the path appropriately.</p> <pre><span class='Paren'>(</span><span class='Value'>add</span><span class='Function'>-</span><span class='Value'>to</span><span class='Function'>-</span><span class='Value'>list</span> <span class='String'>'</span><span class='Value'>load</span><span class='Function'>-</span><span class='Value'>path</span> <span class='String'>"/path/to/BQN/editors/emacs"</span><span class='Paren'>)</span> <span class='Paren'>(</span><span class='Value'>require</span> <span class='String'>'</span><span class='Value'>gnu</span><span class='Function'>-</span><span class='Value'>apl</span><span class='Function'>-</span><span class='Value'>mode</span><span class='Paren'>)</span> </pre> -<h3 id="vs-code">VS Code</h3> +<h3 id="vs-code"><a class="header" href="#vs-code">VS Code</a></h3> <p>See <a href="https://github.com/razetime/bqn-vscode">this repository</a>.</p> -<h3 id="kakoune">Kakoune</h3> +<h3 id="kakoune"><a class="header" href="#kakoune">Kakoune</a></h3> <p>Copy or symlink <code><span class='Value'>kak</span><span class='Function'>/</span><span class='Value'>autoload</span><span class='Function'>/</span><span class='Value'>filetype</span><span class='Function'>/</span><span class='Value'>bqn.kak</span></code> into <code><span class='Value'>autoload</span><span class='Function'>/</span><span class='Value'>filetype</span></code> in your Kakoune config directory (probably <code><span class='Value'>.config</span><span class='Function'>/</span><span class='Value'>kak</span><span class='Function'>/</span></code>).</p> |
