https://github.com/con-f-use/latex-keyboard
Keyboad-Layout and instructions for quicker (La)TeXing
https://github.com/con-f-use/latex-keyboard
Last synced: 4 months ago
JSON representation
Keyboad-Layout and instructions for quicker (La)TeXing
- Host: GitHub
- URL: https://github.com/con-f-use/latex-keyboard
- Owner: con-f-use
- Created: 2016-02-22T11:42:15.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-02-22T13:48:02.000Z (over 9 years ago)
- Last Synced: 2025-02-15T12:38:23.011Z (4 months ago)
- Language: Shell
- Size: 204 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Latex-Keyboard
Keyboad-Layout and instructions for quicker (La)TeXing
## Summary
With just a simple command it is possible to map any UTF-8 character in a LaTeX
document to just about every LaTeX command, as if the character was the actual
LaTeX command. While this is useful for allot of things, it is particularly
nice with a custom keyboard layout.Here is an example LaTeX source before character mapping:
f(x) = \int_{-\infty}^\infty \hat f(\xi)\ e^{2 \pi i \xi x}\,d\xi
And here the same source after:
f(x) = ∫_{-∞}^∞ \hat f(ξ) e^{2πi ξ x} dξ
Not only is the second code more readable, but it is faster and easier to type,
if your keyboard layout looks like this:
For people that type a lot in LaTeX or have special Symbols of other languages
that they use allot, this might be nice.## Usage
Simple put these lines before `\begin{document}` in your latex file:
\usepackage[utf8]{inputenc}
\input{/path/to/unicodedecl.tex}Where you have to replace `/path/to/unicodedecl.tex` with the actual path to
the file of same name in this repository.## Installing the custom layout
### Ubuntu 14.04
On Ubuntu, setting up the custom keyboard layout is as easy as running this
script:./installCustomLayout.sh
All it does is make a backup of the relevant layout file and then overwrite the
"English (Macintosh)" layout with the custom layout shown in the picture above.
Layouts are cached as binary files `/var/lib/xkb/server-*.xkm`. This means that
the script has to run `dpkg-reconfigure xkb-data`. On other systems/versions,
one might not have to run that command or delete the cache files and reboot
to take effect.### Customization
The only changes to the layout file are between lines 675 and 746 in
./installCustomLayout.sh`. They should be fairly self explanatory and the
structure clear. Change the individual characters to what ever you use most.# Alternatives
\documentclass{article}
\usepackage[mathletters]{ucs}
\usepackage[utf8x]{inputenc}\begin{document}
The vorticity $ω$ is defined as $ω = ∇ × u$.
\end{document}