mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-11-03 02:57:01 -05:00
Also ensure insert special character normalizes to NFC
This commit is contained in:
parent
8ed750302a
commit
03a38da996
@ -6,6 +6,7 @@ __copyright__ = '2014, Kovid Goyal <kovid at kovidgoyal.net>'
|
|||||||
|
|
||||||
import re
|
import re
|
||||||
import textwrap
|
import textwrap
|
||||||
|
import unicodedata
|
||||||
from bisect import bisect
|
from bisect import bisect
|
||||||
from functools import partial
|
from functools import partial
|
||||||
|
|
||||||
@ -843,7 +844,7 @@ class CharSelect(Dialog):
|
|||||||
self.parent().activateWindow()
|
self.parent().activateWindow()
|
||||||
w = self.parent().focusWidget()
|
w = self.parent().focusWidget()
|
||||||
e = QInputMethodEvent('', [])
|
e = QInputMethodEvent('', [])
|
||||||
e.setCommitString(c)
|
e.setCommitString(unicodedata.normalize('NFC', c))
|
||||||
if hasattr(w, 'no_popup'):
|
if hasattr(w, 'no_popup'):
|
||||||
oval = w.no_popup
|
oval = w.no_popup
|
||||||
w.no_popup = True
|
w.no_popup = True
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user