|
|
|
@ -1,7 +1,7 @@
@@ -1,7 +1,7 @@
|
|
|
|
|
// <file>
|
|
|
|
|
// <copyright see="prj:///doc/copyright.txt"/>
|
|
|
|
|
// <license see="prj:///doc/license.txt"/>
|
|
|
|
|
// <owner name="Mike Krüger" email="mike@icsharpcode.net"/>
|
|
|
|
|
// <owner name="Mike Krger" email="mike@icsharpcode.net"/>
|
|
|
|
|
// <version value="$version"/>
|
|
|
|
|
// </file>
|
|
|
|
|
|
|
|
|
@ -306,10 +306,11 @@ namespace ICSharpCode.TextEditor
@@ -306,10 +306,11 @@ namespace ICSharpCode.TextEditor
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="offset">The offset.</param>
|
|
|
|
|
/// <param name="length">The length.</param>
|
|
|
|
|
/// <param name="markers">All markers that have been found.</param>
|
|
|
|
|
/// <returns>The Brush or null when no marker was found.</returns>
|
|
|
|
|
Brush GetMarkerBrushAt(int offset, int length, ref Color foreColor) |
|
|
|
|
Brush GetMarkerBrushAt(int offset, int length, ref Color foreColor, out List<TextMarker> markers) |
|
|
|
|
{ |
|
|
|
|
List<TextMarker> markers = Document.MarkerStrategy.GetMarkers(offset, length); |
|
|
|
|
markers = Document.MarkerStrategy.GetMarkers(offset, length); |
|
|
|
|
foreach (TextMarker marker in markers) { |
|
|
|
|
if (marker.TextMarkerType == TextMarkerType.SolidBlock) { |
|
|
|
|
if (marker.OverrideForeColor) { |
|
|
|
@ -392,7 +393,7 @@ namespace ICSharpCode.TextEditor
@@ -392,7 +393,7 @@ namespace ICSharpCode.TextEditor
|
|
|
|
|
if (ColumnRange.WholeColumn.Equals(selectionRange) || logicalColumn >= selectionRange.StartColumn && logicalColumn < selectionRange.EndColumn) { |
|
|
|
|
spaceBackgroundBrush = selectionBackgroundBrush; |
|
|
|
|
} else { |
|
|
|
|
Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref spaceMarkerForeColor); |
|
|
|
|
Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref spaceMarkerForeColor, out markers); |
|
|
|
|
if (!drawLineMarker && markerBrush != null) { |
|
|
|
|
spaceBackgroundBrush = markerBrush; |
|
|
|
|
} else if (!drawLineMarker && currentWord.SyntaxColor != null && currentWord.SyntaxColor.HasBackground) { |
|
|
|
@ -428,7 +429,7 @@ namespace ICSharpCode.TextEditor
@@ -428,7 +429,7 @@ namespace ICSharpCode.TextEditor
|
|
|
|
|
if (ColumnRange.WholeColumn.Equals(selectionRange) || logicalColumn >= selectionRange.StartColumn && logicalColumn <= selectionRange.EndColumn - 1) { |
|
|
|
|
spaceBackgroundBrush = selectionBackgroundBrush; |
|
|
|
|
} else { |
|
|
|
|
Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref tabMarkerForeColor); |
|
|
|
|
Brush markerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, 1, ref tabMarkerForeColor, out markers); |
|
|
|
|
if (!drawLineMarker && markerBrush != null) { |
|
|
|
|
spaceBackgroundBrush = markerBrush; |
|
|
|
|
} else if (!drawLineMarker && currentWord.SyntaxColor != null && currentWord.SyntaxColor.HasBackground) { |
|
|
|
@ -457,7 +458,7 @@ namespace ICSharpCode.TextEditor
@@ -457,7 +458,7 @@ namespace ICSharpCode.TextEditor
|
|
|
|
|
float lastPos = physicalXPos; |
|
|
|
|
|
|
|
|
|
Color wordForeColor = currentWord.Color; |
|
|
|
|
Brush bgMarkerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, word.Length, ref wordForeColor); |
|
|
|
|
Brush bgMarkerBrush = GetMarkerBrushAt(currentLine.Offset + logicalColumn, word.Length, ref wordForeColor, out markers); |
|
|
|
|
Brush wordBackgroundBrush; |
|
|
|
|
if (!drawLineMarker && bgMarkerBrush != null) { |
|
|
|
|
wordBackgroundBrush = bgMarkerBrush; |
|
|
|
@ -530,7 +531,7 @@ namespace ICSharpCode.TextEditor
@@ -530,7 +531,7 @@ namespace ICSharpCode.TextEditor
|
|
|
|
|
logicalColumn += word.Length; |
|
|
|
|
break; |
|
|
|
|
} |
|
|
|
|
markers.Clear(); |
|
|
|
|
//markers.Clear();
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|