25 writes to Top
System.Windows.Forms (25)
winforms\Managed\System\WinForms\Control.cs (2)
11517
padding.
Top
= (int)Math.Round(padding.Top * dy);
11519
margins.
Top
= (int)Math.Round(margins.Top * dy);
winforms\Managed\System\WinForms\DataGridViewCellStyle.cs (1)
440
value.
Top
= Math.Max(0, value.Top);
winforms\Managed\System\WinForms\Layout\LayoutUtils.cs (2)
141
padding.
Top
= Math.Max(0, padding.Top);
364
padding.
Top
= padding.Left;
winforms\Managed\System\WinForms\Padding.cs (1)
248
Top
= 0;
winforms\Managed\System\WinForms\ScrollableControl.cs (1)
1686
padding.
Top
= value;
winforms\Managed\System\WinForms\ToolStripPanelRow.cs (18)
162
padding.
Top
= 0;
1529
cellMargin.
Top
-= spaceToFree;
1536
cellMargin.
Top
= 0;
1602
cellMargin.
Top
-= requiredSpace;
1609
cellMargin.
Top
= 0;
1620
cellMargin.
Top
+= spaceToFree;
1669
cellMargin.
Top
-= requiredSpace;
1676
cellMargin.
Top
= 0;
1700
cellMargin.
Top
+= spaceToFree;
1728
cellMargin.
Top
+= freedSpace;
1766
cellMargin.
Top
-= spaceToFree;
1774
cellMargin.
Top
= 0;
1864
nextCellMargin.
Top
-= requiredSpace;
1880
nextCellMargin.
Top
-= freedSpace;
1897
lastCellMargin.
Top
= Math.Max(0,locationToDrag.Y - nextCell.Bounds.Bottom);
1917
newCellMargin.
Top
= freedSpace - controlToDragWidth;
1937
cellMargin.
Top
= Math.Max(0,locationToDrag.Y-Row.Margin.Top);
1965
nextCellMargin.
Top
+= spaceOccupiedByCell;
82 references to Top
System.Windows.Forms (79)
winforms\Managed\System\WinForms\ArrangedElement.cs (2)
77
Debug.Assert((value.Right >= 0 && value.Left >= 0 && value.
Top
>= 0 && value.Bottom >=0), "who's setting margin negative?");
87
Debug.Assert((value.Right >= 0 && value.Left >= 0 && value.
Top
>= 0 && value.Bottom >=0), "who's setting padding negative?");
winforms\Managed\System\WinForms\Control.cs (2)
11517
padding.Top = (int)Math.Round(padding.
Top
* dy);
11519
margins.Top = (int)Math.Round(margins.
Top
* dy);
winforms\Managed\System\WinForms\DataGridViewButtonCell.cs (2)
745
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
749
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewCell.cs (2)
4374
rectPadding.Height = cellStyle.Padding.
Top
;
4546
borderAndPaddingWidths.Y += cellStyle.Padding.
Top
;
winforms\Managed\System\WinForms\DataGridViewCellStyle.cs (3)
429
if (value.Left < 0 || value.Right < 0 || value.
Top
< 0 || value.Bottom < 0)
440
value.Top = Math.Max(0, value.
Top
);
454
Debug.Assert(value.
Top
>= 0);
winforms\Managed\System\WinForms\DataGridViewCheckBoxCell.cs (2)
1228
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
1232
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewColumnHeaderCell.cs (4)
810
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
814
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
904
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
908
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewComboBoxCell.cs (3)
751
borderAndPaddingWidths.Y += cellStyle.Padding.
Top
;
2178
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
2182
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewImageCell.cs (2)
830
imgBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
834
imgBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewLinkCell.cs (2)
1030
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
1034
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewRowHeaderCell.cs (4)
799
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
803
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
877
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
881
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewTextBoxCell.cs (2)
726
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
730
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\DataGridViewTopLeftHeaderCell.cs (2)
322
valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.
Top
);
326
valBounds.Offset(cellStyle.Padding.Left, cellStyle.Padding.
Top
);
winforms\Managed\System\WinForms\GroupBox.cs (1)
220
return new Rectangle(padding.Left, fontHeight + padding.
Top
, Math.Max(size.Width - padding.Horizontal, 0), Math.Max(size.Height - fontHeight - padding.Vertical, 0));
winforms\Managed\System\WinForms\Layout\DockAndAnchorLayout.cs (1)
524
preferredSizeForAnchoring.Height -= containerPadding.
Top
;
winforms\Managed\System\WinForms\Layout\LayoutUtils.cs (4)
141
padding.Top = Math.Max(0, padding.
Top
);
325
rect.Y -= padding.
Top
;
333
rect.Y += padding.
Top
;
363
temp = padding.
Top
;
winforms\Managed\System\WinForms\Padding.cs (13)
144
return
Top
+ Bottom;
183
return new Padding(p1.Left + p2.Left, p1.
Top
+ p2.
Top
, p1.Right + p2.Right, p1.Bottom + p2.Bottom );
195
return new Padding(p1.Left - p2.Left, p1.
Top
- p2.
Top
, p1.Right - p2.Right, p1.Bottom - p2.Bottom );
204
return p1.Left == p2.Left && p1.
Top
== p2.
Top
&& p1.Right == p2.Right && p1.Bottom == p2.Bottom;
221
^ WindowsFormsUtils.RotateLeft(
Top
, 8)
228
return "{Left=" + Left.ToString(CultureInfo.CurrentCulture) + ",Top=" +
Top
.ToString(CultureInfo.CurrentCulture) + ",Right=" + Right.ToString(CultureInfo.CurrentCulture) + ",Bottom=" + Bottom.ToString(CultureInfo.CurrentCulture) + "}";
266
Debug.Assert(All == Left && Left ==
Top
&&
Top
== Right && Right == Bottom, "_all is true, but All/Left/Top/Right/Bottom inconsistent.");
361
args[nArg++] = intConverter.ConvertToString(context, culture, padding.
Top
);
378
new object[] {padding.Left, padding.
Top
, padding.Right, padding.Bottom});
winforms\Managed\System\WinForms\ScrollableControl.cs (2)
1550
|| owner.Padding.
Top
!= -1
1677
return owner.Padding.
Top
;
winforms\Managed\System\WinForms\ToolStrip.cs (3)
4292
gripRectangle.Y = Math.Max(0,displayRect.Top - Grip.Margin.
Top
);
5488
insertionRect = new Rectangle(item.Bounds.Right, owner.Margin.
Top
, ToolStrip.insertionBeamWidth, owner.Height- (owner.Margin.Vertical)-1);
5491
insertionRect = new Rectangle(item.Bounds.Left, owner.Margin.
Top
, ToolStrip.insertionBeamWidth, owner.Height - (owner.Margin.Vertical) -1);
winforms\Managed\System\WinForms\ToolStripDropDownButton.cs (1)
300
dropDownArrowRect = new Rectangle(0,options.client.Bottom + scaledDropDownArrowPadding.
Top
, ownerItem.Bounds.Width-1, dropDownArrowSize.Height);
winforms\Managed\System\WinForms\ToolStripDropDownMenu.cs (7)
142
rect = LayoutUtils.InflateRect(rect, new Padding(0, this.Padding.
Top
, 0, this.Padding.Bottom));
416
nextPoint = new Point(scaledCheckPadding.Left, scaledCheckPadding.
Top
);
421
nextPoint.Y = scaledImagePadding.
Top
;
431
nextPoint = new Point(1,scaledCheckPadding.
Top
);
451
nextPoint = new Point(1, scaledCheckPadding.
Top
);
473
nextPoint.Y = scaledTextPadding.
Top
;
478
nextPoint.Y = scaledArrowPadding.
Top
;
winforms\Managed\System\WinForms\ToolStripPanelRow.cs (11)
501
margins[i] = c.Margin.
Top
;
510
cachedBounds.X = Math.Max(0, cachedBounds.X - margins[i] - c.Margin.
Top
);
973
dragBounds.Height += (nextRowBounds.Height >> 2) + Row.Margin.Bottom + ToolStripPanel.RowsInternal[index + 1].Margin.
Top
;
1486
dragBounds.Y -= Row.Margin.
Top
+ ToolStripPanel.Padding.
Top
+4;
1528
if (cellMargin.
Top
>= spaceToFree) {
1535
spaceToFree -= lastCellOnRow.Margin.
Top
;
1764
if (cellMargin.
Top
>= spaceToFree) {
1773
spaceToFree -= lastCellOnRow.Margin.
Top
;
1863
if (nextCellMargin.
Top
> requiredSpace) {
1937
cellMargin.Top = Math.Max(0,locationToDrag.Y-Row.Margin.
Top
);
winforms\Managed\System\WinForms\ToolStripSplitStackLayout.cs (4)
330
y += itemMargin.
Top
;
343
y += itemMargin.
Top
;
461
lastBottom = y - itemMargin.
Top
;
468
y = lastTop + itemMargin.
Top
;
System.Workflow.ComponentModel (1)
AuthoringOM\Design\Dialogs\ThemeConfigurationDialog.cs (1)
549
Point top = new Point(this.propertiesGrid.Right + (this.dummyPreviewPanel.Left - this.propertiesGrid.Right) / 2, this.themePanel.Margin.
Top
);
System.WorkflowServices (2)
System\Workflow\Activities\Design\GradientPanel.cs (2)
85
frameRect.Y -= Margin.
Top
;
87
frameRect.Height += Margin.
Top
+ Margin.Bottom;