17 writes to Right
System.Windows.Forms (14)
System\Windows\Forms\Control.cs (2)
9697padding.Right = (int)Math.Round(padding.Right * dx); 9699margins.Right = (int)Math.Round(margins.Right * dx);
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyle.cs (1)
276value.Right = Math.Max(0, value.Right);
System\Windows\Forms\Controls\ToolStrips\ToolStripPanelRow.cs (1)
140padding.Right = 0;
System\Windows\Forms\Controls\ToolStrips\ToolStripPanelRow.HorizontalRowManager.cs (6)
120cellMargin.Right = 0; 127cellMargin.Right = 0; 197cellMargin.Right = 0; 204cellMargin.Right = 0; 266cellMargin.Right = 0; 273cellMargin.Right = 0;
System\Windows\Forms\Layout\LayoutUtils.cs (2)
147padding.Right = Math.Max(0, padding.Right); 428padding.Right = temp;
System\Windows\Forms\Layout\TableLayout.cs (1)
1258(elementMargin.Left, elementMargin.Right) = (elementMargin.Right, elementMargin.Left);
System\Windows\Forms\Scrolling\ScrollableControl.DockPaddingEdgesConverter.cs (1)
156padding.Right = value;
System.Windows.Forms.Primitives (1)
System\Windows\Forms\Padding.cs (1)
177private void ResetRight() => Right = 0;
System.Windows.Forms.Tests (2)
System\Windows\Forms\PaddingTests.cs (2)
253Right = value 288Right = value
126 references to Right
PresentationUI (15)
MS\Internal\Documents\SignatureSummaryDialog.cs (15)
544IntentTextWidth - CellPadding.Left - CellPadding.Right).Height; 554SummaryNameTextWidth - CellPadding.Left - CellPadding.Right).Height; 558SignByTextWidth - CellPadding.Left - CellPadding.Right).Height; 562LocaleTextWidth - CellPadding.Left - CellPadding.Right).Height; 569SummaryNameTextWidth - CellPadding.Left - CellPadding.Right).Height; 640iconXOffset = bounds.Right - (CellPadding.Right + IconWidth); 644statusXOffset = bounds.Right + CellPadding.Right - (IconWidth + SummaryNameTextWidth); 645intentXOffset = bounds.Right + CellPadding.Right + CellPadding.Left - 662IconWidth - CellPadding.Left - CellPadding.Right, 672SummaryNameTextWidth - CellPadding.Left - CellPadding.Right, 680IntentTextWidth - CellPadding.Left - CellPadding.Right, 694signByXOffset = bounds.Left + CellPadding.Left + CellPadding.Right; 695localeXOffset = bounds.Left + CellPadding.Left + CellPadding.Right + SignByTextWidth; 707SignByTextWidth - CellPadding.Left - CellPadding.Right, 715LocaleTextWidth - CellPadding.Left - CellPadding.Right,
System.Windows.Forms (43)
System\Windows\Forms\Control.cs (2)
9697padding.Right = (int)Math.Round(padding.Right * dx); 9699margins.Right = (int)Math.Round(margins.Right * dx);
System\Windows\Forms\Controls\DataGridView\DataGridViewButtonCell.cs (1)
700valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.cs (5)
3598rectPadding = new Rectangle(bounds.X, bounds.Y, cellStyle.Padding.Right, bounds.Height); 3603rectPadding.X = bounds.Left + cellStyle.Padding.Right; 3609rectPadding.X = bounds.Right - cellStyle.Padding.Right; 3610rectPadding.Width = cellStyle.Padding.Right; 3806borderAndPaddingWidths.Width += cellStyle.Padding.Right;
System\Windows\Forms\Controls\DataGridView\DataGridViewCellStyle.cs (3)
266if (value.Left < 0 || value.Right < 0 || value.Top < 0 || value.Bottom < 0) 276value.Right = Math.Max(0, value.Right); 291Debug.Assert(value.Right >= 0);
System\Windows\Forms\Controls\DataGridView\DataGridViewCheckBoxCell.cs (1)
1123valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewColumnHeaderCell.cs (2)
781valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top); 881valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewComboBoxCell.cs (2)
534borderAndPaddingWidths.Width += cellStyle.Padding.Right; 1945valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewImageCell.cs (1)
769DataGridView!.RightToLeftInternal ? cellStyle.Padding.Right : cellStyle.Padding.Left,
System\Windows\Forms\Controls\DataGridView\DataGridViewLinkCell.cs (1)
927valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewRowHeaderCell.cs (2)
662valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top); 746valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxCell.cs (1)
695valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\DataGridView\DataGridViewTopLeftHeaderCell.cs (1)
285valBounds.Offset(cellStyle.Padding.Right, cellStyle.Padding.Top);
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (1)
4189gripRectangle.X -= Grip.Margin.Right;
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownMenu.cs (5)
76int textPadding = (rightToLeft == RightToLeft.Yes) ? _textPadding.Right : _textPadding.Left; 367nextPoint.X = _checkRectangle.Right + _checkPadding.Right + _imagePadding.Left; 424nextPoint.X = _textRectangle.Right + _textPadding.Right + _arrowPadding.Left; 429_maxItemSize.Width = (_arrowRectangle.Right + _arrowPadding.Right) - _imageMarginBounds.Left; 437trimPadding += _textPadding.Right;
System\Windows\Forms\Controls\ToolStrips\ToolStripPanelRow.VerticalRowManager.cs (1)
68dragBounds.Width += (nextRowBounds.Width >> 2) + Row.Margin.Right + ToolStripPanel.RowsInternal[index + 1].Margin.Left;
System\Windows\Forms\Controls\ToolStrips\ToolstripProfessionalRenderer.cs (1)
1485bounds.Width = dropDownMenu.Width - bounds.X - dropDownMenu.Padding.Right;
System\Windows\Forms\Controls\ToolStrips\ToolStripSplitStackLayout.cs (2)
298x = lastRight - (itemMargin.Right + itemSize.Width); 313lastLeft = x + itemSize.Width + itemMargin.Right;
System\Windows\Forms\Layout\ArrangedElement.cs (2)
74Debug.Assert((value.Right >= 0 && value.Left >= 0 && value.Top >= 0 && value.Bottom >= 0), "who's setting margin negative?"); 86Debug.Assert((value.Right >= 0 && value.Left >= 0 && value.Top >= 0 && value.Bottom >= 0), "who's setting padding negative?");
System\Windows\Forms\Layout\FlowLayout.ContainerProxy.cs (1)
137newBounds.X = DisplayRect.Right - bounds.X - bounds.Width + ElementProxy.Margin.Left - ElementProxy.Margin.Right;
System\Windows\Forms\Layout\FlowLayout.cs (1)
325Debug.Assert(container.Children[0].Bounds.X == container.DisplayRectangle.X + container.DisplayRectangle.Width - container.Children[0].Bounds.Width - margin.Right);
System\Windows\Forms\Layout\LayoutUtils.cs (2)
147padding.Right = Math.Max(0, padding.Right); 427padding.Bottom = padding.Right;
System\Windows\Forms\Layout\TableLayout.cs (1)
1258(elementMargin.Left, elementMargin.Right) = (elementMargin.Right, elementMargin.Left);
System\Windows\Forms\Scrolling\ScrollableControl.cs (2)
344_scrollMargin.Width += Padding.Right; 466ctlRight += current.Margin.Right;
System\Windows\Forms\Scrolling\ScrollableControl.DockPaddingEdgesConverter.cs (2)
68|| _owner.Padding.Right != -1 146get => _owner is null ? _right : _owner.Padding.Right;
System.Windows.Forms.Design (5)
System\Windows\Forms\Design\Behavior\ResizeBehavior.cs (1)
184lines.Add(new SnapLine(SnapLineType.Vertical, loc.X + _primaryControl.Margin.Right, SnapLine.MarginRight, SnapLinePriority.Always));
System\Windows\Forms\Design\ControlCommandSet.cs (1)
481lines.Add(new SnapLine(SnapLineType.Vertical, pt.X + primaryControl.Width + primaryControl.Margin.Right, SnapLine.MarginRight, SnapLinePriority.Always));
System\Windows\Forms\Design\ControlDesigner.cs (1)
363snapLines.Add(new SnapLine(SnapLineType.Vertical, margin.Right + width, SnapLine.MarginRight, SnapLinePriority.Always));
System\Windows\Forms\Design\FlowLayoutPanelDesigner .cs (2)
153bounds.Left - (IsRtl ? margin.Right : margin.Left), 209bounds.X -= IsRtl ? margin.Right : margin.Left;
System.Windows.Forms.Primitives (18)
System\Windows\Forms\Internals\ScaleHelper.cs (1)
288ScaleToDpi(logicalPadding.Right, dpi),
System\Windows\Forms\Padding.cs (13)
122public readonly int Horizontal => Left + Right; 141&& Right == other.Right 148new(p1.Left + p2.Left, p1.Top + p2.Top, p1.Right + p2.Right, p1.Bottom + p2.Bottom); 154new(p1.Left - p2.Left, p1.Top - p2.Top, p1.Right - p2.Right, p1.Bottom - p2.Bottom); 160p1.Left == p2.Left && p1.Top == p2.Top && p1.Right == p2.Right && p1.Bottom == p2.Bottom; 167public override readonly int GetHashCode() => HashCode.Combine(Left, Top, Right, Bottom); 169public override readonly string ToString() => $"{{Left={Left},Top={Top},Right={Right},Bottom={Bottom}}}"; 197Debug.Assert(All == Left && Left == Top && Top == Right && Right == Bottom, "_all is true, but All/Left/Top/Right/Bottom inconsistent.");
System\Windows\Forms\PaddingConverter.cs (4)
52new object[] { padding.Left, padding.Top, padding.Right, padding.Bottom }); 62new object[] { padding.Left, padding.Top, padding.Right, padding.Bottom }); 96(int)propertyValues[nameof(Padding.Right)]!, 115return properties.Sort([nameof(Padding.All), nameof(Padding.Left), nameof(Padding.Top), nameof(Padding.Right), nameof(Padding.Bottom)]);
System.Windows.Forms.Tests (45)
System\Windows\Forms\DockPaddingEdgesTests.cs (5)
52Assert.Equal(expectedValue, owner.Padding.Right); 95Assert.Equal(3, owner.Padding.Right); 138Assert.Equal(3, owner.Padding.Right); 181Assert.Equal(expectedRight, owner.Padding.Right); 224Assert.Equal(3, owner.Padding.Right);
System\Windows\Forms\PaddingConverterTests.cs (19)
151{ nameof(Padding.Right), 3 }, 168{ nameof(Padding.Right), expected.Right }, 190{ nameof(Padding.Right), 3 }, 201{ nameof(Padding.Right), 3 }, 211{ nameof(Padding.Right), 3 }, 223{ nameof(Padding.Right), 3 }, 234{ nameof(Padding.Right), 3 }, 244{ nameof(Padding.Right), 3 }, 256{ nameof(Padding.Right), 3 }, 267{ nameof(Padding.Right), 3 }, 277{ nameof(Padding.Right), 3 }, 289{ nameof(Padding.Right), new object() }, 300{ nameof(Padding.Right), null }, 322{ nameof(Padding.Right), 3 }, 333{ nameof(Padding.Right), 3 }, 344{ nameof(Padding.Right), 3 } 382{ nameof(Padding.Right), 3 }, 407Assert.Equal(nameof(Padding.Right), properties[3].Name);
System\Windows\Forms\PaddingTests.cs (21)
19Assert.Equal(0, padding.Right); 34Assert.Equal(all, padding.Right); 56Assert.Equal(right, padding.Right); 70Assert.Equal(0, padding.Right); 88Assert.Equal(value, padding.Right); 106Assert.Equal(0, ((Padding)boxedPadding).Right); 126Assert.Equal(0, ((Padding)boxedPadding).Right); 143Assert.Equal(value, padding.Right); 158Assert.Equal(3, padding.Right); 176Assert.Equal(3, ((Padding)boxedPadding).Right); 193Assert.Equal(5, padding.Right); 208Assert.Equal(3, padding.Right); 226Assert.Equal(3, ((Padding)boxedPadding).Right); 243Assert.Equal(5, padding.Right); 258Assert.Equal(value, padding.Right); 268PropertyDescriptor property = properties[nameof(Padding.Right)]; 276Assert.Equal(0, ((Padding)boxedPadding).Right); 293Assert.Equal(value, padding.Right); 308Assert.Equal(3, padding.Right); 326Assert.Equal(3, ((Padding)boxedPadding).Right); 343Assert.Equal(5, padding.Right);