mirror of
https://github.com/Ryujinx/GtkSharp.git
synced 2024-12-22 20:35:37 +00:00
Changed sample project to show line numbers in sourceview
Just to make it a bit more obvious that the widget is a SourceView and not a TextView.
This commit is contained in:
parent
27125e5984
commit
6d3c0cf744
|
@ -16,7 +16,7 @@ namespace Samples
|
|||
private Box _boxContent;
|
||||
private TreeStore _store;
|
||||
private Dictionary<string, (Type type, Widget widget)> _items;
|
||||
private TextView _textViewCode;
|
||||
private SourceView _textViewCode;
|
||||
private Notebook _notebook;
|
||||
|
||||
public MainWindow() : base(WindowType.Toplevel)
|
||||
|
@ -56,7 +56,10 @@ namespace Samples
|
|||
_notebook.AppendPage(scroll1, new Label { Text = "Data", Expand = true });
|
||||
|
||||
var scroll2 = new ScrolledWindow();
|
||||
|
||||
_textViewCode = new SourceView();
|
||||
_textViewCode.ShowLineNumbers = true;
|
||||
|
||||
_textViewCode.Margin = 3;
|
||||
scroll2.Child = _textViewCode;
|
||||
_notebook.AppendPage(scroll2, new Label { Text = "Code", Expand = true });
|
||||
|
|
Loading…
Reference in a new issue