root/linux/bin/installiere_neo @ 1312

Revision 1312, 70.6 KB (checked in by pascal, 4 years ago)

Kommentare hinzugefügt

  • Property svn:executable set to *
Line 
1#!/bin/bash
2# Copyright 2008 Pascal Hauck <pascal.hauck@web.de>
3# Distributed under the terms of the GNU General Public License v3
4
5# ======= Installation =======
6# Um NEO auf Ihrem System zu (dauerhaft) zu installieren, genügt es, dieses Skript auszuführen
7# z.B. in der Konsole die folgenden beiden Zeilen eingeben:
8# chmod u+x installation
9# ./installation
10# Nun ist NEO auf Ihrem System dauerhaft installier
11# Ein Wechsel zurück zu QWERTZ ist jederzeit mit ›uiae‹ leicht möglich
12
13# Wenn NEO nicht automatisch nach dem Login gestartet werden soll, genügt es, vor die Zeile, die mit
14# asdf   # mit einem # am Zeilenanfang
15# beginnt und sich in der Datei $HOME/.profile befinden, ein # zu setzen
16# ==============================
17
18
19# ======= Deinstallation =======
20# Um NEO wieder zu deinstallieren, kann das Skript ›installiere_neo‹ ein weiteres Mal aufgerufen werden
21# ==============================
22
23
24# ======= Bemerkungen ==========
25# Dieses Skript ist eine rudimentäre Installation. Derzeit gibt es keine Konfigurationsmöglichkeit.
26# Es wird immer das Standardverzeichnis $HOME/neo verwendet
27# Es gibt keine graphische Installation
28# Dennoch kann dieses Skrip helfen, NEO auf eine einfache Weise zu installieren.
29# Dieses Skript wird mit der Zeit verbessert werden.
30# ==============================
31
32
33# colours in the Bash
34B="\033[30m"
35R="\033[31m"
36G="\033[32m"
37
38datei() {  # cut files from the complete file ›installiere_neo‹
39        grep -A10000 "#neo: $1 --- Beginn" installation | grep -B10000 "#neo: $1 --- Ende" | grep -v "#neo:"
40}
41
42erzeuge() {  # create directories, files and entries
43        case $1 in
44        d) # directory
45                if [ -d $2 ]                            # if already exists
46                then
47                        echo -e "Das Verzeichnis ${R}$2${B} gibt es bereits – wird verwendet…"
48                else
49                        echo -e "Erstelle $2"
50                        mkdir $2                        # create
51                fi
52                ;;
53        f) # file
54                if [ -f $3 ]                            # if already exists
55                then
56                        echo -e "Die Datei ${R}$3${B} gibt es bereits – soll die bestehende Datei überschrieben werden? \c"; read -p "[J,N] " -e overwrite
57                        if [ "$overwrite" = "J" ]       # overwrite?
58                        then
59                                echo "Datei $3 wird überschrieben!"
60                                rm -f $3                # remove if user wants to overwrite
61                        else
62                                echo -e "Datei ${R}$3${B} gibt es schon → Installation abgebrochen"
63                                exit
64                        fi
65                fi
66                echo "Erstelle Datei $3"                # create
67                datei $2 > $3
68                ;;
69        l) # soft link
70                if [ -d $HOME/bin/ ]                    # $HOME/bin has to exist!
71                then
72                        echo "Verzeichnis $HOME/bin/ gefunden"
73                else
74                        echo -e "Verzeichnis ${R}$HOME/bin${B} wird erwartet, ist aber nicht vorhanden"
75                        echo "Außerdem wird erwartet, dass /$HOME/bin in der Umgebungsvariable \$PATH ist"
76                        echo "Istallation wird abgebrochen."
77                        exit
78                fi
79                if [ -f $HOME/bin/$2 ]                  # if already exists
80                then
81                        echo -e "Datei ${R}$HOME/bin/$2${B} gibt es bereits – soll die bestehende Datei überschrieben werden? \c"; read -p "[J,N] " -e overwrite
82                        if [ "$overwrite" = "J" ]       # overwrite?
83                        then
84                                echo "Datei $2 wird überschrieben!"
85                                rm -f $HOME/bin/$2      # remove if user wants to overwrite
86                        else
87                                echo -e "Datei ${R}$2${B} gibt es schon → Installation abgebrochen"
88                                exit
89                        fi
90                fi
91                echo "Erstelle Link $HOME/bin/$2"
92                ln -s $HOME/neo/$2 $HOME/bin            # create
93                ;;
94        esac
95}
96
97entferne(){  # remove files for uninstall option
98        echo "Entferne $1"
99        rm $1 || echo -e "${R}Konnte die Datei $1 nicht entfernen!${B}"
100}
101
102deinstall() {  #remove all directories, files and entries made by ›installiere_neo‹
103        echo
104        echo
105        rmfromprofile
106        entferne $HOME/.neorc
107        entferne $HOME/bin/uiae
108        entferne $HOME/neo/uiae
109        entferne $HOME/bin/asdf
110        entferne $HOME/neo/asdf
111        entferne $HOME/neo/neo.map
112        entferne $HOME/neo/neo_de.xmodmap
113        echo "Entferne $HOME/neo/"
114        rmdir $HOME/neo/ || echo -e "${R}Konnte das Verzeichenis $HOME/neo/ nicht entfernen!${B}"
115}
116
117rmfromprofile() {  # remove the entry in $HOME/.profile
118        grep -v "^\# NEO:$" $HOME/.profile | grep -v "asdf   \# mit" > $HOME/profile.neo.tmp
119        rm /$HOME/.profile
120        mv $HOME/profile.neo.tmp $HOME/.profile
121}
122
123
124# *** main program ***
125clear
126echo
127echo "   *** NEO – Ergonomie und Zeichenvielfalt ***"
128echo
129echo
130echo " Ihr System wird untersucht…"
131echo
132
133# check for an existing neo configuration
134if [ -f "${NEO_CONFIG}" ]; then
135        . "${NEO_CONFIG}" || die "Failed to source ${NEO_CONFIG}"
136elif [ -f "${HOME}"/.neorc ]; then
137        . "${HOME}"/.neorc || die "Failed to source ${HOME}/.neorc"
138elif [ -f /etc/neo.conf ]; then
139        . /etc/neo.conf || die "Failed to source /etc/neo.conf"
140else
141
142# no configuration file found → install NEO
143        echo "Bislang gibt es kein vollständig konfiguriertes NEO auf Ihrem System"
144        echo
145        echo "Sie haben folgende Möglichkeiten:"
146        echo
147        echo " [1]  NEO nur testen"
148        echo "       Sie haben die Möglichkeit, NEO zu Testen, ihre Standardbelegung (in der Regel QWERTZ) bleibt erhalten"
149        echo
150        echo
151        echo " [2] NEO als Standardbelegung"
152        echo "       Mit dieser Option wird NEO die neue Standardbelegung für diesen Benutzer und nach (nicht vor!) dem"
153        echo "       Login automatisch aktiviert"
154        echo
155        echo
156        echo -e " Wenn ${G}installiere_neo${B} ein weiteres Mal aufgerufen wird, haben weitere Optionen – z.B. die Deinstallation von NEO"
157        echo
158
159        installoption=""
160        while [ ! $installoption ]                      # choose between QWERTZ or NEO as standard
161        do                                              # switch with ›asdf‹ and ›uiae‹
162                echo
163                read -p "Wählen Sie eine Option [1,2]: " -e installoption
164                case $installoption in
165                2)
166                        echo
167                        echo "Nach dem Login wird NEO die Standardbelegung sein."
168                        echo -e "Um dies zu ändern, kann ${G}installiere_neo${B} ein weiteres Mal ausgeführt werden."
169                        echo
170                        read -n1 -p "Drücke eine Taste um fortzufahren oder STRG+C zum Abbrechen"
171                        ;;
172                1)
173                        echo
174                        echo "Das Standardlayout wird nich verändert."
175                        echo -e "Zu NEO kann man jederzeit mit der Abrollbewegung ${G}asdf${B} wechseln."
176                        echo
177                        read -n1 -p "Drücke eine Taste um fortzufahren oder STRG+C zum Abbrechen"
178                        ;;
179                *)
180                        echo
181                        echo "Bitte wählen Sie die Optionen 1, um NEO zu testen oder 2, um NEO zur Standardbelegung zu machen"
182                        installoption=""
183                        ;;
184                esac
185        done
186
187
188        echo
189        echo
190        echo " Installation von NEO mit xmodmap wird gestartet…"
191        echo
192        echo
193
194# *** main installation process ***
195# creating a directory $HOME/neo with NEO files
196# linking ›asdf‹ and ›uiae‹ scripts to $HOME/bin
197        erzeuge d $HOME/neo
198        erzeuge f xmodmap $HOME/neo/neo_de.xmodmap
199        erzeuge f console $HOME/neo/neo.map
200        erzeuge f asdf $HOME/neo/asdf
201        chmod u+x $HOME/neo/asdf
202        erzeuge l asdf
203        erzeuge f uiae $HOME/neo/uiae
204        chmod u+x $HOME/neo/uiae
205        erzeuge l uiae
206        erzeuge f neorc $HOME/.neorc
207
208# entry in $HOME/.profile with NEO or QWERTZ as standard keyboard layout after login
209        case $installoption in
210        2)
211                echo
212                echo "Nach dem Login wird NEO die Standardbelegung sein."
213                echo -e "Um dies zu ändern, kann ${G}installiere_neo${B} ein weiteres Mal ausgeführt werden."
214                rmfromprofile
215                datei profile.neo > $HOME/neo/neo.profile
216                cat $HOME/neo/neo.profile >> $HOME/.profile
217                rm $HOME/neo/neo.profile
218                ;;
219        1)
220                echo
221                echo "Das Standardlayout wird nich verändert."
222                echo -e "Zu NEO kann man jederzeit mit der Abrollbewegung ${G}asdf${B} wechseln."
223                rmfromprofile
224                datei profile.qwertz > $HOME/neo/neo.profile
225                cat $HOME/neo/neo.profile >> $HOME/.profile
226                rm $HOME/neo/neo.profile
227                ;;
228        esac
229
230# starting NEO layout
231        echo
232        echo "Die Belegung wird nun auf NEO geändert…" 
233        cd $HOME/neo
234        ./asdf xmodmap
235        echo -e "Um zu QWERTZ zurückzukehren, genügt es, die Abrollbewegung ${G}uiae${B} einzugeben."
236        exit
237fi
238
239
240# configuration file found → delete/deinstall options
241        echo "Es gibt auf Ihrem System bereits eine Konfiguration für NEO."
242        echo
243        echo "Sollte NEO nur für diesen Benutzer installiert sein, haben folgende Möglichkeiten:"
244        echo
245        echo " [1]  NEO zukünftig nicht mehr als Standardbelegung"
246        echo -e "       NEO wird nicht länger direkt nach dem Login zur Verfügung stehen, wohl aber nach Eingabe von ${G}adsf${B}."
247        echo
248        echo
249        echo " [2] NEO vollständig vom System entfernen"
250        echo "       Dieso Option entfernt alle zuvor angelegten Verzeichnisse, Datein und Einträge zur NEO-Belegung"
251        echo
252        echo
253        echo " Diese Optionen funktionieren nur dann zuverlässig, wenn NEO auch mit ${G}installiere_neo${B} installiert wurde"
254        echo
255
256        deinstalloption=""
257        while [ ! $deinstalloption ]                    # choose between deleting NEO as standard layout or delete NEO at all
258        do                                              # if deleted as standard layout only, ›asdf‹ is still working
259                echo
260                read -p "Wählen Sie eine Option [1,2]: " -e deinstalloption
261                case $deinstalloption in
262                2)
263                        echo
264                        echo -e "Alle zuvor von ${G}installiere_neo${B} vorgenommen Änderungen am System werden gelöscht!"
265                        echo
266                        read -n1 -p "Drücke eine Taste um fortzufahren oder STRG+C zum Abbrechen"
267                        deinstall                       # full deinstallation
268                        ;;
269                1)
270                        echo
271                        echo "NEO wird als Standardbelegung entfernt"
272                        echo -e "Zu NEO kann man weiterhin jederzeit mit der Abrollbewegung ${G}asdf${B} wechseln."
273                        echo
274                        read -n1 -p "Drücke eine Taste um fortzufahren oder STRG+C zum Abbrechen"
275                        echo
276                        rmfromprofile                   # alter the entry in $HOME/.profile; first: remove old entry
277                        echo >> $HOME/.profile          # write the new entry
278                        echo "# NEO:" >> $HOME/.profile
279                        echo "# asdf   # mit einem # am Zeilenanfang bleibt QWERTZ das Standardlayout, sonst ist es NEO" >> $HOME/.profile
280                        ;;
281                *)
282                        echo
283                        echo "Bitte wählen Sie die Optionen 1, um NEO nicht länger als Standardbelegung zu nutzen"
284                        echo " oder 2, um NEO vollständig zu entfernen"
285                        deinstalloption=""
286                        ;;
287                esac
288        done
289exit
290
291#neo: xmodmap --- Beginn
292!! ~/.xmodmap
293!!
294!! German NEO-Layout
295!! adopted 2004 by Hanno Behrens <Hanno.Behrens@gmx.de>
296!! inspired by Dvorak/de-ergo  http://www.goebel-consult.de/de-ergo/
297!! Authors:
298!!      Benjamin Kellermann <Benjamin dot Kellermann at gmx dot Germany>
299!!      Erik Streb <mail at erikstreb dot de>
300!!      Pascal Hauck <pascal dot hauck at web dot de>
301!!
302!! Other Questions:
303!!      <mailinglist at neo-layout dot org>
304!!
305!! $Revision: 1293 $, $Date: 2008-12-19 09:39:48 +0100 (Fr, 19 Dez 2008) $
306!! http://pebbles.schattenlauf.de/layout.php
307!!
308!! To try the layout in this file, simply do xmodmap <file>.
309!! To load the layout in this file at X startup, simply store it as
310!! ~/.xmodmap
311
312
313!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
314! Ebenen
315!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
316! Ebene 1: normal
317! Ebene 2: Shift
318! Ebene 3: Mod3
319! Ebene 4: Mod4 (zum Markieren Shift+Mod4)
320! Ebene 5: Shift+Mod3
321! Ebene 6: Mod3+Mod4 (in dieser Reihenfolge!)
322! Ebene 7: wird (bis auf technisch bedingte Ausnahmen) nicht belegt
323! Multi_key=Compose (keine eigene Ebene): Mod3+Tab or right window key
324! Feststellen/Shift_Lock: Shift+Shift
325! Mod4_Lock: Mod4(rechts)+Mod4(links)
326
327! Reihenfolge der Ebenen in der Xmodmap:
328!            Ebene1  Ebene2  Ebene3  Ebene5  Ebene4  Ebene4+Sh  Ebene6 Ebene7
329
330
331!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
332! Modifier definition
333!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
334clear Lock
335clear Mod2
336! Mod2 war NumLock !
337clear Mod3
338clear Mod5
339
340!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
341! Shift
342!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
343! 50=left 62=right
344! Shift+Shift ergibt ein ShiftLock (wie Caps, wirkt aber auf alle Zeichen, nicht nur auf Großbuchstaben)
345! Der Lock lässt sich durch ein weiteres Shift lösen.
346! Eigentlich (siehe Referenz) sollte hier ein CapsLock stehen.
347keycode 50 =  Shift_L Shift_Lock
348keycode 62 =  Shift_R Shift_Lock
349
350!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
351! Mod3
352!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
353! 66=left 51=right
354! Make CapsLock an modifier called Mod3 (similar to AltGr) (Mode_switch or ISO_Group_Shift is for 3rd and 4th level)
355! Make former CapsLock and qwertz-# to Mode_switch or ISO_Group_Shift
356! Mod3(links) (=Qwertz-Caps) erlaubt nur 4 Ebenen
357! Ohne einen Eintrag in der zweiten Gruppe (=Ebene 3) ergäbe Mod3+Mod3=Group_Shift+Group_Shift=Gruppe 3=Ebene 6. Das ist nicht gewünscht.
358keycode 66 =  ISO_Group_Shift ISO_Group_Shift ISO_First_Group  NoSymbol
359keycode 51 =  ISO_Group_Shift ISO_Group_Shift ISO_First_Group  NoSymbol
360
361!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
362! Mod4
363!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
364! 94=left 113=right
365! Make the former AltGr and qwertz-< to Mod4 (ISO_Level3_Shift)
366! Mod4(rechts)+Mod4(links) lässt Mod4 einrasten (Mod4Lock)
367! das funktioniert nur in dieser Reihenfolge, da Mod4(rechts) (=Qwertz-AltGr) nur 4 Ebenen hat
368! Der Lock lässt sich durch ein weiteres Mod4 lösen.
369keysym less = ISO_Level3_Shift  ISO_Level3_Shift  ISO_Group_Shift   ISO_Group_Shift  ISO_Level3_Lock  NoSymbol
370keysym ISO_Level3_Shift = ISO_Level3_Shift  ISO_Level3_Shift  ISO_Group_Shift   ISO_Group_Shift  ISO_Level3_Lock  NoSymbol
371
372!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
373! window keys
374!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
375! keysym Super_L = Super_L
376! keycode 116 = Super_R
377keysym Super_R = Multi_key Multi_key
378! add Mod4 = Super_L
379
380!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
381! general Lock
382!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
383! Einrasten über linke Win-Taste+Modifier, Lösen über nochmaliges Betätigen des Modifiers
384! Shift_Lock und Mo4_Lock funktionieren, Mod3_Lock lässt sich aber nicht mehr lösen!!!!
385! keycode 115 = ISO_Lock  NoSymbol
386! add Lock = ISO_Lock
387
388
389! add Mod3 = ISO_Group_Shift
390! add Mod5 = ISO_Level3_Shift
391
392
393
394!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
395! main keyboard
396!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
397
398!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
399! Tab key
400!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
401keycode 23 = Tab  ISO_Left_Tab  Multi_key  ISO_Level3_Lock
402
403!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
404! Space key
405!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
406keycode 65 = space  space  space  nobreakspace  KP_0  KP_0  U202F  NoSymbol
407
408!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
409! dead keys
410!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
411!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene4          Ebene4+Sh       Ebene6          Ebene7
412
413keycode 49 = dead_circumflex    dead_tilde      dead_abovering  dead_breve      dead_caron  Pointer_EnableKeys  dead_macron     NoSymbol
414! called T1     ˆ               ˜               ˚               ˘               ˇ          (keypad-mouse mode)  ¯
415keycode 21 = dead_grave         NoSymbol        dead_diaeresis  U1FFE           NoSymbol        NoSymbol        NoSymbol        NoSymbol
416! called T2     `                               ¨               ῾ dasia (asper)
417keycode 35 = dead_acute         dead_cedilla    dead_stroke     U1FBF        dead_doubleacute   NoSymbol        dead_abovedot   NoSymbol
418! called T3     ´               ¸               /               ᾿ psili (lenis) ˝                               ˙
419
420
421
422!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
423! The first row (number Row)
424!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
425!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene4          Ebene4+Sh       Ebene6          Ebene7
426
427keycode 10 =    1               degree          onesuperior     onesubscript    ordfeminine     NoSymbol        notsign         NoSymbol
428!                               °               ¹               ₁               ª                               ¬
429keycode 11 =    2               section         twosuperior     twosubscript    masculine       NoSymbol        logicalor       NoSymbol
430!                               §               ²               ₂               º                               ∨
431keycode 12 =    3               U2113           threesuperior   threesubscript  numerosign      NoSymbol        logicaland      NoSymbol
432!                               ℓ liter         ³               ₃               №                               ∧
433keycode 13 =    4               guillemotright  U203A           dagger          Prior           Prior           downtack        NoSymbol
434!                               »               ›               †                                               ⊥ perpendicular
435keycode 14 =    5               guillemotleft   U2039           femalesymbol    periodcentered  NoSymbol        U2221           NoSymbol
436!                               «               ‹               ♀               ·                               ∡ angle sign
437keycode 15 =    6               EuroSign        cent            malesymbol      sterling        NoSymbol        U2225           NoSymbol
438!                               €               ¢               ♂               £                               ∥ parallel
439
440keycode 16 =    7               dollar          yen             Greek_kappa     currency        NoSymbol        rightarrow      NoSymbol
441!                               $               ¥               κ               ¤                               →
442keycode 17 =    8   doublelowquotemark    singlelowquotemark  leftanglebracket  NoSymbol        NoSymbol        infinity        NoSymbol
443!                               „               ‚               ⟨ (bra)                                         ∞
444keycode 18 =    9   leftdoublequotemark   leftsinglequotemark rightanglebracket KP_Divide       KP_Divide       containsas      NoSymbol
445!                               “               ‘               ⟩ (ket)         /               /               ∋
446keycode 19 =    0   rightdoublequotemark  rightsinglequotemark  zerosubscript   KP_Multiply     KP_Multiply     emptyset        NoSymbol
447!                       ”                       ’               ₀               *               *               ∅
448keycode 20 = minus              emdash          NoSymbol        U2011           KP_Subtract     KP_Subtract     hyphen          NoSymbol
449!               -               —                               ‑ non-breaking  -               -               ­ soft hyphen
450
451!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
452! The upper row
453!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
454!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene4          Ebene4+Sh       Ebene6          Ebene7
455
456keycode 24 =    x               X               ellipsis        Greek_xi        U22EE           NoSymbol        Greek_XI        Greek_XI
457!                                               …               ξ               ⋮                               Ξ               Ξ
458keycode 25 =    v               V               underscore      NoSymbol        BackSpace       BackSpace       U2259           NoSymbol
459!                                               _                                                               ≙               ≙
460keycode 26 =    l               L               bracketleft     Greek_lambda    Up              Up              Greek_LAMBDA    Greek_LAMBDA
461!                                               [               λ                                               Λ               Λ
462keycode 27 =    c               C               bracketright    Greek_chi       Delete          Delete          U2102           NoSymbol
463!                                               ]               χ                                               ℂ komplex
464keycode 28 =    w               W               asciicircum     Greek_omega     Insert          Insert          Greek_OMEGA     Greek_OMEGA
465!                                               ^               ω                                               Ω               Ω
466
467keycode 29 =    k               K               exclam          U03F0           exclamdown      NoSymbol        radical         NoSymbol
468!                                               !               ϰ Greek_kappa   ¡                               √
469keycode 30 =    h               H               less            Greek_psi       KP_7            KP_7            Greek_PSI       Greek_PSI
470!                                               <               ψ                                               Ψ               Ψ
471keycode 31 =    g               G               greater         Greek_gamma     KP_8            KP_8            Greek_GAMMA     Greek_GAMMA
472!                                               >               γ                                               Γ               Γ
473keycode 32 =    f               F               equal           Greek_phi       KP_9            KP_9            Greek_PHI       Greek_PHI
474!                                               =               φ                                               Φ               Φ
475keycode 33 =    q               Q               ampersand       U03D5           KP_Add          KP_Add          U211A           NoSymbol
476!                                               &               ϕ Greek_phi     +               +               ℚ rational
477keycode 34 = ssharp             U1E9E           U017F    Greek_finalsmallsigma  NoSymbol        NoSymbol        jot             NoSymbol
478!               ß               ẞ Capital ß     ſ long s        ς                                               ∘ ring operator
479
480!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
481! The home row (middle row)
482!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
483!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene4          Ebene4+Sh       Ebene6          Ebene7
484
485keycode 38 =    u               U               backslash       NoSymbol        Home            Home            U222E           NoSymbol
486!                                               \                                                               ∮ contour integral
487keycode 39 =    i               I               slash           Greek_iota      Left            Left            integral        NoSymbol
488!                                               /               ι                                               ∫
489keycode 40 =    a               A               braceleft       Greek_alpha     Down            Down            U2200           NoSymbol
490!                                               {               α                                               ∀ for all
491keycode 41 =    e               E               braceright      Greek_epsilon   Right           Right           U2203           NoSymbol
492!                                               }               ε                                               ∃ there exists
493keycode 42 =    o               O               asterisk        Greek_omicron   End             End             elementof       NoSymbol
494!                                               *               ο                                               ∈
495
496keycode 43 =    s               S               question        Greek_sigma     questiondown    NoSymbol        Greek_SIGMA     Greek_SIGMA
497!                                               ?               σ               ¿                               Σ               Σ
498keycode 44 =    n               N               parenleft       Greek_nu        KP_4            KP_4            U2115           NoSymbol
499!                                               (               ν                                               ℕ natural
500keycode 45 =    r               R               parenright      U03F1           KP_5            KP_5            U211D           NoSymbol
501!                                               )               ϱ Greek_rho                                     ℝ real
502keycode 46 =    t               T               minus           Greek_tau       KP_6            KP_6            partialderivative
503!                                               -               τ                                               ∂
504keycode 47 =    d               D               colon           Greek_delta     KP_Separator    NoSymbol        Greek_DELTA     Greek_DELTA
505!                                               :               δ               ,/.                             Δ               Δ
506keycode 48 =    y               Y               at              Greek_upsilon   KP_Decimal      NoSymbol        nabla           NoSymbol
507!                                               @               υ               ./,                             ∇
508
509!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
510! The lower row
511!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
512!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene4          Ebene4+Sh       Ebene6          Ebene7
513
514keycode 52 = udiaeresis         Udiaeresis      numbersign      NoSymbol        Escape          Escape          U211C           NoSymbol
515!               ü               Ü               #                                                               ℜ real part
516keycode 53 = odiaeresis         Odiaeresis      dollar          NoSymbol        Tab             ISO_Left_Tab    U2111           NoSymbol
517!               ö               Ö               $                                                               ℑ imaginary part
518keycode 54 = adiaeresis         Adiaeresis      bar             Greek_eta       Next            Next            U2135           NoSymbol
519!               ä               Ä               |               η                                               ℵ alef symbol
520keycode 55 =    p               P               asciitilde      Greek_pi        Return          Return          Greek_PI        Greek_PI
521!                                               ~               π                                               Π               Π
522keycode 56 =    z               Z               grave           Greek_zeta      Undo            Redo            U2124           NoSymbol
523!                                               `               ζ                                               ℤ integers
524
525keycode 57 =    b               B               plus            Greek_beta      colon           NoSymbol        U21D0           NoSymbol
526!                                               +               β               :                               ⇐
527keycode 58 =    m               M               percent         Greek_mu        KP_1            KP_1            ifonlyif        NoSymbol
528!                                               %               μ                                               ⇔
529keycode 59 = comma              endash          quotedbl        Greek_rho       KP_2            KP_2            U21D2           NoSymbol
530!               ,               –               "               ρ                                               ⇒ implies
531keycode 60 = period        enfilledcircbullet   apostrophe      U03D1           KP_3            KP_3            Greek_THETA     Greek_THETA
532!               .               •               '               ϑ Greek_theta                                   Θ
533keycode 61 =    j               J               semicolon       Greek_theta     semicolon       NoSymbol        variation       NoSymbol
534!                                               ;               θ               ;                               ∝ proportional to
535
536
537
538!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
539! Keypad
540!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
541!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
542! The uppest row
543!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
544!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene6          Ebene7
545
546keycode 77  = Tab               ISO_Left_Tab    equal           approxeq        identical       NoSymbol
547!                                               =               ≈ almost equal  ≡ identical to
548keysym KP_Divide = KP_Divide    KP_Divide       division        U2300           U2223           NoSymbol
549!               /               /               ÷               ⌀ diameter      ∣ divides
550keycode 63  = KP_Multiply       KP_Multiply     U22C5           U2299           U2297           NoSymbol
551!               *               *               ⋅ dot           ⊙ cirled dot    ⊗ circled times
552keycode 82  = KP_Subtract       KP_Subtract     U2212           U2296           U2238           NoSymbol
553!               -               -               − real minus    ⊖ cirled minus  ∸ dot minus
554
555!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
556! The upper row
557!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
558!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene6          Ebene7
559
560keycode 79 =  KP_7              U2714           U2195           U226A           upstile         NoSymbol
561!                               ✔ check mark    ↕ arrow         ≪ much less     ⌈
562keycode 80 =  KP_8              U2718           uparrow         intersection    U22C2           NoSymbol
563!                               ✘ ballot x      ↑               ∩               ⋂ n-ary intersection
564keycode 81 =  KP_9              NoSymbol        U20D7           U226B           U2309           NoSymbol
565!                                               vector          ≫ much greater  ⌉
566keycode 86 =  KP_Add            KP_Add          plusminus       U2295           U2214           NoSymbol
567!               +               +               ±               circled plus    dot plus
568
569!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
570! The middle row
571!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
572!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene6          Ebene7
573
574keycode 83 =  KP_4              club            leftarrow       includedin      U2286           NoSymbol
575!                               ♣               ←               ⊂               ⊆
576keycode 84 =  KP_5              EuroSign        brokenbar       U22B6           U22B7           NoSymbol
577!                               €               ¦               ⊶ original of   ⊷ image of
578keycode 85 =  KP_6              U2023           rightarrow      includes        U2287           NoSymbol
579!                               ‣               →               ⊃               ⊇
580
581!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
582! The lower row
583!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
584!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene6          Ebene7
585
586keycode 87 =  KP_1              diamond         U2194           lessthanequal   downstile       NoSymbol
587!                               ♦               ↔ arrow         ≤               ⌊
588keycode 88 =  KP_2              heart           downarrow       union           U22C3           NoSymbol
589!                               ♥               ↓               ∪               ⋃ n-ary union
590keycode 89 =  KP_3              U2660           U21CC         greaterthanequal  U230B           NoSymbol
591!                               ♠               ⇌               ≥               ⌋
592! keycode 108 = KP_Enter        KP_Enter        KP_Enter        KP_Enter        KP_Enter        KP_Enter
593!                                                               
594
595
596!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
597! The lowest row
598!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
599!            Ebene1             Ebene2          Ebene3          Ebene5          Ebene6          Ebene7
600
601keycode 90 = KP_0               U2423           percent         U2030           U25A1           NoSymbol
602!                               ␣ space sign    %               ‰ per mille     □ white square
603keycode 91 = comma              period          KP_Separator    minutes         seconds         NoSymbol
604!               ,               .               ,/.             ′ min,feets     ″ sec,inches
605
606
607
608
609!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
610! Bemerkungen
611!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
612! 1.) Ebene 6 (hier: der 7. Eintrag) erreicht man über ISO_Group_Shift+ISO_Group_Shift
613!     (bzw. mode_switch+mode_switch) und über keine andere mir bekannte Kombination. Insbesondere legt
614!     ISO_Level3_Shift Level3 (Ebene 4, hier: Eintrag 5) fest, verschiebt also nicht. Darum kann man
615!     ISO_Level3_Shift nur mit Shift sinnvoll kombinieren. Daraus resultiert, dass Ebene 6 nur über
616!     Mod3+Mod4 (in dieser Reihenfolge!) erreicht werden kann.
617!
618! 2.) Die KP_-Einträge ermöglichen die Steuerung des Mauscursors mit der Tastatur.
619!     Hierzu wird mittels Mod4+ß dieser Betriebsmodus ein- und später wieder ausgeschaltet.
620!     Die Steuerung des Cursors kann über den Ziffernblock (Ebene 4, eventuell mit
621!     eingerastetem Mod4) erfolgen.
622#neo: xmodmap --- Ende
623#neo: console --- Beginn
624! neo.map - german NEO keyboard layout
625! 2008 Pascal Hauck, <pascal.hauck@web.de>
626!
627! Diese Datei ist experimentell!
628! Sollten Fehler auftreten oder sich verschiedene Linux-Distributionen
629! anders verhalten als erwartet, sollte dies auf der Mailingliste
630! der NEO-Tastaturbelegung gemeldet werden.
631!
632! Diese Keymap wird über einige Skripte automatisch aus der neo_de.xmodmap
633! erzeugt.
634!
635
636keymaps 0-18
637strings as usual
638compose as usual
639! --------------------------------------------------------------------------
640! Modifier definitions
641! --------------------------------------------------------------------------
642                   keycode  42 = Shift           
643#          shift   keycode  42 = Caps_Lock       
644                   keycode  54 = Shift           
645#          shift   keycode  54 = Caps_Lock       
646                   keycode  58 = AltGr           
647#          altgr   keycode  58 = AltGr_Lock     
648                   keycode  43 = AltGr           
649#          altgr   keycode  43 = AltGr_Lock     
650                   keycode  86 = ShiftL         
651#          shiftl  keycode  86 = ShiftL_Lock     
652                   keycode 100 = ShiftL         
653#          shiftl  keycode 100 = ShiftL_Lock     
654
655                   keycode   1 = Escape           Escape          Escape          Escape         
656           shiftl  keycode  57 = Escape           
657   shift   shiftl  keycode  57 = Escape           
658   altgr   shiftl  keycode  57 = Escape           
659           alt     keycode   1 = Meta_Escape     
660   shift   altgr   keycode   1 = Meta_Escape     
661
662! --------------------------------------------------------------------------
663! function keys
664! --------------------------------------------------------------------------
665! ----Backspace-------------------------------------------------------------
666                   keycode  14 = Delete           Delete         
667           alt     keycode  14 = Meta_Delete     
668   shift   alt     keycode  14 = Meta_Delete     
669! ----Return Enter----------------------------------------------------------
670                   keycode  28 = Return         
671           alt     keycode  28 = Meta_Control_m 
672                   keycode  96 = KP_Enter       
673           altgr   keycode  96 = Hex_F           
674! ----Tab-------------------------------------------------------------------
675                   keycode  15 = Tab              Meta_Tab       
676           alt     keycode  15 = Meta_Tab       
677           altgr   keycode  15 = Compose
678! ----Control Alt-----------------------------------------------------------
679                   keycode  29 = Control         
680                   keycode  97 = Control         
681                   keycode  56 = Alt             
682! ----Prt SclLk Pause-------------------------------------------------------
683                   keycode  99 =
684           control keycode  99 = Control_backslash
685           alt     keycode  99 = Control_backslash
686   control alt     keycode  99 = Meta_Control_backslash
687                   keycode  70 = Scroll_Lock      Show_Memory      Show_Registers   Show_State     
688           alt     keycode  70 = Scroll_Lock     
689                   keycode 119 = Pause           
690! ----Home block------------------------------------------------------------
691                   keycode 102 = Find           
692                   keycode 104 = Prior           
693           shift   keycode 104 = Scroll_Backward
694                   keycode 107 = Select         
695                   keycode 109 = Next           
696           shift   keycode 109 = Scroll_Forward 
697                   keycode 111 = Remove         
698   altgr   control keycode 111 = Boot           
699   control alt     keycode 111 = Boot           
700                   keycode 110 = Insert         
701! ----Navigation block------------------------------------------------------
702                   keycode 103 = Up             
703           alt     keycode 103 = KeyboardSignal 
704                   keycode 105 = Left           
705           alt     keycode 105 = Decr_Console   
706                   keycode 106 = Right           
707           alt     keycode 106 = Incr_Console   
708                   keycode 108 = Down           
709! ----Win keys--------------------------------------------------------------
710                   keycode 125 = Decr_Console    Last_Console      Incr_Console     
711                   keycode 126 = Incr_Console    Last_Console      Decr_Console     
712! ----menue key-------------------------------------------------------------
713                   keycode 127 = Compose         F100
714! ----F-keys----------------------------------------------------------------
715                   keycode  59 = F1               F13              Console_13       F25             
716           alt     keycode  59 = Console_1       
717   control alt     keycode  59 = Console_1       
718                   keycode  60 = F2               F14              Console_14       F26             
719           alt     keycode  60 = Console_2       
720   control alt     keycode  60 = Console_2       
721                   keycode  61 = F3               F15              Console_15       F27             
722           alt     keycode  61 = Console_3       
723   control alt     keycode  61 = Console_3       
724                   keycode  62 = F4               F16              Console_16       F28             
725           alt     keycode  62 = Console_4       
726   control alt     keycode  62 = Console_4       
727                   keycode  63 = F5               F17              Console_17       F29             
728           alt     keycode  63 = Console_5       
729   control alt     keycode  63 = Console_5       
730                   keycode  64 = F6               F18              Console_18       F30             
731           alt     keycode  64 = Console_6       
732   control alt     keycode  64 = Console_6       
733                   keycode  65 = F7               F19              Console_19       F31             
734           alt     keycode  65 = Console_7       
735   control alt     keycode  65 = Console_7       
736                   keycode  66 = F8               F20              Console_20       F32             
737           alt     keycode  66 = Console_8       
738   control alt     keycode  66 = Console_8       
739                   keycode  67 = F9               F21              Console_21       F33             
740           alt     keycode  67 = Console_9       
741   control alt     keycode  67 = Console_9       
742                   keycode  68 = F10              F22              Console_22       F34             
743           alt     keycode  68 = Console_10     
744   control alt     keycode  68 = Console_10     
745                   keycode  87 = F11              F23              Console_23       F35             
746           alt     keycode  87 = Console_11     
747   control alt     keycode  87 = Console_11     
748                   keycode  88 = F12              F24              Console_24       F36             
749           alt     keycode  88 = Console_12     
750   control alt     keycode  88 = Console_12     
751! ----unknown keys from defkeymap.map---------------------------------------
752                   keycode  84 = Last_Console   
753                   keycode  89 =
754                   keycode  90 =
755                   keycode  91 =
756                   keycode  92 =
757                   keycode  93 =
758                   keycode  94 =
759                   keycode  95 =
760                   keycode 101 = Break           
761                   keycode 112 = Macro           
762   altgr   control keycode 112 = VoidSymbol     
763   shift   alt     keycode 112 = VoidSymbol     
764   altgr   alt     keycode 112 = VoidSymbol     
765                   keycode 113 = F13             
766   altgr   control keycode 113 = VoidSymbol     
767   shift   alt     keycode 113 = VoidSymbol     
768   altgr   alt     keycode 113 = VoidSymbol     
769                   keycode 114 = F14             
770   altgr   control keycode 114 = VoidSymbol     
771   shift   alt     keycode 114 = VoidSymbol     
772   altgr   alt     keycode 114 = VoidSymbol     
773                   keycode 115 = Help           
774   altgr   control keycode 115 = VoidSymbol     
775   shift   alt     keycode 115 = VoidSymbol     
776   altgr   alt     keycode 115 = VoidSymbol     
777                   keycode 116 = Do             
778   altgr   control keycode 116 = VoidSymbol     
779   shift   alt     keycode 116 = VoidSymbol     
780   altgr   alt     keycode 116 = VoidSymbol     
781                   keycode 117 = F17             
782   altgr   control keycode 117 = VoidSymbol     
783   shift   alt     keycode 117 = VoidSymbol     
784   altgr   alt     keycode 117 = VoidSymbol     
785                   keycode 118 = KP_MinPlus     
786   altgr   control keycode 118 = VoidSymbol     
787   shift   alt     keycode 118 = VoidSymbol     
788   altgr   alt     keycode 118 = VoidSymbol     
789                   keycode 119 = Pause
790                   keycode 120 =
791                   keycode 121 =
792                   keycode 122 =
793                   keycode 123 =
794                   keycode 124 =
795
796
797! ----Space key-------------------------------------------------------------
798                   keycode  57 = space                 space                 space                 nobreakspace         
799           shiftl  keycode  57 = KP_0                 
800   shift   shiftl  keycode  57 = KP_0                 
801   altgr   shiftl  keycode  57 = U+202F               
802
803! ----dead keys-------------------------------------------------------------
804                   keycode  41 = dead_circumflex       dead_caron            dead_breve            VoidSymbol           
805           shiftl  keycode  41 = VoidSymbol           
806   shift   shiftl  keycode  41 = VoidSymbol           
807   altgr   shiftl  keycode  41 = VoidSymbol           
808                   keycode  13 = dead_acute            dead_grave            dead_cedilla          VoidSymbol           
809           shiftl  keycode  13 = U+0307               
810   shift   shiftl  keycode  13 = VoidSymbol           
811   altgr   shiftl  keycode  13 = U+030a               
812                   keycode  27 = dead_tilde            U+0304                dead_diaeresis        VoidSymbol           
813           shiftl  keycode  27 = dead_doubleacute     
814   shift   shiftl  keycode  27 = VoidSymbol           
815   altgr   shiftl  keycode  27 = VoidSymbol           
816
817! --------------------------------------------------------------------------
818! Row 1 (number row)
819! --------------------------------------------------------------------------
820                   keycode   2 = one                   degree                onesuperior           U+2081               
821           shiftl  keycode   2 = U+2022               
822   shift   shiftl  keycode   2 = VoidSymbol           
823   altgr   shiftl  keycode   2 = notsign               
824                   keycode   3 = two                   U+2116                twosuperior           U+2082               
825           shiftl  keycode   3 = U+2023               
826   shift   shiftl  keycode   3 = VoidSymbol           
827   altgr   shiftl  keycode   3 = U+2228               
828                   keycode   4 = three                 section               threesuperior         U+2083               
829           shiftl  keycode   4 = VoidSymbol           
830   shift   shiftl  keycode   4 = VoidSymbol           
831   altgr   shiftl  keycode   4 = U+2227               
832                   keycode   5 = four                  guillemotright        U+203A                U+2113               
833           shiftl  keycode   5 = Prior                 
834   shift   shiftl  keycode   5 = Prior                 
835   altgr   shiftl  keycode   5 = U+22a4               
836                   keycode   6 = five                  guillemotleft         U+2039                U+2640               
837           shiftl  keycode   6 = VoidSymbol           
838   shift   shiftl  keycode   6 = VoidSymbol           
839   altgr   shiftl  keycode   6 = U+2221               
840                   keycode   7 = six                   U+20ac                cent                  U+2642               
841           shiftl  keycode   7 = sterling             
842   shift   shiftl  keycode   7 = VoidSymbol           
843   altgr   shiftl  keycode   7 = U+2225               
844                   keycode   8 = seven                 dollar                yen                   U+03ba               
845           shiftl  keycode   8 = currency             
846   shift   shiftl  keycode   8 = VoidSymbol           
847   altgr   shiftl  keycode   8 = U+21C8               
848                   keycode   9 = eight                 U+201e                U+201a                U+2329               
849           shiftl  keycode   9 = KP_Divide             
850   shift   shiftl  keycode   9 = KP_Divide             
851   altgr   shiftl  keycode   9 = U+21C5               
852                   keycode  10 = nine                  U+201c                U+2018                U+232a               
853           shiftl  keycode  10 = KP_Multiply           
854   shift   shiftl  keycode  10 = KP_Multiply           
855   altgr   shiftl  keycode  10 = U+220B               
856                   keycode  11 = zero                  U+201d                U+2019                U+2080               
857           shiftl  keycode  11 = KP_Subtract           
858   shift   shiftl  keycode  11 = KP_Subtract           
859   altgr   shiftl  keycode  11 = U+2205               
860                   keycode  12 = minus                 U+2013                U+2014                U+2011               
861           shiftl  keycode  12 = VoidSymbol           
862   shift   shiftl  keycode  12 = VoidSymbol           
863   altgr   shiftl  keycode  12 = hyphen               
864
865! --------------------------------------------------------------------------
866! Row 2 (upper row)
867! --------------------------------------------------------------------------
868                   keycode  16 = x                     X                     U+2026                U+03be               
869           shiftl  keycode  16 = U+22EE               
870   shift   shiftl  keycode  16 = VoidSymbol           
871   altgr   shiftl  keycode  16 = U+039E               
872           control keycode  16 = Control_x                     
873   shift   control keycode  16 = Control_x                     
874           alt     keycode  16 = Meta_x                     
875   shift   alt     keycode  16 = Meta_X                     
876   control alt     keycode  16 = Meta_Control_x                     
877                   keycode  17 = v                     V                     underscore            VoidSymbol           
878           shiftl  keycode  17 = BackSpace             
879   shift   shiftl  keycode  17 = BackSpace             
880   altgr   shiftl  keycode  17 = U+2259               
881           control keycode  17 = Control_v                     
882   shift   control keycode  17 = Control_v                     
883           alt     keycode  17 = Meta_v                     
884   shift   alt     keycode  17 = Meta_V                     
885   control alt     keycode  17 = Meta_Control_v                     
886                   keycode  18 = l                     L                     bracketleft           U+03bb               
887           shiftl  keycode  18 = Up                   
888   shift   shiftl  keycode  18 = Up                   
889   altgr   shiftl  keycode  18 = U+039B               
890           control keycode  18 = Control_l                     
891   shift   control keycode  18 = Control_l                     
892           alt     keycode  18 = Meta_l                     
893   shift   alt     keycode  18 = Meta_L                     
894   control alt     keycode  18 = Meta_Control_l                     
895                   keycode  19 = c                     C                     bracketright          U+03c7               
896           shiftl  keycode  19 = Remove               
897   shift   shiftl  keycode  19 = Remove               
898   altgr   shiftl  keycode  19 = U+2102               
899           control keycode  19 = Control_c                     
900   shift   control keycode  19 = Control_c                     
901           alt     keycode  19 = Meta_c                     
902   shift   alt     keycode  19 = Meta_C                     
903   control alt     keycode  19 = Meta_Control_c                     
904                   keycode  20 = w                     W                     asciicircum           U+03c9               
905           shiftl  keycode  20 = Insert               
906   shift   shiftl  keycode  20 = Insert               
907   altgr   shiftl  keycode  20 = U+03A9               
908           control keycode  20 = Control_w                     
909   shift   control keycode  20 = Control_w                     
910           alt     keycode  20 = Meta_w                     
911   shift   alt     keycode  20 = Meta_W                     
912   control alt     keycode  20 = Meta_Control_w                     
913                   keycode  21 = k                     K                     exclam                U+03F0               
914           shiftl  keycode  21 = exclamdown           
915   shift   shiftl  keycode  21 = VoidSymbol           
916   altgr   shiftl  keycode  21 = U+221a               
917           control keycode  21 = Control_k                     
918   shift   control keycode  21 = Control_k                     
919           alt     keycode  21 = Meta_k                     
920   shift   alt     keycode  21 = Meta_K                     
921   control alt     keycode  21 = Meta_Control_k                     
922                   keycode  22 = h                     H                     less                  U+03c8               
923           shiftl  keycode  22 = KP_7                 
924   shift   shiftl  keycode  22 = KP_7                 
925   altgr   shiftl  keycode  22 = U+03A8               
926           control keycode  22 = Control_h                     
927   shift   control keycode  22 = Control_h                     
928           alt     keycode  22 = Meta_h                     
929   shift   alt     keycode  22 = Meta_H                     
930   control alt     keycode  22 = Meta_Control_h                     
931                   keycode  23 = g                     G                     greater               U+03b3               
932           shiftl  keycode  23 = KP_8                 
933   shift   shiftl  keycode  23 = KP_8                 
934   altgr   shiftl  keycode  23 = U+0393               
935           control keycode  23 = Control_g                     
936   shift   control keycode  23 = Control_g                     
937           alt     keycode  23 = Meta_g                     
938   shift   alt     keycode  23 = Meta_G                     
939   control alt     keycode  23 = Meta_Control_g                     
940                   keycode  24 = f                     F                     equal                 U+03c6               
941           shiftl  keycode  24 = KP_9                 
942   shift   shiftl  keycode  24 = KP_9                 
943   altgr   shiftl  keycode  24 = U+03A6               
944           control keycode  24 = Control_f                     
945   shift   control keycode  24 = Control_f                     
946           alt     keycode  24 = Meta_f                     
947   shift   alt     keycode  24 = Meta_F                     
948   control alt     keycode  24 = Meta_Control_f                     
949                   keycode  25 = q                     Q                     ampersand             U+03D5               
950           shiftl  keycode  25 = KP_Add               
951   shift   shiftl  keycode  25 = KP_Add               
952   altgr   shiftl  keycode  25 = U+211A               
953           control keycode  25 = Control_q                     
954   shift   control keycode  25 = Control_q                     
955           alt     keycode  25 = Meta_q                     
956   shift   alt     keycode  25 = Meta_Q                     
957   control alt     keycode  25 = Meta_Control_q                     
958                   keycode  26 = ssharp                U+1E9E                U+017F                U+03c2               
959           shiftl  keycode  26 = VoidSymbol           
960   shift   shiftl  keycode  26 = VoidSymbol           
961   altgr   shiftl  keycode  26 = U+2218               
962
963! --------------------------------------------------------------------------
964! Row 3 (home row, middle row)
965! --------------------------------------------------------------------------
966                   keycode  30 = u                     U                     backslash             VoidSymbol           
967           shiftl  keycode  30 = Home                 
968   shift   shiftl  keycode  30 = Home                 
969   altgr   shiftl  keycode  30 = U+222E               
970           control keycode  30 = Control_u                     
971   shift   control keycode  30 = Control_u                     
972           alt     keycode  30 = Meta_u                     
973   shift   alt     keycode  30 = Meta_U                     
974   control alt     keycode  30 = Meta_Control_u                     
975                   keycode  31 = i                     I                     slash                 U+03b9               
976           shiftl  keycode  31 = Left                 
977   shift   shiftl  keycode  31 = Left                 
978   altgr   shiftl  keycode  31 = U+222b               
979           control keycode  31 = Control_i                     
980   shift   control keycode  31 = Control_i                     
981           alt     keycode  31 = Meta_i                     
982   shift   alt     keycode  31 = Meta_I                     
983   control alt     keycode  31 = Meta_Control_i                     
984                   keycode  32 = a                     A                     braceleft             U+03b1               
985           shiftl  keycode  32 = Down                 
986   shift   shiftl  keycode  32 = Down                 
987   altgr   shiftl  keycode  32 = U+2200               
988           control keycode  32 = Control_a                     
989   shift   control keycode  32 = Control_a                     
990           alt     keycode  32 = Meta_a                     
991   shift   alt     keycode  32 = Meta_A                     
992   control alt     keycode  32 = Meta_Control_a                     
993                   keycode  33 = e                     E                     braceright            U+03b5               
994           shiftl  keycode  33 = Right                 
995   shift   shiftl  keycode  33 = Right                 
996   altgr   shiftl  keycode  33 = U+2203               
997           control keycode  33 = Control_e                     
998   shift   control keycode  33 = Control_e                     
999           alt     keycode  33 = Meta_e                     
1000   shift   alt     keycode  33 = Meta_E                     
1001   control alt     keycode  33 = Meta_Control_e                     
1002                   keycode  34 = o                     O                     asterisk              U+03bf               
1003           shiftl  keycode  34 = End                   
1004   shift   shiftl  keycode  34 = End                   
1005   altgr   shiftl  keycode  34 = U+2208               
1006           control keycode  34 = Control_o                     
1007   shift   control keycode  34 = Control_o                     
1008           alt     keycode  34 = Meta_o                     
1009   shift   alt     keycode  34 = Meta_O                     
1010   control alt     keycode  34 = Meta_Control_o                     
1011                   keycode  35 = s                     S                     question              U+03c3               
1012           shiftl  keycode  35 = questiondown         
1013   shift   shiftl  keycode  35 = VoidSymbol           
1014   altgr   shiftl  keycode  35 = U+03A3               
1015           control keycode  35 = Control_s                     
1016   shift   control keycode  35 = Control_s                     
1017           alt     keycode  35 = Meta_s                     
1018   shift   alt     keycode  35 = Meta_S                     
1019   control alt     keycode  35 = Meta_Control_s                     
1020                   keycode  36 = n                     N                     parenleft             U+03bd               
1021           shiftl  keycode  36 = KP_4                 
1022   shift   shiftl  keycode  36 = KP_4                 
1023   altgr   shiftl  keycode  36 = U+2115               
1024           control keycode  36 = Control_n                     
1025   shift   control keycode  36 = Control_n                     
1026           alt     keycode  36 = Meta_n                     
1027   shift   alt     keycode  36 = Meta_N                     
1028   control alt     keycode  36 = Meta_Control_n                     
1029                   keycode  37 = r                     R                     parenright            U+03F1               
1030           shiftl  keycode  37 = KP_5                 
1031   shift   shiftl  keycode  37 = KP_5                 
1032   altgr   shiftl  keycode  37 = U+211D               
1033           control keycode  37 = Control_r                     
1034   shift   control keycode  37 = Control_r                     
1035           alt     keycode  37 = Meta_r                     
1036   shift   alt     keycode  37 = Meta_R                     
1037   control alt     keycode  37 = Meta_Control_r                     
1038                   keycode  38 = t                     T                     minus                 U+03c4               
1039           shiftl  keycode  38 = KP_6                 
1040   shift   shiftl  keycode  38 = KP_6                 
1041   altgr   shiftl  keycode  38 = U+2202               
1042           control keycode  38 = Control_t                     
1043   shift   control keycode  38 = Control_t                     
1044           alt     keycode  38 = Meta_t                     
1045   shift   alt     keycode  38 = Meta_T                     
1046   control alt     keycode  38 = Meta_Control_t                     
1047                   keycode  39 = d                     D                     colon                 U+03b4               
1048           shiftl  keycode  39 = comma                 
1049   shift   shiftl  keycode  39 = VoidSymbol           
1050   altgr   shiftl  keycode  39 = U+0394               
1051           control keycode  39 = Control_d                     
1052   shift   control keycode  39 = Control_d                     
1053           alt     keycode  39 = Meta_d                     
1054   shift   alt     keycode  39 = Meta_D                     
1055   control alt     keycode  39 = Meta_Control_d                     
1056                   keycode  40 = y                     Y                     at                    U+03c5               
1057           shiftl  keycode  40 = period               
1058   shift   shiftl  keycode  40 = VoidSymbol           
1059   altgr   shiftl  keycode  40 = U+2207               
1060           control keycode  40 = Control_y                     
1061   shift   control keycode  40 = Control_y                     
1062           alt     keycode  40 = Meta_y                     
1063   shift   alt     keycode  40 = Meta_Y                     
1064   control alt     keycode  40 = Meta_Control_y                     
1065
1066! --------------------------------------------------------------------------
1067! Row 4 (lower row)
1068! --------------------------------------------------------------------------
1069                   keycode  44 = udiaeresis            Udiaeresis            numbersign            VoidSymbol           
1070           shiftl  keycode  44 = Escape               
1071   shift   shiftl  keycode  44 = Escape               
1072   altgr   shiftl  keycode  44 = U+211C               
1073                   keycode  45 = odiaeresis            Odiaeresis            dollar                VoidSymbol           
1074           shiftl  keycode  45 = Tab                   
1075   shift   shiftl  keycode  45 = Meta_Tab             
1076   altgr   shiftl  keycode  45 = U+2111               
1077                   keycode  46 = adiaeresis            Adiaeresis            bar                   U+03b7               
1078           shiftl  keycode  46 = Next                 
1079   shift   shiftl  keycode  46 = Next                 
1080   altgr   shiftl  keycode  46 = U+2135               
1081                   keycode  47 = p                     P                     asciitilde            U+03c0               
1082           shiftl  keycode  47 = Return               
1083   shift   shiftl  keycode  47 = Return               
1084   altgr   shiftl  keycode  47 = U+03A0               
1085           control keycode  47 = Control_p                     
1086   shift   control keycode  47 = Control_p                     
1087           alt     keycode  47 = Meta_p                     
1088   shift   alt     keycode  47 = Meta_P                     
1089   control alt     keycode  47 = Meta_Control_p                     
1090                   keycode  48 = z                     Z                     grave                 U+03b6               
1091           shiftl  keycode  48 = VoidSymbol           
1092   shift   shiftl  keycode  48 = VoidSymbol           
1093   altgr   shiftl  keycode  48 = U+2124               
1094           control keycode  48 = Control_z                     
1095   shift   control keycode  48 = Control_z                     
1096           alt     keycode  48 = Meta_z                     
1097   shift   alt     keycode  48 = Meta_Z                     
1098   control alt     keycode  48 = Meta_Control_z                     
1099                   keycode  49 = b                     B                     plus                  U+03b2               
1100           shiftl  keycode  49 = colon                 
1101   shift   shiftl  keycode  49 = VoidSymbol           
1102   altgr   shiftl  keycode  49 = U+21D0               
1103           control keycode  49 = Control_b                     
1104   shift   control keycode  49 = Control_b                     
1105           alt     keycode  49 = Meta_b                     
1106   shift   alt     keycode  49 = Meta_B                     
1107   control alt     keycode  49 = Meta_Control_b                     
1108                   keycode  50 = m                     M                     percent               U+03bc               
1109           shiftl  keycode  50 = KP_1                 
1110   shift   shiftl  keycode  50 = KP_1                 
1111   altgr   shiftl  keycode  50 = U+21d4               
1112           control keycode  50 = Control_m                     
1113   shift   control keycode  50 = Control_m                     
1114           alt     keycode  50 = Meta_m                     
1115   shift   alt     keycode  50 = Meta_M                     
1116   control alt     keycode  50 = Meta_Control_m                     
1117                   keycode  51 = comma                 VoidSymbol            quotedbl              U+03c1               
1118           shiftl  keycode  51 = KP_2                 
1119   shift   shiftl  keycode  51 = KP_2                 
1120   altgr   shiftl  keycode  51 = U+21D2               
1121                   keycode  52 = period                VoidSymbol            apostrophe            U+03D1               
1122           shiftl  keycode  52 = KP_3                 
1123   shift   shiftl  keycode  52 = KP_3                 
1124   altgr   shiftl  keycode  52 = U+0398               
1125                   keycode  53 = j                     J                     semicolon             U+03b8               
1126           shiftl  keycode  53 = semicolon             
1127   shift   shiftl  keycode  53 = VoidSymbol           
1128   altgr   shiftl  keycode  53 = U+221d               
1129           control keycode  53 = Control_j                     
1130   shift   control keycode  53 = Control_j                     
1131           alt     keycode  53 = Meta_j                     
1132   shift   alt     keycode  53 = Meta_J                     
1133   control alt     keycode  53 = Meta_Control_j                     
1134
1135! --------------------------------------------------------------------------
1136! Keypad Row 1 (uppest row)
1137! --------------------------------------------------------------------------
1138                   keycode  69 = Tab                   Meta_Tab              equal                 U+2248               
1139           shiftl  keycode  69 = U+2260               
1140   shift   shiftl  keycode  69 = VoidSymbol           
1141   altgr   shiftl  keycode  69 = U+2261               
1142                   keycode  98 = KP_Divide             KP_Divide             division              U+2223               
1143           shiftl  keycode  98 = U+2300               
1144   shift   shiftl  keycode  98 = VoidSymbol           
1145   altgr   shiftl  keycode  98 = U+2044               
1146                   keycode  55 = KP_Multiply           KP_Multiply           U+22C5                multiply             
1147           shiftl  keycode  55 = U+2299               
1148   shift   shiftl  keycode  55 = VoidSymbol           
1149   altgr   shiftl  keycode  55 = U+2297               
1150                   keycode  74 = KP_Subtract           KP_Subtract           U+2212                U+2216               
1151           shiftl  keycode  74 = U+2296               
1152   shift   shiftl  keycode  74 = VoidSymbol           
1153   altgr   shiftl  keycode  74 = U+2238               
1154
1155! --------------------------------------------------------------------------
1156! Keypad Row 2 (upper row)
1157! --------------------------------------------------------------------------
1158                   keycode  71 = KP_7                  U+2714                U+2195                U+230a               
1159           shiftl  keycode  71 = Home                 
1160   shift   shiftl  keycode  71 = Home                 
1161   altgr   shiftl  keycode  71 = U+2308               
1162                   keycode  72 = KP_8                  U+2718                U+2191                U+2229               
1163           shiftl  keycode  72 = Up                   
1164   shift   shiftl  keycode  72 = Up                   
1165   altgr   shiftl  keycode  72 = U+22C2               
1166                   keycode  73 = KP_9                  U+2020                U+20D7                U+230B               
1167           shiftl  keycode  73 = Prior                 
1168   shift   shiftl  keycode  73 = Prior                 
1169   altgr   shiftl  keycode  73 = U+2309               
1170                   keycode  78 = KP_Add                KP_Add                plusminus             U+2213               
1171           shiftl  keycode  78 = U+2295               
1172   shift   shiftl  keycode  78 = VoidSymbol           
1173   altgr   shiftl  keycode  78 = U+2214               
1174
1175! --------------------------------------------------------------------------
1176! Keypad Row 3 (home row, middle row)
1177! --------------------------------------------------------------------------
1178                   keycode  75 = KP_4                  U+2663                U+2190                U+2282               
1179           shiftl  keycode  75 = Left                 
1180   shift   shiftl  keycode  75 = Left                 
1181   altgr   shiftl  keycode  75 = U+2286               
1182                   keycode  76 = KP_5                  U+20ac                U+221e                U+22B6               
1183           shiftl  keycode  76 = VoidSymbol           
1184   shift   shiftl  keycode  76 = VoidSymbol           
1185   altgr   shiftl  keycode  76 = U+22B7               
1186                   keycode  77 = KP_6                  brokenbar             U+2192                U+2283               
1187           shiftl  keycode  77 = Right                 
1188   shift   shiftl  keycode  77 = Right                 
1189   altgr   shiftl  keycode  77 = U+2287               
1190
1191! --------------------------------------------------------------------------
1192! Keypad Row 4 (lower row)
1193! --------------------------------------------------------------------------
1194                   keycode  79 = KP_1                  U+2666                U+2194                U+226A               
1195           shiftl  keycode  79 = End                   
1196   shift   shiftl  keycode  79 = End                   
1197   altgr   shiftl  keycode  79 = U+2264               
1198                   keycode  80 = KP_2                  U+2665                U+2193                U+222a               
1199           shiftl  keycode  80 = Down                 
1200   shift   shiftl  keycode  80 = Down                 
1201   altgr   shiftl  keycode  80 = U+22C3               
1202                   keycode  81 = KP_3                  U+2660                U+21CC                U+226B               
1203           shiftl  keycode  81 = Next                 
1204   shift   shiftl  keycode  81 = Next                 
1205   altgr   shiftl  keycode  81 = U+2265               
1206
1207! --------------------------------------------------------------------------
1208! Keypad Row 5 (lowest row)
1209! --------------------------------------------------------------------------
1210                   keycode  82 = KP_0                  U+2423                percent               U+2030               
1211           shiftl  keycode  82 = Insert               
1212   shift   shiftl  keycode  82 = Insert               
1213   altgr   shiftl  keycode  82 = U+25A1               
1214                   keycode  83 = comma                 period                U+002c                U+2032               
1215           shiftl  keycode  83 = Remove               
1216   shift   shiftl  keycode  83 = Remove               
1217   altgr   shiftl  keycode  83 = U+2033               
1218
1219
1220! --------------------------------------------------------------------------
1221! additional Keys with control function (has to be edited manually!!!!)
1222! --------------------------------------------------------------------------
1223   control altgr   keycode  30 = Control_backslash
1224   alt     altgr   keycode  30 = Control_backslash
1225   control alt altgr keycode  30 = Meta_Control_backslash
1226   control altgr   keycode  19 = Control_bracketright
1227   alt     altgr   keycode  19 = Control_bracketright
1228   control alt altgr keycode  19 = Meta_Control_bracketright
1229   control altgr   keycode  17 = Control_underscore
1230   alt     altgr   keycode  17 = Control_underscore
1231   control alt altgr keycode  17 = Meta_Control_underscore
1232   control altgr   keycode  20 = Control_asciicircum
1233   alt     altgr   keycode  20 = Control_asciicircum
1234   control alt altgr keycode  20 = Meta_Control_asciicircum
1235
1236
1237! --------------------------------------------------------------------------
1238! Strings and Compose
1239! --------------------------------------------------------------------------
1240# string F100 = "setleds +num\n"
1241#neo: console --- Ende
1242#neo: asdf --- Beginn
1243#!/bin/sh
1244# Copyright 2008 Bernd Steinhauser <berniyh@exherbo.org>
1245# Copyright 2008 Benjamin Kellermann
1246# Copyright 2008 Pascal Hauck
1247# Copyright 2008 Erik Streb del Toro
1248# Distributed under the terms of the GNU General Public License v3
1249
1250if [ -f "${NEO_CONFIG}" ]; then
1251        . "${NEO_CONFIG}" || die "Failed to source ${NEO_CONFIG}"
1252elif [ -f "${HOME}"/.neorc ]; then
1253        . "${HOME}"/.neorc || die "Failed to source ${HOME}/.neorc"
1254elif [ -f /etc/neo.conf ]; then
1255        . /etc/neo.conf || die "Failed to source /etc/neo.conf"
1256else
1257        echo "No configuration file found. Using default values, this might fail!"
1258fi
1259
1260# Default paths
1261PATH_XMODMAP=${PATH_XMODMAP:-/usr/bin/xmodmap}
1262PATH_SETXKBMAP=${PATH_SETXKBMAP:-/usr/bin/setxkbmap}
1263PATH_LOADKEYS=${PATH_LOADKEYS:-/usr/bin/loadkeys}
1264PATH_SUDO=${PATH_SUDO:-/usr/bin/sudo}
1265PATH_SETLEDS=${PATH_SETLEDS:-/usr/bin/setleds}
1266PATH_NUMLOCKX=${PATH_NUMLOCKX:-/usr/bin/numlockx}
1267PATH_XSET=${PATH_XSET:-/usr/bin/xset}
1268
1269# Default values
1270NEO_X_VARIANTE=${NEO_X_VARIANTE:-xkbmap}
1271NEO_X_VARIANTE=${1-$NEO_X_VARIANTE}
1272NEO_XKBMAP=${NEO_XKBMAP:-de}
1273NEO_XKBVARIANT=${NEO_XKBVARIANT:-neo}
1274NEO_XMODMAP=${NEO_XMODMAP:-$HOME/neo/neo_de.xmodmap}
1275NEO_XMODMAP_XPROG=${NEO_XMODMAP_XPROG:-$HOME/neo/neo_de_x-prog.xmodmap}
1276NEO_XMODMAP_ALTERNATIVE=${NEO_XMODMAP_ALTERNATIVE:-$HOME/neo/neo_de_alternative.xmodmap}
1277NEO_XMODMAP_EVDEV=${NEO_XMODMAP_EVDEV:-$HOME/neo/neo_de_evdev.xmodmap}
1278NEO_CONSOLE_KEYMAP=${NEO_CONSOLE_KEYMAP:-$HOME/neo/neo.map}
1279
1280die() {
1281        echo "$@" >&2
1282        exit 1
1283}
1284
1285set_xmodmap() {
1286        if [ -e "${PATH_XMODMAP}" ]; then
1287                if [ -f "$@" ]; then
1288                        set_xkbmap lv
1289                        "${PATH_XMODMAP}" "$@" || ( set_xkbmap de ; die "Failed to set xmodmap $@." )
1290                else
1291                        die "Cannot use $@ for xmodmap."
1292                fi
1293        else
1294                die "xmodmap not found, cannot set xmodmap."
1295        fi
1296}
1297
1298set_xkbmap() {
1299        if [ -e "${PATH_SETXKBMAP}" ]; then
1300                "${PATH_SETXKBMAP}" "$@" || die "Failed to select xkbmap $@."
1301        else
1302                die "setxkbmap not found, cannot set xkbmap."
1303        fi
1304}
1305
1306set_keymap() {
1307        if [ -e "${PATH_LOADKEYS}" ]; then
1308                if [ -f "$@" ]; then
1309                        if [ "${EUID}" = 0 ]; then
1310                                "${PATH_LOADKEYS}" "$@" || die "Failed to set keymap $@."
1311                        elif [ -e "${PATH_SUDO}" ]; then
1312                                "${PATH_SUDO}" "${PATH_LOADKEYS}" "$@" || die "Failed to set keymap using sudo."
1313                        else
1314                                die "You need root priviliges to change the keymap."
1315                        fi
1316                else
1317                        die "keymap file $@ does not exist."
1318                fi
1319        else
1320                die "loadkeys not found, cannot set keymap."
1321        fi
1322}
1323
1324if [ -n "$SSH_CONNECTION" ]; then
1325        die "Cannot set keybord layout in a ssh session."
1326fi
1327
1328if [ -z ${DISPLAY} ]; then
1329        set_keymap "${NEO_CONSOLE_KEYMAP}"
1330
1331        if [ -e "${PATH_SETLEDS}" ]; then
1332                "${PATH_SETLEDS}" +num || die "Failed to set NUM status."
1333        else
1334                die "setleds does not exist, cannot set NUM status."
1335        fi
1336else
1337        if [ -e "${PATH_NUMLOCKX}" ]; then
1338                "${PATH_NUMLOCKX}" off || die "Failed to turn off Numlock."
1339        else
1340                die "numlockx not found, cannot turn off Numlock."
1341        fi
1342
1343        if [ -e "${PATH_XSET}" ]; then
1344                for modifier in 51 94; do
1345                        "${PATH_XSET}" -r ${modifier} || die "Failed to unset repeat for modifier ${modifier}."
1346                done
1347                for deadkey in 21 35 49; do
1348                        "${PATH_XSET}" -r ${deadkey} || die "Failed to unset repeat for deadkey ${deakey}."
1349                done
1350        else
1351                die "xset not found, cannot set modifiers and dead keys."
1352        fi
1353
1354        case "${NEO_X_VARIANTE}" in
1355                xkbmap)
1356                        set_xkbmap "${NEO_XKBMAP}" "${NEO_XKBVARIANT}"
1357                        ;;
1358                xmodmap)
1359                        set_xmodmap "${NEO_XMODMAP}"
1360                        ;;
1361                xprog)
1362                        set_xmodmap "${NEO_XMODMAP_XPROG}"
1363                        ;;
1364                alternative)
1365                        set_xmodmap "${NEO_XMODMAP_ALTERNATIVE}"
1366                        ;;
1367                evdev)
1368                        set_xmodmap "${NEO_XMODMAP_EVDEV}"
1369                        ;;
1370                *)
1371                        die "Unknown Neo X variant ${NEO_X_VARIANTE}."
1372                        ;;
1373        esac
1374fi
1375
1376#neo: asdf --- Ende
1377#neo: uiae --- Beginn
1378#!/bin/sh
1379# Copyright 2008 Bernd Steinhauser <berniyh@exherbo.org>
1380# Copyright 2008 Benjamin Kellermann
1381# Copyright 2008 Pascal Hauck
1382# Copyright 2008 Erik Streb del Toro
1383# Distributed under the terms of the GNU General Public License v3
1384
1385if [ -f "${NEO_CONFIG}" ]; then
1386        . "${NEO_CONFIG}" || die "Failed to source ${NEO_CONFIG}"
1387elif [ -f "${HOME}"/.neorc ]; then
1388        . "${HOME}"/.neorc || die "Failed to source ${HOME}/.neorc"
1389elif [ -f /etc/neo.conf ]; then
1390        . /etc/neo.conf || die "Failed to source /etc/neo.conf"
1391else
1392        echo "No configuration file found. Using default values, this might fail!"
1393fi
1394
1395# Default paths
1396PATH_XMODMAP=${PATH_XMODMAP:-/usr/bin/xmodmap}
1397PATH_SETXKBMAP=${PATH_SETXKBMAP:-/usr/bin/setxkbmap}
1398PATH_LOADKEYS=${PATH_LOADKEYS:-/usr/bin/loadkeys}
1399PATH_SUDO=${PATH_SUDO:-/usr/bin/sudo}
1400PATH_SETLEDS=${PATH_SETLEDS:-/usr/bin/setleds}
1401PATH_NUMLOCKX=${PATH_NUMLOCKX:-/usr/bin/numlockx}
1402PATH_XSET=${PATH_XSET:-/usr/bin/xset}
1403
1404# Default values
1405STD_X_VARIANTE=${STD_X_VARIANTE:-xkbmap}
1406STD_XKBMAP=${STD_XKBMAP:-de}
1407STD_XKBVARIANT=${STD_XKBVARIANT:-nodeadkeys}
1408STD_CONSOLE_KEYMAP="${STD_CONSOLE_KEYMAP:-de-latin1-nodeadkeys}"
1409NUM_LOCK_STATUS=${NUM_LOCK_STATUS:-on}
1410
1411die() {
1412        echo "$@" >&2
1413        exit 1
1414}
1415
1416set_xmodmap() {
1417        if [ -e "${PATH_XMODMAP}" ]; then
1418                if [ -f "$@" ]; then
1419                        "${PATH_XMODMAP}" "$@" || die "Failed to set xmodmap $@."
1420                else
1421                        die "Cannot use $@ for xmodmap."
1422                fi
1423        else
1424                die "xmodmap not found, cannot set xmodmap."
1425        fi
1426}
1427
1428set_xkbmap() {
1429        if [ -e "${PATH_SETXKBMAP}" ]; then
1430                "${PATH_SETXKBMAP}" "$@" || die "Failed to select xkbmap $@."
1431        else
1432                die "setxkbmap not found, cannot set xkbmap."
1433        fi
1434}
1435
1436set_keymap() {
1437        if [ -e "${PATH_LOADKEYS}" ]; then
1438                if [ -f "$@" ]; then
1439                        if [ "${EUID}" = 0 ]; then
1440                                "${PATH_LOADKEYS}" "$@" || die "Failed to set keymap $@."
1441                        elif [ -e "${PATH_SUDO}" ]; then
1442                                "${PATH_SUDO}" "${PATH_LOADKEYS}" "$@" || die "Failed to set keymap using sudo."
1443                        else
1444                                die "You need root priviliges to change the keymap."
1445                        fi
1446                else
1447                        die "keymap file $@ does not exist."
1448                fi
1449        else
1450                die "loadkeys not found, cannot set keymap."
1451        fi
1452}
1453
1454if [ -n "$SSH_CONNECTION" ]; then
1455        die "Cannot set keybord layout in a ssh session."
1456fi
1457
1458if [ -z ${DISPLAY} ]; then
1459        set_keymap "${NEO_CONSOLE_KEYMAP}"
1460
1461        if [ -e "${PATH_SETLEDS}" ]; then
1462                if [ "${NUM_LOCK_STATUS}" = "on" ]; then
1463                        "${PATH_SETLEDS}" -num || die "Failed to set num lock status to on."
1464                else
1465                        "${PATH_SETLEDS}" +num || die "Failed to set num lock status to off."
1466                fi
1467        else
1468                die "setleds does not exist, cannot set NUM status."
1469        fi
1470else
1471        if [ -e "${PATH_XSET}" ]; then
1472                for modifier in 51 94; do
1473                        "${PATH_XSET}" r ${modifier} || die "Failed to set repeat for modifier ${modifier}."
1474                done
1475                for deadkey in 21 35 49; do
1476                        "${PATH_XSET}" r ${deadkey} || die "Failed to set repeat for deadkey ${deakey}."
1477                done
1478        else
1479                die "xset not found, cannot set modifiers and dead keys."
1480        fi
1481
1482        case "${STD_X_VARIANTE}" in
1483                xkbmap)
1484                        set_xkbmap "${STD_XKBMAP}" "${STD_XKBVARIANT}"
1485                        ;;
1486                xmodmap)
1487                        set_xkbmap de
1488                        set_xmodmap "${STD_XMODMAP}"
1489                        ;;
1490                *)
1491                        die "Unknown standard X variant ${STD_X_VARIANTE}."
1492                        ;;
1493        esac
1494
1495        if [ -e "${PATH_NUMLOCKX}" ]; then
1496                if [ "${NUM_LOCK_STATUS}" = "on" ]; then
1497                        "${PATH_NUMLOCKX}" on || die "Failed to set num lock status to on."
1498                else
1499                        "${PATH_NUMLOCKX}" off || die "Failed to set num lock status to off."
1500                fi
1501        else
1502                die "numlockx not found, cannot turn off Numlock."
1503        fi
1504fi
1505
1506#neo: uiae --- Ende
1507#neo: neorc --- Beginn
1508# This file contains the configuration for the Neo scripts
1509
1510# Select the neo Variant to be used when using an X Server
1511# Values are "xkbmap", "xmodmap", "xprog", "alternative" or "evdev"
1512# default is xkbmap, this variable should always be set
1513NEO_X_VARIANTE="xmodmap"
1514
1515
1516# When using xkbmap, you may specify which xkbmap should be used, the default
1517# is "de" (This is useful if you installed the symbols file under a different
1518# name):
1519#NEO_XKBMAP=de
1520
1521# You can also specify the xkbmap variant to be used, the default is "neo":
1522#NEO_XKBVARIANT=neo
1523
1524
1525# When using a xmodmap, you may specify the full path to the xmodmap to be used.
1526# Default:
1527NEO_XMODMAP="$HOME/neo/neo_de.xmodmap"
1528#NEO_XMODMAP_XPROG="$HOME/neo/neo_de_x-prog.xmodmap"
1529#NEO_XMODMAP_ALTERNATIVE="$HOME/neo/neo_de_alternative.xmodmap"
1530#NEO_XMODMAP_EVDEV="$HOME/neo/neo_de_evdev.xmodmap"
1531
1532
1533# Standard keyboard layout to switch back to when executing "uiae":
1534#STD_XKBMAP=de
1535
1536# Standard layout variant to switch back to when executing "uiae":
1537#STD_XKBVARIANT=nodeadkeys
1538
1539# Numlock status when switching to standard keyboard layout using "uiae",
1540# values are "on" and "off":
1541#NUM_LOCK_STATUS=on
1542
1543
1544# For Neo without an X System set the path to the console keymap
1545NEO_CONSOLE_KEYMAP="$HOME/neo/neo" # if necessary add „.map“
1546
1547# Set the standard console keymap to switch back to
1548#STD_CONSOLE_KEYMAP="de-latin1-nodeadkeys"
1549
1550
1551# If you installed one of these programs in a non-standard path you may,
1552# uncomment the variable and change the path to the executable:
1553#PATH_XMODMAP=/usr/bin/xmodmap
1554#PATH_SETXKBMAP=/usr/bin/setxkbmap
1555#PATH_LOADKEYS=/usr/bin/loadkeys
1556#PATH_SUDO=/usr/bin/sudo
1557#PATH_SETLEDS=/usr/bin/setleds
1558#PATH_NUMLOCKX=/usr/bin/numlockx
1559#PATH_XSET=/usr/bin/xset
1560
1561#neo: neorc --- Ende
1562#neo: profile.neo --- Beginn
1563
1564# NEO:
1565asdf   # mit einem # am Zeilenanfang bleibt QWERTZ das Standardlayout, sonst ist es NEO
1566#neo: profile.neo --- Ende
1567#neo: profile.qwertz --- Beginn
1568
1569# NEO:
1570# asdf   # mit einem # am Zeilenanfang bleibt QWERTZ das Standardlayout, sonst ist es NEO
1571#neo: profile.qwertz --- Ende
1572
Note: See TracBrowser for help on using the browser.