I have a treeview that I want to make as minimalist as possible.
TreeView treeView = new TreeView();
treeView.Dock = DockStyle.Fill;
treeView.Margin = new Padding(0);
treeView.CheckBoxes = true;
For my goal, I added these settings (like descripted in this article):
treeView.ShowRootLines = false;
treeView.ShowLines = false;
treeView.ShowPlusMinus = false;
treeView.Indent = 1;
And still, there is some empty space left of the treeview.
How can it be removed?
Edit: Setting the indent to 0 removes the space for the parent nodes succesfully:
That feels a bit weird because Indent is described as "distance to indent each child tree node level". So this approach takes me the possibility to move the child nodes closer to the parent nodes (like in the second image).
So instead of moving just the parent to the left, I'd like to move parent + childs to the left.
question from:
https://stackoverflow.com/questions/65915376/windows-forms-remove-empty-space-left-of-treeview 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…