From 1e10fc04bca16bf1b6e92ea8a350c5d038d9b122 Mon Sep 17 00:00:00 2001 From: cxl Date: Thu, 4 Sep 2014 13:43:35 +0000 Subject: [PATCH] ide: TextDiffCtrl hl fix git-svn-id: svn://ultimatepp.org/upp/trunk@7638 f0d560ea-af0d-0410-9eb7-867de7ffcac7 --- uppsrc/TextDiffCtrl/TextCtrl.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/uppsrc/TextDiffCtrl/TextCtrl.cpp b/uppsrc/TextDiffCtrl/TextCtrl.cpp index 28ed40449..166986f35 100644 --- a/uppsrc/TextDiffCtrl/TextCtrl.cpp +++ b/uppsrc/TextDiffCtrl/TextCtrl.cpp @@ -251,13 +251,14 @@ void TextCompareCtrl::Paint(Draw& draw) if(!sel) WhenHighlight(hln, ln); int x = 0; + int a = StdFont().GetAscent(); for(int i = 0; i < hln.GetCount(); i++) { Font fnt = font; LineEdit::Highlight& h = hln[i]; fnt.Bold(h.font.IsBold()); fnt.Italic(h.font.IsItalic()); fnt.Underline(h.font.IsUnderline()); - draw.DrawText(number_width - offset.cx + x, y, &h.chr, fnt, h.ink, 1); + draw.DrawText(number_width - offset.cx + x, y + a - fnt.GetAscent(), &h.chr, fnt, h.ink, 1); x += font[h.chr]; } }