mirror of
https://github.com/sourcegit-scm/sourcegit.git
synced 2024-12-23 20:47:25 -08:00
ux: better line number layout
This commit is contained in:
parent
ecc1414006
commit
55d2657799
1 changed files with 3 additions and 3 deletions
|
@ -104,7 +104,7 @@ namespace SourceGit.Views
|
|||
if (string.IsNullOrEmpty(lineNumber))
|
||||
continue;
|
||||
|
||||
var y = line.GetTextLineVisualYPosition(line.TextLines[0], VisualYPosition.TextTop) - view.VerticalOffset;
|
||||
var y = line.GetTextLineVisualYPosition(line.TextLines[0], VisualYPosition.LineMiddle) - view.VerticalOffset;
|
||||
var txt = new FormattedText(
|
||||
lineNumber,
|
||||
CultureInfo.CurrentCulture,
|
||||
|
@ -112,7 +112,7 @@ namespace SourceGit.Views
|
|||
typeface,
|
||||
presenter.FontSize,
|
||||
presenter.Foreground);
|
||||
context.DrawText(txt, new Point(Bounds.Width - txt.Width, y));
|
||||
context.DrawText(txt, new Point(Bounds.Width - txt.Width, y - txt.Height * 0.5));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -392,7 +392,7 @@ namespace SourceGit.Views
|
|||
|
||||
_lineStyleTransformer = new LineStyleTransformer(this);
|
||||
|
||||
TextArea.TextView.Margin = new Thickness(4, 0);
|
||||
TextArea.TextView.Margin = new Thickness(2, 0);
|
||||
TextArea.TextView.Options.EnableHyperlinks = false;
|
||||
TextArea.TextView.Options.EnableEmailHyperlinks = false;
|
||||
|
||||
|
|
Loading…
Reference in a new issue