edbee / edbee-lib

QWidget based Text Editor Component for Qt. Multi-caret, Textmate grammar and highlighting support.
Other
75 stars 26 forks source link

Rendering issues when selecting Chinese characters #110

Open vadi2 opened 4 years ago

vadi2 commented 4 years ago

Given this text:

tool.tempid1 = tempTrigger("这里是大理寺", [[speedwalk("se;2s;w;n;et")]], 1)
tool.tempid2 = tempTrigger("这里是盛昌行临安府分店", [[speedwalk("s;e;2n;nw")]], 1)
tool.tempid3 = tempRegexTrigger([[^这里是(\w+)的储物柜.*]], [[speedwalk("out;s;e;2n;nw")]], 1)
tempTimer(0.2, [[send("place")]])
tempTimer(0.4, [[killTrigger(tool.tempid1)]])
tempTimer(0.4, [[killTrigger(tool.tempid2)]])
tempTimer(0.4, [[killTrigger(tool.tempid3

There seems to be some rendering strangeness when selecting text, see: https://streamable.com/7pcz7b

gamecreature commented 4 years ago

When I look at this, it looks like the distance between the lines is too small. Selection background is drawn on a per line basis. Which means the background is drawn over the previous line.

Perhaps this also is the cause of #73. (line height drawing issues)

gamecreature commented 4 years ago

Checked in My test environment. It renders correctly. Could you check if the line-height has been decreased?