Bug 889397 - Unicode surrogates cause odd cursor movement in the editor
Unicode surrogates cause odd cursor movement in the editor
Status: CLOSED WORKSFORME
Product: Zanata
Classification: Community
Component: Component-UI (Show other bugs)
2.0
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Damian Jansen
Zanata-QA Mailling List
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-12-20 22:25 EST by Sean Flanigan
Modified: 2014-03-24 01:01 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-03-24 01:01:48 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Sean Flanigan 2012-12-20 22:25:00 EST
Description of problem:
The codemirror editor we are using does not properly support some unicode characters, such as this one: "
Comment 1 Sean Flanigan 2012-12-21 02:41:36 EST
I guess bugzilla can't handle that character either!

Here's the report again, without the character itself:


Description of problem:
The codemirror editor we are using does not properly support some unicode characters, such as this one: http://www.codetable.net/decimal/119558

Version-Release number of selected component (if applicable):
2.0.3 (20121129-1831)

How reproducible:
100%

Steps to Reproduce:
1. Enter an ASCII character, eg "A".
2. Paste the character "
Comment 2 Sean Flanigan 2012-12-21 02:44:03 EST
Oops, broke bugzilla again.

Steps to Reproduce:
1. Enter an ASCII character, eg "A".
2. Paste the character [from http://www.codetable.net/decimal/119558 ] into a textflow target
3. Press the left arrow twice.
  
Actual results:
Cursor appears just before the Unicode character.

Expected results:
Cursor appears before the A character.

Additional info:
See also https://github.com/ajaxorg/ace/issues/1153 for a similar bug in ACE

Even stranger cursor behaviour can be found if you press backspace after pasting the Unicode character, because it deletes only one of the surrogates.
Comment 3 Ding-Yi Chen 2014-03-24 01:01:48 EDT
Tested with Zanata 3.4.0-SNAPSHOT (20140321-1747)
I cannot reproduce this bug, it might be fixed in code mirror upgrade.


However, as a note: I did find that I cannot save the character "U+1D306 TETRAGRAM FOR CENTRE" because of the limitation of MySQL
(See http://dev.mysql.com/doc/refman/5.1/en/faqs-cjk.html#qandaitem-B-11-1-16)

For mysql >= 5.5.3, the setting encoding as utf8mb4 should fix the problem,
but there are no feasible solutions for earlier versions.

Note You need to log in before you can comment on or make changes to this bug.