diff options
author | Mickael Istria | 2018-03-21 10:01:18 +0000 |
---|---|---|
committer | Mickael Istria | 2018-03-23 13:16:16 +0000 |
commit | 910772ae20594fbad8efe137df01c165c669fbc4 (patch) | |
tree | 34639aac81938228f7fa7834cf48e8b24aa28015 | |
parent | a035890396b7cbf3ae656755649e82024d37e128 (diff) | |
download | eclipse.platform.text-910772ae20594fbad8efe137df01c165c669fbc4.tar.gz eclipse.platform.text-910772ae20594fbad8efe137df01c165c669fbc4.tar.xz eclipse.platform.text-910772ae20594fbad8efe137df01c165c669fbc4.zip |
Bug 532682 - Too high bracket box when line height is bigger
Change-Id: I601f715ee8a47fba82c1233d80d12032877741e3
Signed-off-by: Mickael Istria <mistria@redhat.com>
-rw-r--r-- | org.eclipse.jface.text/src/org/eclipse/jface/text/source/MatchingCharacterPainter.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/org.eclipse.jface.text/src/org/eclipse/jface/text/source/MatchingCharacterPainter.java b/org.eclipse.jface.text/src/org/eclipse/jface/text/source/MatchingCharacterPainter.java index f7afc6b1767..1e3f99bc8c7 100644 --- a/org.eclipse.jface.text/src/org/eclipse/jface/text/source/MatchingCharacterPainter.java +++ b/org.eclipse.jface.text/src/org/eclipse/jface/text/source/MatchingCharacterPainter.java @@ -249,9 +249,10 @@ public final class MatchingCharacterPainter implements IPainter, PaintListener { gc.setForeground(fColor); Rectangle bounds= fTextWidget.getTextBounds(offset, offset + length - 1); + int height= fTextWidget.getCaret().getSize().y; // draw box around line segment - gc.drawRectangle(bounds.x, bounds.y, bounds.width - 1, bounds.height - 1); + gc.drawRectangle(bounds.x, bounds.y + bounds.height - height, bounds.width - 1, height - 1); // draw box around character area // int widgetBaseline= fTextWidget.getBaseline(); |