Xcode/Mac: keyboard shortcut to type the "OR" sign "||" (double vertical bar)?
70,322
Solution 1
This site lists the shortcut as Shift+Alt+L if you use a Mac keyboard. But the "pipe" symbol does actually exist on the Mac UK keyboard so can't you just press that key twice?
Solution 2
That did not work for me either. But this one did:
Alt+ 7 with the Alt key on the right side of the keyboard or Ctrl + Alt + 7 with the Alt key on the left side
Solution 3
I have a Macbook with Danish keyboard, and for me I use the Alt+i, to make the | operand.
Solution 4
It is Shift + Alt + "I" for Turkish QWERTY users. Shift + Alt + "L" did not work for me, even with U.S. input source.
Solution 5
On Swedish keyboard this worked for me: Opt + 7
Related videos on Youtube
Author by
toto_tata
Updated on July 09, 2022Comments
-
toto_tata over 1 year
Each time I have to copy paste "||" from elsewhere when I want to type the double vertical bar of the OR sign.
Is there a keyboard shortcut to type it?
-
user3443701 over 12 yearsShift-\ Shift-\ doesn't work?
-
-
Elina over 6 yearsOn the French Mac keyboard there is no pipe key... and brackets/braces are not even printed on the paren keys... see support.apple.com/library/content/dam/edam/applecare/images/…
-
andyb over 6 years@neural5torm Have you tried combinations from superuser.com/a/416474/287444 or apple.stackexchange.com/a/17915? I do not have a Mac in front of me so I cannot check
-
Elina over 6 yearsOh but your solution does work though, I was merely trying to explain why the OP asked the question in the first place since his profile seems to indicate he is from France (as I am)...
-
Mikkel Larsen over 4 yearsFinally - Thanks!!
-
Alan Mark Kristensen about 3 yearsOn a never macbook that will be the
option
+i
combo instead