Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Insert non-breaking spaces System
I'm not sure how far back this goes, but on Leopard at least, pressing Option-Space on the US or US Extended keyboard layouts inserts a non-breaking space (U+00A0) rather than a normal space (U+0020). This might be useful for some people; unfortunately there seems to be no simple shortcut for inserting non-breaking hyphens on either of these two keyboard layouts.
    •    
  • Currently 2.25 / 5
  You rated: 2 / 5 (8 votes cast)
 
[21,637 views]  

Insert non-breaking spaces | 8 comments | Create New Account
Click here to return to the 'Insert non-breaking spaces' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Insert non-breaking spaces
Authored by: sjmills on Mar 24, '08 08:02:21AM

That's been around as long as I can remember, I think in the pre-OS X days as well. I can only test it in Classic right now, but yes, it works there.



[ Reply to This | # ]
Insert non-breaking spaces
Authored by: HamsterDeCombat on Mar 24, '08 08:05:03AM

Yes, it was already there before Mac OS X, and with international keyboard layouts as well.



[ Reply to This | # ]
Insert non-breaking spaces
Authored by: boredzo on Mar 24, '08 08:22:42AM

I'm not sure how far back this goes,

It goes back to System 1.0.



[ Reply to This | # ]
Insert non-breaking Hyphen
Authored by: timrand on Mar 24, '08 09:20:26AM

In MS-Word (only) it is CMD-SHIFT-<hyphen> to create a non-breaking hyphen.



[ Reply to This | # ]
Insert non-breaking spaces
Authored by: adrianm on Mar 24, '08 01:45:00PM

Non breaking hyphen us unicode u2011 - I'm not sure if it has a normal keyboard way of entering it, but if you choose the 'Unicode Hex Input' input method, you can do opt+2011 to enter it.

A bit clumsy though.

---
~/.sig: not found



[ Reply to This | # ]
Insert non-breaking spaces
Authored by: asmeurer on Mar 24, '08 08:34:47PM

Woah. I am surprised this isn't in here yet. This has definitely been around since the classic days, maybe even System 1.0 as another commenter suggests.

Option-Space also sometimes lets you type a space character when the spacebar would otherwise do something else, such as selecting the first item in a folder instead of activating Quicklook in the Leopard Finder (I think this hint was posted here). Ditto for selecting playlists in iTunes instead of play/pausing (I don't know if that has been hinted. Fair game if it hasn't).



[ Reply to This | # ]
Insert non-breaking spaces
Authored by: leraillez@netinf on Mar 25, '08 02:14:10AM
I'm not sure how far back this goes, but on Leopard at least, pressing Option-Space on the US or US Extended keyboard layouts inserts a non-breaking space (U+00A0) rather than a normal space (U+0020).
This has been the rule on French keyboards since... but it's broken in Mail.app in Leopard (I never used Mal.app before TimeMachine and the fact that a big mail database is a Go hog in backups). Mail.app 3 inserts normal spaces instead of non breaking spaces and it's frustrating. In French you insert non-breaking spaces before "; : ? !" and » and after «. So you get punctuation marks at the beginning of lines and that's not very clean, to say the least.

[ Reply to This | # ]
Insert non-breaking spaces
Authored by: almostHandsome on Mar 01, '10 08:07:16PM

In OS X, you can easily create new shortcuts.

Create a file called: ~/Library/KeyBindings/DefaultKeyBinding.dict
using a plain text editor.

Add a line like:
"^`" = ("insertText:", "&#8209;"); /* nbhy */

This means "Control-` generates a command to insert a non-breaking hyphen character.

You can also insert a whole word, which is good for words or sequences of words you type often that are long like:
"^M" = ( "insertText:", "Massachusetts" );
"^N" = ( "insertText:", "New Hampshire" );
which means Control-M (not Control-m) inserts Massachusetts.

You can also use 2 character sequences, like
"^s" = {
"^c" = ("insertText:", "&#10004;");
"^x" = ("insertText:", "&#10008;"); /* X Symbol */
"^1" = ("insertText:", ""); /* superscript 1 */
"^2" = ("insertText:", ""); /* superscript 2 */
"^3" = ("insertText:", ""); /* superscript 3 */
};
Then Control-s followed by Control-c enters a check mark, etc.

Yes, this also be used for commands like:
"^a" = "deleteToBeginningOfParagraph:";
which is similar to the built-in Control-k command (delete to end of paragraph and put it in the yank buffer).

Or to move the cursor right by 7 words:
"^\UF703" = (
"moveWordForward:",
"moveWordForward:",
"moveWordForward:",
"moveWordForward:",
"moveWordForward:",
"moveWordForward:",
"moveWordForward:"
);

I get endless amusement out of this kind of thing.



[ Reply to This | # ]