I want to type guillemets (angle quotes, «») in Ubuntu when using
- Russian keyboard mapping
- English keyboard mapping
Is it possible (preferably without typing numeric codes)?
There is a discussion here, but it does not mention Linux.
I want to type guillemets (angle quotes, «») in Ubuntu when using
Is it possible (preferably without typing numeric codes)?
There is a discussion here, but it does not mention Linux.
Below is list of methods to enable special typographic symbols.
For Russian en English layouts they are defined in /usr/share/X11/xkb/symbols/typo
file (mainly based on the layout proposed by Ilya Birman).
As the result you will get the following symbols:
First keyboard row:
≈
;¹
, Shift+1 exclamdown ¡
;²
, Shift+2 onehalf ½
;³
, Shift+3 onethird ⅓
;$
, Shift+4 onequarter ¼
;‰
, Shift+5 NoSymbol;↑
, Shift+6 NoSymbol;&
, Shift+7 questiondown ¿
;∞
, Shift+8 oneeighth ⅛
;←
, Shift+9 NoSymbol;→
, Shift+0 NoSymbol;—
, Shift+- endash –
;≠
, Shift+= plusminus ±
;Second keyboard row:
€
, Shift+e NoSymbol;®
, Shift+r NoSymbol;™
, Shift+t NoSymbol;¥
, Shift+y NoSymbol;´
, Shift+p doubleacute ˝
;[
, Shift+[ braceleft {
;]
, Shift+] braceright }
.Third keyboard row:
́
, Shift+a NoSymbol;§
, Shift+s NoSymbol;°
, Shift+d division ÷
;£
, Shift+f NoSymbol;„
, Shift+j singlelowquotemark ‚
;“
, Shift+k leftsinglequotemark ‘
;”
, Shift+l rightsinglequotemark ’
;‘
, Shift+; minutes ′
;’
, Shift+' seconds ″
.Fourth keyboard row:
×
, Shift+x U22C5 (DOT OPERATOR) ⋅
;©
, Shift+c cent ¢
;↓
, Shift+v U25CA (LOZENGE) ◊
;−
, Shift+m enfilledcircbullet •
;«
, Shift+, less <
;»
, Shift+. greater >
;…
, Shift+/ NoSymbol;Space:
, Shift+ Space nobreakspace
.For other languages layouts may vary.
Settings for common desktop environments are presented below.
Launch GNOME Tweaks (installable with sudo apt-get install gnome-tweak-tool
, run by gnome-tweak-tool
)
Open Keyboard preferences (or unity-control-center keyboard
)
Use guillemets («елочки») in any application by pressing RightAlt with corresponding keys (Б and Ю; ,
and .
).
sudo apt-get install gnome-tweaks
, run by gnome-tweaks
)
,
and .
).mate-keyboard-properties
).Select Russian keyboard layout and click Show to ensure that we have guillemets («елочки»):
Use guillemets («елочки») in any application by pressing RightAlt with corresponding keys (Б and Ю; ,
and .
).
Use GSettings to set two layouts (us
and ru
) using Alt+Shift as layout switcher, typographic symbols are enabled RightAlt as 3rd level switch::
gsettings set org.mate.peripherals-keyboard-xkb.kbd layouts "['us', 'ru']"
gsettings set org.mate.peripherals-keyboard-xkb.kbd model "''"
gsettings set org.mate.peripherals-keyboard-xkb.kbd options \
"['grp\tgrp:alt_shift_toggle', 'lv3\tlv3:ralt_switch', 'compat\tmisc:typo']"
Edit /etc/default/keyboard
and add here two parameters as described in man xkeyboard-config
:
misc:typo
to enable extra typographic characters andlv3:ralt_switch
to choose typographic symbols with Right Alt:
XKBOPTIONS="grp:alt_shift_toggle,lv3:ralt_switch"
After editing you should update initramfs images to include the new version of configuration file
sudo update-initramfs -k all -u
AltRight+<
, it prints б.
– rapt
Aug 05 '18 at 20:26
"RightAlt" + "ю"
or "RightAlt" + "."
it prints »
. Do you see 3rd level on the image of keyboard layout chart (accessible from keyboard indicator in right top corner of the screen)?
– N0rbert
Aug 05 '18 at 20:48
unity-control-center keyboard
. Thank you for correction! 3rd-level is next level for <Shift+key>
, I think. If it is not enabled you have lowercaps and capitals. If 3rd level is enabled you have special 3rd level of typographic symbols (see MATE keyboard screenshot above - it have guillemets and other characters). Please follow my instruction precisely. I have tested it many times. Also see this page about typographic keyboard layout (Ubuntu's 3rd layout is based on it).
– N0rbert
Aug 05 '18 at 21:20
RightAlt
) is not anymore functioning in any shortcut that includes this key. Is there a way to solve this?
– rapt
Aug 05 '18 at 23:47
RightAlt
then do not use it for shortcuts starting (or containing) Alt
. Use LeftAlt
instead. Also you can read somewhere about layout switching on wikipedia. As we do not have hardware AltGr
key, we may use one from the Alternative Characters Key list (for example RightAlt
). I can't offer more. The method above is complete and working.
– N0rbert
Aug 06 '18 at 08:44
On the English keyboard the simplest way I have found is this...
Tap Compose then >> (2x > in succession) which gives »
Tap Compose then << (2x < in succession) which gives «
AltGr
key in my physical Keyboard. Is there a way to work around this? Did they not take it into account? What do you mean by not having a Russian keyboard? You can add the Russian keyboard mapping, no?
– rapt
Aug 02 '18 at 08:57
Super+Ctrl+Alt+<<
on both English and Russian keyboard mappings. It did not work. I am using Unity desktop.
– rapt
Aug 05 '18 at 19:22
Apparently having an AltGr (Alternate Graphics) key on your keyboard where the Right Alt resides on US style keyboards is helpful for « and » simulation key strokes.
From this French article, translated by google below, it says:
Under X11 (GNU / Linux) :
Further discussion can be found in Wikipedia:
AltGr (also Alt Graph, or Right Alt1) is a modifier key found on some computer keyboards and is primarily used to type characters that are unusual for the locale of the keyboard layout, such as currency symbols and accented letters. On a typical, IBM-compatible PC keyboard, the AltGr key, when present, takes the place of the right-hand Alt key. In macOS, the Option key has functions similar to the AltGr key.
There is a lot more to read in the link!