Closed JensLincke closed 3 years ago
For plain text labels, we turn a tab keypress into 4 * \xa0 (non-breaking space character), which is what you see in the output. All other unicode chars (such as umlauts) are correct in the output. On the terminal in macOS, the output looks like this for me:
$ cat architecture.drawio.xml| grep custom | cut -c -120 <mxCell id="iHkALPmoCXANNeq6opZh-39" value="+ process(code, 
 annotations, 
 customInstances, 
 <mxCell id="iHkALPmoCXANNeq6opZh-46" value="+ onmessage(code, 
 annotations, 
 customInstances, &# <mxCell id="iHkALPmoCXANNeq6opZh-50" value="<div style="font-size: 5px"><br></div>&l <mxCell id="iHkALPmoCXANNeq6opZh-98" value="<span class="hljs-comment" style="color: rgb(150,
Embedding also works for me. Could you add a link to a test case please?
maybe this is a linux issue... but I see this in a standard WSL (windows subsystem for linux) and in xterm... and I see this in chrome when viewing the raw file on github: @alderg , did you check the file out with git and in got automatically repaired in MacOS?
How did you insert those characters?
I used https://app.diagrams.net to load a file from github and save it back https://app.diagrams.net/#HLivelyKernel%2Flively4-core%2Fdrawio%2Fsrc%2Fbabylonian-programming-editor%2Farchitecture.drawio
What key did you press to insert those characters?
Sorry, I found the issue on my side:
using https://app.diagrams.net/#HJensLincke%2Fdrawio-test%2Fdrawio%2Ftest-chars.drawio
to edit https://github.com/JensLincke/drawio-test/blob/drawio/test-chars.drawio
I used a german keyboard and pasted the unicode through the clipboard
This is sample text:
this a tab...
öäüß german umlauts and sz
→and a unicode error
and the umlauts and unicode char seems to correctly end up in the drawio branch ....
And the bad conversion happend when copying it to the main branch...
Preflight Checklist
Describe the bug
Using https://www.diagrams.net/ I created a drawing and saved it in github as
architecture.drawio
When displaying in in a website via embedding the text encoding is weired
Potential BUG: double UTF-8 encoding...
And by converting it from UTF-8 to Latin1 it will be displayed correctly in a UTF8 terminal:
So I assume there is a double utf-8 encoding happening somewhere?
To Reproduce Steps to reproduce the behavior:
edited figugure https://app.diagrams.net/#HLivelyKernel%2Flively4-core%2Fdrawio%2Fsrc%2Fbabylonian-programming-editor%2Farchitecture.drawio
Visit same file on gitbub https://github.com/LivelyKernel/lively4-core/blob/gh-pages/src/babylonian-programming-editor/architecture.drawio
See weired encoding on line 1000
Expected behavior
I would expect to see "tabs" or other unicode there, but not encoding errors.
draw.io version (In the Help->About menu of the draw.io editor):
Desktop (please complete the following information):