Browse Source

fixed SD-353: Wrong position of insight window when horizontal ruler is visible

git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@117 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Markus Palme 21 years ago
parent
commit
ecb18d86d0
  1. 3
      src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/InsightWindow/InsightWindow.cs

3
src/Libraries/ICSharpCode.TextEditor/Project/Src/Gui/InsightWindow/InsightWindow.cs

@ -67,8 +67,9 @@ namespace ICSharpCode.TextEditor.Gui.InsightWindow @@ -67,8 +67,9 @@ namespace ICSharpCode.TextEditor.Gui.InsightWindow
int xpos = control.ActiveTextAreaControl.TextArea.TextView.GetDrawingXPos(caretPos.Y, caretPos.X);
int ypos = (control.ActiveTextAreaControl.Document.GetVisibleLine(caretPos.Y) + 1) * control.ActiveTextAreaControl.TextArea.TextView.FontHeight - control.ActiveTextAreaControl.TextArea.VirtualTop.Y;
int rulerHeight = control.TextEditorProperties.ShowHorizontalRuler ? control.ActiveTextAreaControl.TextArea.TextView.FontHeight : 0;
Point p = control.ActiveTextAreaControl.PointToScreen(new Point(xpos, ypos));
Point p = control.ActiveTextAreaControl.PointToScreen(new Point(xpos, ypos + rulerHeight));
if (p.Y != Location.Y) {
Location = p;
}

Loading…
Cancel
Save