114 references to TabAlignment
System.Windows.Forms (15)
System\Windows\Forms\Controls\TabControl\TabControl.cs (15)
29
private
TabAlignment
_alignment =
TabAlignment
.Top;
100
[DefaultValue(
TabAlignment
.Top)]
103
public
TabAlignment
Alignment
118
if (_alignment is
TabAlignment
.Left or
TabAlignment
.Right)
142
if (_appearance == TabAppearance.FlatButtons && _alignment !=
TabAlignment
.Top)
293
if (_alignment is
TabAlignment
.Bottom or
294
TabAlignment
.Right)
299
if (_alignment is
TabAlignment
.Left or
300
TabAlignment
.Right)
317
if (_appearance == TabAppearance.FlatButtons && _alignment ==
TabAlignment
.Top)
564
if (!Multiline && (_alignment ==
TabAlignment
.Left || _alignment ==
TabAlignment
.Right))
566
_alignment =
TabAlignment
.Top;
System.Windows.Forms.Tests (99)
System\Windows\Forms\TabControlTests.cs (99)
23
Assert.Equal(
TabAlignment
.Top, control.Alignment);
223
[InlineData(
TabAlignment
.Bottom, 0x56010802)]
224
[InlineData(
TabAlignment
.Left, 0x56010A80)]
225
[InlineData(
TabAlignment
.Right, 0x56010A82)]
226
[InlineData(
TabAlignment
.Top, 0x56010800)]
227
public void TabControl_CreateParams_GetAlignment_ReturnsExpected(
TabAlignment
alignment, int expectedStyle)
273
[InlineData(TabAppearance.Normal,
TabAlignment
.Bottom, 0x56010802)]
274
[InlineData(TabAppearance.Normal,
TabAlignment
.Left, 0x56010A80)]
275
[InlineData(TabAppearance.Normal,
TabAlignment
.Right, 0x56010A82)]
276
[InlineData(TabAppearance.Normal,
TabAlignment
.Top, 0x56010800)]
277
[InlineData(TabAppearance.Buttons,
TabAlignment
.Bottom, 0x56010902)]
278
[InlineData(TabAppearance.Buttons,
TabAlignment
.Left, 0x56010B80)]
279
[InlineData(TabAppearance.Buttons,
TabAlignment
.Right, 0x56010B82)]
280
[InlineData(TabAppearance.Buttons,
TabAlignment
.Top, 0x56010900)]
281
[InlineData(TabAppearance.FlatButtons,
TabAlignment
.Bottom, 0x56010902)]
282
[InlineData(TabAppearance.FlatButtons,
TabAlignment
.Left, 0x56010B80)]
283
[InlineData(TabAppearance.FlatButtons,
TabAlignment
.Right, 0x56010B82)]
284
[InlineData(TabAppearance.FlatButtons,
TabAlignment
.Top, 0x56010908)]
285
public void TabControl_CreateParams_GetAppearance_ReturnsExpected(TabAppearance appearance,
TabAlignment
alignment, int expectedStyle)
363
yield return new object[] { true,
TabAlignment
.Top, true };
364
yield return new object[] { true,
TabAlignment
.Bottom, true };
365
yield return new object[] { true,
TabAlignment
.Left, true };
366
yield return new object[] { true,
TabAlignment
.Right, true };
368
yield return new object[] { false,
TabAlignment
.Top, false };
369
yield return new object[] { false,
TabAlignment
.Bottom, false };
370
yield return new object[] { false,
TabAlignment
.Left, true };
371
yield return new object[] { false,
TabAlignment
.Right, true };
376
public void TabControl_Alignment_Set_GetReturnsExpected(bool multiline,
TabAlignment
value, bool expectedMultiline)
396
yield return new object[] { true,
TabAlignment
.Top, true, 0 };
397
yield return new object[] { true,
TabAlignment
.Bottom, true, 1 };
398
yield return new object[] { true,
TabAlignment
.Left, true, 1 };
399
yield return new object[] { true,
TabAlignment
.Right, true, 1 };
401
yield return new object[] { false,
TabAlignment
.Top, false, 0 };
402
yield return new object[] { false,
TabAlignment
.Bottom, false, 1 };
403
yield return new object[] { false,
TabAlignment
.Left, true, 1 };
404
yield return new object[] { false,
TabAlignment
.Right, true, 1 };
409
public void TabControl_Alignment_SetWithHandle_GetReturnsExpected(bool multiline,
TabAlignment
value, bool expectedMultiline, int expectedCreatedCallCount)
442
[InvalidEnumData<
TabAlignment
>]
443
public void TabControl_Alignment_SetInvalidValue_ThrowsInvalidEnumArgumentException(
TabAlignment
value)
450
[InlineData(
TabAlignment
.Bottom)]
451
[InlineData(
TabAlignment
.Left)]
452
[InlineData(
TabAlignment
.Right)]
453
public void TabControl_Appearance_GetFlatButtonsWithAlignment_ReturnsExpected(
TabAlignment
alignment)
464
control.Alignment =
TabAlignment
.Top;
466
Assert.Equal(
TabAlignment
.Top, control.Alignment);
1618
yield return new object[] {
TabAlignment
.Bottom, true,
TabAlignment
.Bottom,
TabAlignment
.Bottom };
1619
yield return new object[] {
TabAlignment
.Left, true,
TabAlignment
.Left,
TabAlignment
.Top };
1620
yield return new object[] {
TabAlignment
.Right, true,
TabAlignment
.Right,
TabAlignment
.Top };
1621
yield return new object[] {
TabAlignment
.Top, true,
TabAlignment
.Top,
TabAlignment
.Top };
1622
yield return new object[] {
TabAlignment
.Bottom, false,
TabAlignment
.Bottom,
TabAlignment
.Bottom };
1623
yield return new object[] {
TabAlignment
.Left, false,
TabAlignment
.Top,
TabAlignment
.Top };
1624
yield return new object[] {
TabAlignment
.Right, false,
TabAlignment
.Top,
TabAlignment
.Top };
1625
yield return new object[] {
TabAlignment
.Top, false,
TabAlignment
.Top,
TabAlignment
.Top };
1630
public void TabControl_Multiline_Set_GetReturnsExpected(
TabAlignment
alignment, bool value,
TabAlignment
expectedAlignment1,
TabAlignment
expectedAlignment2)
1656
yield return new object[] {
TabAlignment
.Bottom, true,
TabAlignment
.Bottom, 1,
TabAlignment
.Bottom };
1657
yield return new object[] {
TabAlignment
.Left, true,
TabAlignment
.Left, 0,
TabAlignment
.Top };
1658
yield return new object[] {
TabAlignment
.Right, true,
TabAlignment
.Right, 0,
TabAlignment
.Top };
1659
yield return new object[] {
TabAlignment
.Top, true,
TabAlignment
.Top, 1,
TabAlignment
.Top };
1660
yield return new object[] {
TabAlignment
.Bottom, false,
TabAlignment
.Bottom, 0,
TabAlignment
.Bottom };
1661
yield return new object[] {
TabAlignment
.Left, false,
TabAlignment
.Top, 1,
TabAlignment
.Top };
1662
yield return new object[] {
TabAlignment
.Right, false,
TabAlignment
.Top, 1,
TabAlignment
.Top };
1663
yield return new object[] {
TabAlignment
.Top, false,
TabAlignment
.Top, 0,
TabAlignment
.Top };
1668
public void TabControl_Multiline_SetWithHandle_GetReturnsExpected(
TabAlignment
alignment, bool value,
TabAlignment
expectedAlignment1, int expectedCreatedCallCount,
TabAlignment
expectedAlignment2)