Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorangelozerr2017-09-08 08:09:40 +0000
committerAlexander Kurtakov2017-09-15 13:02:40 +0000
commitaf04cf1999227a7e74d86c687b4289e27cd594fd (patch)
treecf47e0d89b89e2589820df17fc264977bb554614
parente341a61b8c18b906a60eee6886b5d0fc452797e1 (diff)
downloadeclipse.platform.text-I20170917-2000.tar.gz
eclipse.platform.text-I20170917-2000.tar.xz
eclipse.platform.text-I20170917-2000.zip
Bug 481968 - LineNumberRulerColumn.doPaint ignores LineSpacing ofI20170917-2000I20170916-1500I20170915-2000I20170915-1030
StyledText Compute line height by taking care of line spacing Change-Id: I00c7337a018eb5925254bfabf221e8522daa1adc Signed-off-by: angelozerr <angelo.zerr@gmail.com>
-rw-r--r--org.eclipse.jface.text/src/org/eclipse/jface/text/source/LineNumberRulerColumn.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/org.eclipse.jface.text/src/org/eclipse/jface/text/source/LineNumberRulerColumn.java b/org.eclipse.jface.text/src/org/eclipse/jface/text/source/LineNumberRulerColumn.java
index 81002167f..750d18a2a 100644
--- a/org.eclipse.jface.text/src/org/eclipse/jface/text/source/LineNumberRulerColumn.java
+++ b/org.eclipse.jface.text/src/org/eclipse/jface/text/source/LineNumberRulerColumn.java
@@ -11,6 +11,7 @@
* Nikolay Botev <bono8106@hotmail.com> - [rulers] Clicking in line number ruler should not trigger annotation ruler - https://bugs.eclipse.org/bugs/show_bug.cgi?id=40889
* Florian Weßling <flo@cdhq.de> - [rulers] Line numbering was wrong when word wrap was active - https://bugs.eclipse.org/bugs/show_bug.cgi?id=35779
* Rüdiger Herrmann - Insufficient is-disposed check in LineNumberRulerColumn::redraw - https://bugs.eclipse.org/bugs/show_bug.cgi?id=506427
+ * Angelo ZERR <angelo.zerr@gmail.com> - Compute line height by taking care of line spacing - https://bugs.eclipse.org/bugs/show_bug.cgi?id=481968
*******************************************************************************/
package org.eclipse.jface.text.source;
@@ -867,7 +868,7 @@ public class LineNumberRulerColumn implements IVerticalRulerColumn {
continue;
final int offsetAtLine= fCachedTextWidget.getOffsetAtLine(widgetLine);
- int lineHeight= fCachedTextWidget.getLineHeight(offsetAtLine);
+ int lineHeight = JFaceTextUtil.computeLineHeight(fCachedTextWidget, widgetLine, widgetLine + 1, 1);
paintLine(line, y, lineHeight, gc, display);
// increment y position

Back to the top