Is there any way to have a dash ( - ) that wont break the word if it's ending a line? (Just like
prevents a line break between two words)
The problem that I currently have is a blog post (dynamic) that has the word X-Ray in it. Sadly, it falls on the end of a line so I get
Lorem ipsum dolor si amet X-
Ray
I would like to prevent that, and get a result like this
Lorem ipsum dolor si amet
X-Ray
I can't just <br />
everything, because depending on where you are on the website, it won't be stuck in that position everywhere.
Hyphenation (properly called word division) is breaking long words between lines. The purpose of hyphenation is to reduce the white space between words.
The answer to this dilemma is to use non-breaking hyphens instead of regular dashes when you don't want Word to break a line at the hyphen. To do this, hold down the Ctrl and Shift keys as you type the dash (this is the same as typing Ctrl and an underscore). Word will then not break the line at that point.
The answer to this dilemma is to use non-breaking hyphens instead of regular dashes when you don't want Word to break a line at the hyphen. To do this, hold down the Ctrl and Shift keys as you type the dash (this is the same as typing Ctrl and an underscore). Word will then not break the line at that point.
Hyphenation is the use of a hyphen to break up a word when it reaches the edge of a document or container. The picture is an example of hyphenation. As shown in the picture, the word "service" is hyphenated as "ser-vice" because it's continued to the next line.
Try a non-breaking hyphen, ‑
Info at http://www.fileformat.info/info/unicode/char/2011/index.htm
You can use the Unicode Character 'NON-BREAKING HYPHEN' (U+2011).
HTML Entity (decimal) ‑
HTML Entity (hex) ‑
How to type in Microsoft Windows Alt +2011
UTF-8 (hex) 0xE2 0x80 0x91 (e28091)
UTF-8 (binary) 11100010:10000000:10010001
UTF-16 (hex) 0x2011 (2011)
UTF-16 (decimal) 8,209
UTF-32 (hex) 0x00002011 (2011)
UTF-32 (decimal) 8,209
C/C++/Java source code "\u2011"
Python source code u"\u2011"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With