Open amarao opened 6 years ago
I can't reproduce this neither on Ubuntu 17.10 nor on Debian Testing. Note that for some emojis (like flags) you have to press the left or right arrow key multiple times before the cursor actually moves on screen (probably because they consist of multiple Unicode code points but that's a missing feature of xi-core).
Yea core doesn't handle cursor movement through emoji (or other complex graphemes) although that should be fixed soon: https://github.com/google/xi-editor/pull/520
I'd agree, that part of the lag is due to stops inside emoji, but I want to point, that when moving cursor through faces (colored), CPU consumption goes way up. ~30% of one core for xi-gtk process and ~80% for Xorg. (intel driver). It does not happens on normal text: ~7% for xi-gtk at max and 10% for xorg.
Can it be related to the way emoji are drawn?
Steps to reproduce:
1) Create a new document in xi-gtk 2) Copy content of https://getemoji.com/ page from a web-browser 3) Paste that content into xi-gtk 4) Move cursor somewhere in the middle (to the national flags) 5) Try to move cursor around
Expected behavior: no lags. Actual behavior: delays up to 200ms per each cursor move in any direction. CPU consumption goes from 3% to 60% for just a cursor movement.
Environment: freshly compiled release version of xi-core, commit 16a00f6c5f9e549c64c for xi-gtk, Ubuntu 18.04 86_64, CPU Intel(R) Core(TM) i7-7560U CPU @ 2.40GHz