Bug 366424 - Cannot type "private use" unicode characters
Summary: Cannot type "private use" unicode characters
Status: RESOLVED FIXED
Alias: None
Product: kate
Classification: Applications
Component: part (show other bugs)
Version: unspecified
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: KWrite Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-04 20:46 UTC by Luke-Jr
Modified: 2019-08-27 18:00 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.62


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Luke-Jr 2016-08-04 20:46:45 UTC
Version 5.21.0
Using:
- KDE Frameworks 5.21.0
- Qt 5.5.1 (built against 5.5.1)
- The xcb windowing system

I am unable to type characters such as: 

They render fine, and I can copy/paste them fine.

I can type them fine in Qt Designer with both Qt and KDE text entry widgets.

Reproducible: Always
Comment 1 Christoph Feck 2016-08-05 13:20:51 UTC
How do you type them? Standard keyboard layouts should not generate Private Use characters.
Comment 3 Christoph Feck 2016-08-05 16:08:47 UTC
http://www.kreativekorp.com/ucsur/ says Tonal is U+E8E0..U+E8FF. Which is right? :)
(unrelated to this bug report, but I am planning to add UCSUR support to KCharSelect)
Comment 4 Luke-Jr 2016-08-05 20:48:57 UTC
U+E9D0..U+E9EF:
- was the original spec in 2010 ( http://luke.dashjr.org/education/tonal/glyphs/CSUR.html )
- has the oldest support in Tonal-capable fonts
- overlaps/conflicts with UCSUR's GLAITHA-B
- is used by Bitcoin Knots for Tonal support
- is used by Tonal keyboard mappings
- appears to be used in most/all? Tonal-including documents
U+E8E0..U+E8FF:
- was assigned by UCSUR in 2012
- has support in Tonal-capable fonts for at least a few years (IIRC since 2013?)
- appears to have real-world font conflicts
Comment 5 Luke-Jr 2016-09-30 10:10:36 UTC
Bug still exists with 16.04.3 and KF 5.23.0
Comment 6 Christoph Cullmann 2019-08-26 19:41:00 UTC
I see a way to fix this, see https://phabricator.kde.org/D23472
Comment 7 Christoph Cullmann 2019-08-27 17:03:56 UTC
Git commit 0bf5522434044c61d266fc47bc127fef23d41e7b by Christoph Cullmann, on behalf of Ahmad Samir.
Committed on 27/08/2019 at 17:03.
Pushed by cullmann into branch 'master'.

Mimic QInputControl::isAcceptableInput() when filtering typed characters

Summary:
Move all input characters filtering out of typeChars() to KateViewInternal
and filter the input before sending it to typeChars().

This increases the scope of unicode characters that users can type in ktexteditor.
For more info see:
QChar documentation
http://www.unicode.org/Public/UNIDATA/UnicodeData.txt

This should fix:
- bug 396764 (typing soft-hyphens)
- bug 366424 (typing "private use" unicode characters)
- Hopefully bug 389796 (typing formatting characters such as ZWNJ)
Related: bug 396764, bug 389796

Test Plan:
Test typing a soft-hyphen char (here I used Compose key + minus + minus + space)
For the two other bugs, ask the users to test...

All unit tests passed

Reviewers: #ktexteditor, dhaumann, cullmann

Reviewed By: #ktexteditor, cullmann

Subscribers: kde-frameworks-devel, kwrite-devel

Tags: #kate, #frameworks

Differential Revision: https://phabricator.kde.org/D23472

M  +1    -17   src/document/katedocument.cpp
M  +1    -1    src/document/katedocument.h
M  +85   -12   src/view/kateviewinternal.cpp
M  +5    -0    src/view/kateviewinternal.h

https://commits.kde.org/ktexteditor/0bf5522434044c61d266fc47bc127fef23d41e7b