1 override of SelectionLength
System.Windows.Forms (1)
System\Windows\Forms\Controls\RichTextBox\RichTextBox.cs (1)
1048public override int SelectionLength
56 writes to SelectionLength
System.Windows.Forms (9)
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\PropertyGridView.cs (3)
847EditTextBox.SelectionLength = 0; 4352EditTextBox.SelectionLength = 0; 4685EditTextBox.SelectionLength = 0;
System\Windows\Forms\Controls\RichTextBox\RichTextBox.cs (1)
1064set => base.SelectionLength = value;
System\Windows\Forms\Controls\TextBox\MaskedTextBox.cs (2)
2015SelectionLength = 0; 2849SelectionLength = 0;
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (2)
221SelectionLength = length; 1685SelectionLength = 0;
System\Windows\Forms\Controls\ToolStrips\ToolStripTextBox.cs (1)
322set { TextBox.SelectionLength = value; }
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\LinkAreaEditor.LinkAreaUI.cs (1)
146_sampleEdit.SelectionLength = linkArea.Length;
System.Windows.Forms.Tests (45)
MaskedTextBoxTests.cs (1)
650control.SelectionLength = value.Length;
TextBoxBaseTests.ClipboardTests.cs (15)
19SelectionLength = 2 25control.SelectionLength = 2; 42SelectionLength = 2 49control.SelectionLength = 2; 65SelectionLength = 2 83control.SelectionLength = 2; 102SelectionLength = 2 109control.SelectionLength = 2; 125SelectionLength = 2 143control.SelectionLength = 2; 173SelectionLength = 2 187SelectionLength = 2 192control.SelectionLength = 2; 210control.SelectionLength = 2; 235control.SelectionLength = 2;
TextBoxBaseTests.cs (28)
2643SelectionLength = selectionLength, 2664SelectionLength = selectionLength, 2686SelectionLength = selectionLength, 2708SelectionLength = selectionLength 2812SelectionLength = value 2820control.SelectionLength = value; 2841SelectionLength = value 2848control.SelectionLength = value; 2876control.SelectionLength = value; 2886control.SelectionLength = value; 2911control.SelectionLength = value; 2929Assert.Throws<ArgumentOutOfRangeException>("value", () => control.SelectionLength = -1); 3016SelectionLength = 2, 3084SelectionLength = 1 3270SelectionLength = selectionLength, 3437SelectionLength = selectionLength, 3899SelectionLength = 2 3919SelectionLength = 2, 3940SelectionLength = 2, 4151SelectionLength = 2 4177control.SelectionLength = 2; 4202control.SelectionLength = 2; 4228SelectionLength = 2 5465SelectionLength = 2, 5983SelectionLength = 0 6002SelectionLength = 5 6872SelectionLength = 2 6910SelectionLength = 2
TextBoxTests.cs (1)
630SelectionLength = 2,
WinFormsControlsTest (1)
DragDrop.cs (1)
221textBox.SelectionLength = 0;
79 references to SelectionLength
System.Windows.Forms (13)
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxEditingControl.cs (8)
132if ((RightToLeft == RightToLeft.No && !(SelectionLength == 0 && SelectionStart == Text.Length)) || 133(RightToLeft == RightToLeft.Yes && !(SelectionLength == 0 && SelectionStart == 0))) 144if ((RightToLeft == RightToLeft.No && !(SelectionLength == 0 && SelectionStart == 0)) || 145(RightToLeft == RightToLeft.Yes && !(SelectionLength == 0 && SelectionStart == Text.Length))) 155int end = SelectionStart + SelectionLength; 167|| SelectionStart + SelectionLength < Text.IndexOf("\r\n", StringComparison.Ordinal))) 176if (SelectionLength != Text.Length) 193if (SelectionLength > 0 ||
System\Windows\Forms\Controls\RichTextBox\RichTextBox.cs (1)
1054return base.SelectionLength;
System\Windows\Forms\Controls\TextBox\TextBox.cs (1)
589if (SelectionLength == 0 && MouseButtons == MouseButtons.None)
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (2)
211if (SelectionLength != 0) 1052Select(value, SelectionLength);
System\Windows\Forms\Controls\ToolStrips\ToolStripTextBox.cs (1)
321get { return TextBox.SelectionLength; }
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\LinkAreaEditor.LinkAreaUI.cs (1)
120Value = new LinkArea(_sampleEdit.SelectionStart, _sampleEdit.SelectionLength);
System.Windows.Forms.Tests (65)
MaskedTextBoxTests.cs (1)
594control.SelectionLength.Should().Be(0);
System\Windows\Forms\DataGridViewTextBoxEditingControlTests.cs (7)
110Assert.Equal(0, control.SelectionLength); 1461Assert.Equal(4, control.SelectionLength); 1468Assert.Equal(4, control.SelectionLength); 1475Assert.Equal(0, control.SelectionLength); 1494Assert.Equal(0, control.SelectionLength); 1501Assert.Equal(0, control.SelectionLength); 1508Assert.Equal(4, control.SelectionLength);
TextBoxBaseTests.cs (54)
2593Assert.Equal(0, control.SelectionLength); 2647Assert.Equal(0, control.SelectionLength); 2669Assert.Equal(0, control.SelectionLength); 2691Assert.Equal(0, control.SelectionLength); 2720Assert.Equal(0, control.SelectionLength); 2768Assert.Equal(0, control.SelectionLength); 2775Assert.Equal(0, control.SelectionLength); 2786Assert.Equal(0, control.SelectionLength); 2795Assert.Equal(0, control.SelectionLength); 2815Assert.Equal(expected, control.SelectionLength); 2822Assert.Equal(expected, control.SelectionLength); 2843Assert.Equal(expected, control.SelectionLength); 2849Assert.Equal(expected, control.SelectionLength); 2878Assert.Equal(expected, control.SelectionLength); 2888Assert.Equal(expected, control.SelectionLength); 2990Assert.Equal(0, control.SelectionLength); 2997Assert.Equal(0, control.SelectionLength); 3054Assert.Equal(0, control.SelectionLength); 3064Assert.Equal(0, control.SelectionLength); 3223Assert.Equal(0, control.SelectionLength); 3234Assert.Equal(0, control.SelectionLength); 3277Assert.Equal(expectedSelectionLength, control.SelectionLength); 3288Assert.Equal(expectedSelectionLength, control.SelectionLength); 3307Assert.Equal(0, control.SelectionLength); 3318Assert.Equal(0, control.SelectionLength); 3342Assert.Equal(0, control.SelectionLength); 3355Assert.Equal(0, control.SelectionLength); 3386Assert.Equal(0, control.SelectionLength); 3399Assert.Equal(0, control.SelectionLength); 3451Assert.Equal(0, control.SelectionLength); 3465Assert.Equal(0, control.SelectionLength); 3866Assert.Equal(0, control.SelectionLength); 3884Assert.Equal(0, control.SelectionLength); 3904Assert.Equal(expectedSelectionLength, control.SelectionLength); 3925Assert.Equal(expectedSelectionLength, control.SelectionLength); 3947Assert.Equal(expectedSelectionLength, control.SelectionLength); 3970Assert.Equal(0, control.SelectionLength); 3999Assert.Equal(0, control.SelectionLength); 4216Assert.Equal(0, control.SelectionLength); 4232Assert.Equal(0, control.SelectionLength); 5489Assert.Equal(2, control.SelectionLength); 5502Assert.Equal(2, control.SelectionLength); 6233Assert.Equal(expectedSelectionLength, control.SelectionLength); 6240Assert.Equal(expectedSelectionLength, control.SelectionLength); 6263Assert.Equal(expectedSelectionLength, control.SelectionLength); 6273Assert.Equal(expectedSelectionLength, control.SelectionLength); 6323Assert.Equal(0, control.SelectionLength); 6330Assert.Equal(0, control.SelectionLength); 6344Assert.Equal(4, control.SelectionLength); 6351Assert.Equal(4, control.SelectionLength); 6370Assert.Equal(0, control.SelectionLength); 6380Assert.Equal(0, control.SelectionLength); 6405Assert.Equal(4, control.SelectionLength); 6415Assert.Equal(4, control.SelectionLength);
TextBoxTests.cs (3)
103Assert.Equal(0, control.SelectionLength); 654Assert.Equal(0, control.SelectionLength); 667Assert.Equal(0, control.SelectionLength);