[kompare] [Bug 481778] Text in lines is cut in half, only lower half of the line text is visible when font size less than 14
Christoph Feck
bugzilla_noreply at kde.org
Thu Jul 31 23:06:38 BST 2025
https://bugs.kde.org/show_bug.cgi?id=481778
--- Comment #20 from Christoph Feck <cfeck at kde.org> ---
What worked for me is forcing Top alignment. I didn't really understand the
logic behind paintHeight(), so the patch might be all wrong.
diff --git a/src/komparepart/komparelistview.cpp
b/src/komparepart/komparelistview.cpp
index 61cd7bb..3deb472 100644
--- a/src/komparepart/komparelistview.cpp
+++ b/src/komparepart/komparelistview.cpp
@@ -745,7 +745,7 @@ void KompareListViewLineItem::init(int line,
DifferenceString* text)
void KompareListViewLineItem::paintCell(QPainter* p, const
QStyleOptionViewItem& option, int column)
{
int width = option.rect.width();
- Qt::Alignment align = option.displayAlignment;
+ Qt::Alignment align = option.displayAlignment & ~Qt::AlignVCenter |
Qt::AlignTop;
p->setRenderHint(QPainter::Antialiasing);
p->translate(option.rect.topLeft());
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Kompare-devel
mailing list