mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
Improved text selection (#4127)
Co-authored-by: pajlada <rasmus.karlsson@pajlada.com>
This commit is contained in:
parent
39f7d8ac4c
commit
d409e3f17d
2 changed files with 3 additions and 1 deletions
|
@ -79,6 +79,7 @@
|
|||
- Minor: Make menus and placeholders display appropriate custom key combos. (#4045)
|
||||
- Minor: Migrated /chatters to Helix API. (#4088, #4097, #4114)
|
||||
- Minor: Migrated /mods to Helix API. (#4103)
|
||||
- Minor: Improved text selection to match Windows native behaviour. (#4127)
|
||||
- Minor: Add settings tooltips. (#3437)
|
||||
- Minor: Improved look of tabs when using a layout other than top. (#3925)
|
||||
- Bugfix: Fixed `Add new account` dialog causing main chatterino window to be non movable. (#4121)
|
||||
|
|
|
@ -327,7 +327,8 @@ int TextLayoutElement::getMouseOverIndex(const QPoint &abs) const
|
|||
auto &&text = this->getText();
|
||||
auto width = metrics.horizontalAdvance(this->getText()[i]);
|
||||
|
||||
if (x + width > abs.x())
|
||||
// accept mouse to be at only 50%+ of character width to increase index
|
||||
if (x + (width * 0.5) > abs.x())
|
||||
{
|
||||
if (text.size() > i + 1 && QChar::isLowSurrogate(text[i].unicode()))
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue