Sublime Forum

Sublime not showing line-break unicode char <U+2028>

#1

I spent literally half an hour tonight trying to understand why the hell the browser was adding an extra line break to my page design.

Checked CSS, firebug, nothing. Happening in both Chrome and in Firefox !

Long story short, after a lot of debugging, I realized my

tags

were to blame. But most amazingly, when I replaced those lines with the exact same content inside the

tags, the line breaks disappeared !

Since neither ‘show source code’ nor firebug showed anything different, but the render was different (extra line break), I decided to commit the changes with the line break, then replace those lines with the same exact content and run git diff.

To my surprise, there was an Invisible character in my HTML code that Sublime simply didn’t show:

cl.ly/image/1V3n0i0W2P2k

After a google search for <U+2028>, you find out it’s the Unicode Character ‘LINE SEPARATOR’ (U+2028)

As you can see, in Sublime it’s invisible:

cl.ly/image/2g463F272r0H

How did I get that char there in the first place ? I copied and pasted text from a .docx file opened in Pages directly inside sublime.

0 Likes