22 references to PreferredSize
System.Windows.Forms (21)
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (1)
1240Size preferredSize = PreferredSize;
System\Windows\Forms\Controls\DataGridView\DataGridViewTextBoxCell.cs (1)
214preferredHeight = txtEditingControl.PreferredSize.Height;
System\Windows\Forms\Controls\Labels\Label.cs (5)
640public virtual int PreferredHeight => PreferredSize.Height; 650public virtual int PreferredWidth => PreferredSize.Width; 837Size preferredSize = (AutoSize) ? PreferredSize : new Size(saveWidth, saveHeight); 1391Size preferredSize = PreferredSize; 1398Debug.Assert(!AutoSize || (AutoSize && !SelfSizing) || Size == PreferredSize,
System\Windows\Forms\Controls\PictureBox\PictureBox.cs (1)
961Size = PreferredSize;
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
372public new Size PreferredSize => base.PreferredSize;
System\Windows\Forms\Controls\ToolStrips\ToolStripPanel.cs (1)
640controlArray[i].Size = controlArray[i].PreferredSize;
System\Windows\Forms\Controls\ToolStrips\ToolStripPanelCell.cs (8)
162if (MaximumSize.Height >= Control.PreferredSize.Height) 171if (MaximumSize.Height + growBy >= Control.PreferredSize.Height) 173int freed = Control.PreferredSize.Height - MaximumSize.Height; 181if (MaximumSize.Height + growBy < Control.PreferredSize.Height) 195if (MaximumSize.Width >= Control.PreferredSize.Width) 204if (MaximumSize.Width + growBy >= Control.PreferredSize.Width) 206int freed = Control.PreferredSize.Width - MaximumSize.Width; 214if (MaximumSize.Width + growBy < Control.PreferredSize.Width)
System\Windows\Forms\Controls\ToolStrips\ToolStripPanelRow.HorizontalRowManager.cs (1)
438int controlToDragWidth = (toolStripToDrag.AutoSize) ? toolStripToDrag.PreferredSize.Width : toolStripToDrag.Width;
System\Windows\Forms\Controls\ToolStrips\ToolStripPanelRow.VerticalRowManager.cs (1)
444int controlToDragWidth = (toolStripToDrag.AutoSize) ? toolStripToDrag.PreferredSize.Height : toolStripToDrag.Height;
System\Windows\Forms\Form.cs (1)
4250Size prefSize = PreferredSize;
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\BorderSidesEditor.BorderSidesEditorUI.cs (1)
35Size = PreferredSize;