305 references to ControlStyles
System.Web.Mobile (1)
UI\MobileControls\Design\Util\GroupLabel.cs (1)
27SetStyle(ControlStyles.UserPaint, true);
System.Windows.Forms (277)
winforms\Managed\System\WinForms\AxHost.cs (1)
341SetStyle(ControlStyles.UserPaint, false);
winforms\Managed\System\WinForms\Button.cs (6)
64SetStyle(ControlStyles.StandardClick | 65ControlStyles.StandardDoubleClick, 158if (GetStyle(ControlStyles.UserPaint)) { 300if (GetStyle(ControlStyles.UserPaint)) { 307if (GetStyle(ControlStyles.UserPaint)) { 406Debug.Assert(!GetStyle(ControlStyles.UserPaint), "Shouldn't get BN_CLICKED when UserPaint");
winforms\Managed\System\WinForms\ButtonBase.cs (13)
74SetStyle( ControlStyles.SupportsTransparentBackColor | 75ControlStyles.Opaque | 76ControlStyles.ResizeRedraw | 77ControlStyles.OptimizedDoubleBuffer | 78ControlStyles.CacheText | // We gain about 2% in painting by avoiding extra GetWindowText calls 79ControlStyles.StandardClick, 84SetStyle(ControlStyles.UserMouse | 85ControlStyles.UserPaint, OwnerDraw); 942Debug.Assert(GetStyle(ControlStyles.UserPaint), "Shouldn't be in PaintControl when control is not UserPaint style"); 1139if (GetStyle(ControlStyles.UserPaint)) { 1190if (OwnerDraw != GetStyle(ControlStyles.UserPaint)) { 1191SetStyle(ControlStyles.UserMouse | ControlStyles.UserPaint, OwnerDraw);
winforms\Managed\System\WinForms\CheckBox.cs (2)
79SetStyle(ControlStyles.StandardClick | 80ControlStyles.StandardDoubleClick, false);
winforms\Managed\System\WinForms\CheckedListBox.cs (1)
123SetStyle(ControlStyles.ResizeRedraw, true);
winforms\Managed\System\WinForms\ComboBox.cs (8)
166SetStyle(ControlStyles.UserPaint | 167ControlStyles.UseTextForAccessibility | 168ControlStyles.StandardClick, false); 2207else if ((msg == NativeMethods.WM_CTLCOLORLISTBOX) && GetStyle(ControlStyles.UserPaint)) { 3688if (!Application.RenderWithVisualStyles && GetStyle(ControlStyles.UserPaint) == false && this.DropDownStyle == ComboBoxStyle.DropDownList && (FlatStyle == FlatStyle.Flat || FlatStyle == FlatStyle.Popup)) { 3757if (GetStyle(ControlStyles.UserPaint) == false && (FlatStyle == FlatStyle.Flat || FlatStyle == FlatStyle.Popup)) { 3811if (GetStyle(ControlStyles.UserPaint) == false && FlatStyle == FlatStyle.Flat || FlatStyle == FlatStyle.Popup) { 3815if (GetStyle(ControlStyles.UserPaint) == false && FlatStyle == FlatStyle.Flat || FlatStyle == FlatStyle.Popup) {
winforms\Managed\System\WinForms\ContainerControl.cs (1)
63SetStyle(ControlStyles.AllPaintingInWmPaint, false);
winforms\Managed\System\WinForms\Control.cs (81)
421private ControlStyles controlStyle; // User supplied control style 503SetStyle(ControlStyles.AllPaintingInWmPaint | 504ControlStyles.UserPaint | 505ControlStyles.StandardClick | 506ControlStyles.StandardDoubleClick | 507ControlStyles.UseTextForAccessibility | 508ControlStyles.Selectable,true); 1115if (!value.Equals(Color.Empty) && !GetStyle(ControlStyles.SupportsTransparentBackColor) && value.A < 255) 1207SetStyle(ControlStyles.ResizeRedraw, true); 1540return cacheTextCounter > 0 || GetStyle(ControlStyles.CacheText); 1547if (GetStyle(ControlStyles.CacheText) || !IsHandleCreated) { 1873if (GetStyle(ControlStyles.ContainerControl)) { 2395return GetStyle(ControlStyles.OptimizedDoubleBuffer); 2401SetStyle(ControlStyles.OptimizedDoubleBuffer | ControlStyles.AllPaintingInWmPaint, value); 2404SetStyle(ControlStyles.OptimizedDoubleBuffer, value); 2413return GetStyle(ControlStyles.DoubleBuffer | ControlStyles.UserPaint); 2571if (IsHandleCreated && !GetStyle(ControlStyles.UserPaint)) { 3195if (!c.IsEmpty && !GetStyle(ControlStyles.SupportsTransparentBackColor) && c.A < 255) 3642return GetStyle(ControlStyles.SupportsTransparentBackColor) && this.BackColor.A < 255; 3649return GetStyle(ControlStyles.SupportsTransparentBackColor) && c.A < 255; 3706return GetStyle( ControlStyles.ResizeRedraw ); 3709SetStyle( ControlStyles.ResizeRedraw, value ); 5644if ((controlStyle & ControlStyles.Selectable) != ControlStyles.Selectable) { 6528return ((ctl.controlStyle & ControlStyles.ContainerControl) == ControlStyles.ContainerControl && ctl is IContainerControl); 6625if ((controlStyle & ControlStyles.FixedWidth) != ControlStyles.FixedWidth && (specified & BoundsSpecified.Width) != 0) { 6630if ((controlStyle & ControlStyles.FixedHeight) != ControlStyles.FixedHeight && (specified & BoundsSpecified.Height) != 0) { 7082protected bool GetStyle(ControlStyles flag) { 7141if (!GetStyle(ControlStyles.UserPaint)) { 7230!GetStyle(ControlStyles.Opaque)); 7281(controlStyle & ControlStyles.Opaque) != ControlStyles.Opaque); 7330(controlStyle & ControlStyles.Opaque) != ControlStyles.Opaque); 8174if (GetStyle(ControlStyles.UserPaint)) { 8224if (IsHandleCreated && !GetStyle(ControlStyles.UserPaint)) { 8501if (GetStyle(ControlStyles.UserPaint)) { 8726if (!GetStyle(ControlStyles.UserPaint)){ 9383if (GetStyle(ControlStyles.ResizeRedraw)) { 9460if ((controlStyle & ControlStyles.ResizeRedraw) == ControlStyles.ResizeRedraw 9857if (!GetStyle(ControlStyles.Opaque)) { 10054if ((validationConstraints & ValidationConstraints.Selectable) == ValidationConstraints.Selectable && !c.GetStyle(ControlStyles.Selectable) || 10402if(GetStyle(ControlStyles.UserPaint)) { 11409if (DpiHelper.EnableDpiChangedHighDpiImprovements && !GetStyle(ControlStyles.UserPaint) && (Properties.GetObject(PropFont) == null)) { 11587if ((controlStyle & ControlStyles.FixedWidth) != ControlStyles.FixedWidth) { 11591if ((controlStyle & ControlStyles.FixedHeight) != ControlStyles.FixedHeight) { 11623if (!GetStyle(ControlStyles.FixedWidth)) { 11626if (!GetStyle(ControlStyles.FixedHeight)) { 12036protected void SetStyle(ControlStyles flag, bool value) { 12040if ((flag & ControlStyles.EnableNotifyMessage) != 0 && value) 12237return GetStyle(ControlStyles.ContainerControl); 12955if (GetStyle(ControlStyles.UserPaint)) { 12958if (!(GetStyle(ControlStyles.AllPaintingInWmPaint))) { 13276if (!GetStyle(ControlStyles.CacheText)) { 13359if (!GetStyle(ControlStyles.UserMouse)) { 13369if (button == MouseButtons.Left && GetStyle(ControlStyles.Selectable)) { 13473if (!GetStyle(ControlStyles.UserMouse)) { 13495if (!GetStyle(ControlStyles.UserMouse)) { 13509if ((controlStyle & ControlStyles.StandardClick) == ControlStyles.StandardClick) { 13652bool doubleBuffered = DoubleBuffered || (GetStyle(ControlStyles.AllPaintingInWmPaint) && DoubleBufferingEnabled); 13743if ((m.WParam == IntPtr.Zero) && GetStyle(ControlStyles.AllPaintingInWmPaint) || doubleBuffered) { 14114if ((controlStyle & ControlStyles.EnableNotifyMessage) == ControlStyles.EnableNotifyMessage) { 14163if (GetStyle(ControlStyles.UserPaint)) { 14172if (GetStyle(ControlStyles.UserPaint)) { 14289if (GetStyle(ControlStyles.StandardDoubleClick)) { 14301if (GetStyle(ControlStyles.StandardDoubleClick)) { 14319if (GetStyle(ControlStyles.StandardDoubleClick)) { 14361if (GetStyle(ControlStyles.StandardDoubleClick)) { 15688if (GetStyle(ControlStyles.ResizeRedraw)) { 19482if (ownerControl.GetStyle(ControlStyles.ContainerControl)) 19742if (ownerControl.GetStyle(ControlStyles.UseTextForAccessibility)) {
winforms\Managed\System\WinForms\DataGrid.cs (4)
330SetStyle(ControlStyles.UserPaint, true); 331SetStyle(ControlStyles.Opaque, false); 332SetStyle(ControlStyles.SupportsTransparentBackColor, false); 333SetStyle(ControlStyles.UserMouse, true);
winforms\Managed\System\WinForms\DataGridView.cs (4)
427SetStyle(ControlStyles.UserPaint | 428ControlStyles.Opaque | 429ControlStyles.UserMouse, true); 431SetStyle(ControlStyles.SupportsTransparentBackColor, false);
winforms\Managed\System\WinForms\DateTimePicker.cs (4)
135SetStyle(ControlStyles.FixedHeight, true); 141SetStyle(ControlStyles.UserPaint | 142ControlStyles.StandardClick, false); 149SetStyle(ControlStyles.UseTextForAccessibility, false);
winforms\Managed\System\WinForms\Form.cs (1)
4373if( !GetStyle(ControlStyles.Selectable) || !this.Enabled || !this.Visible) {
winforms\Managed\System\WinForms\GroupBox.cs (10)
56SetStyle(ControlStyles.ContainerControl, true); 57SetStyle(ControlStyles.SupportsTransparentBackColor | 58ControlStyles.UserPaint | 59ControlStyles.ResizeRedraw, OwnerDraw); 61SetStyle(ControlStyles.Selectable, false); 250SetStyle(ControlStyles.ContainerControl, true); 252SetStyle(ControlStyles.SupportsTransparentBackColor | 253ControlStyles.UserPaint | 254ControlStyles.ResizeRedraw | 255ControlStyles.UserMouse, OwnerDraw);
winforms\Managed\System\WinForms\Label.cs (9)
102SetStyle(ControlStyles.UserPaint | 103ControlStyles.SupportsTransparentBackColor | 104ControlStyles.OptimizedDoubleBuffer, IsOwnerDraw()); 106SetStyle(ControlStyles.FixedHeight | 107ControlStyles.Selectable, false); 109SetStyle(ControlStyles.ResizeRedraw, true); 425SetStyle(ControlStyles.UserPaint 426| ControlStyles.SupportsTransparentBackColor 427| ControlStyles.OptimizedDoubleBuffer, OwnerDraw);
winforms\Managed\System\WinForms\LinkLabel.cs (8)
86SetStyle(ControlStyles.AllPaintingInWmPaint 87| ControlStyles.OptimizedDoubleBuffer 88| ControlStyles.Opaque 89| ControlStyles.UserPaint 90| ControlStyles.StandardClick 91| ControlStyles.ResizeRedraw, true); 1153bool optimizeBackgroundRendering = !GetStyle(ControlStyles.OptimizedDoubleBuffer); 1882SetStyle(ControlStyles.Selectable, selectable);
winforms\Managed\System\WinForms\ListBox.cs (3)
156SetStyle(ControlStyles.UserPaint | 157ControlStyles.StandardClick | 158ControlStyles.UseTextForAccessibility, false);
winforms\Managed\System\WinForms\ListView.cs (3)
244SetStyle(ControlStyles.UserPaint, false); 245SetStyle(ControlStyles.StandardClick, false); 246SetStyle(ControlStyles.UseTextForAccessibility, false);
winforms\Managed\System\WinForms\MDIClient.cs (1)
51SetStyle(ControlStyles.Selectable, false);
winforms\Managed\System\WinForms\MonthCalendar.cs (2)
184SetStyle(ControlStyles.UserPaint, false); 185SetStyle(ControlStyles.StandardClick, false);
winforms\Managed\System\WinForms\Panel.cs (3)
50SetStyle(ControlStyles.Selectable | 51ControlStyles.AllPaintingInWmPaint, false); 52SetStyle(ControlStyles.SupportsTransparentBackColor, true);
winforms\Managed\System\WinForms\PictureBox.cs (8)
127SetStyle(ControlStyles.Opaque |ControlStyles.Selectable , false); 128SetStyle(ControlStyles.OptimizedDoubleBuffer|ControlStyles.SupportsTransparentBackColor, true); 974SetStyle(ControlStyles.FixedHeight | ControlStyles.FixedWidth, true); 978SetStyle(ControlStyles.FixedHeight | ControlStyles.FixedWidth, false);
winforms\Managed\System\WinForms\Printing\PrintPreviewControl.cs (3)
73SetStyle(ControlStyles.ResizeRedraw, false); 74SetStyle(ControlStyles.Opaque | ControlStyles.OptimizedDoubleBuffer, true);
winforms\Managed\System\WinForms\ProgressBar.cs (3)
74SetStyle(ControlStyles.UserPaint | 75ControlStyles.UseTextForAccessibility | 76ControlStyles.Selectable, false);
winforms\Managed\System\WinForms\PropertyGrid.cs (1)
5030SetStyle(ControlStyles.OptimizedDoubleBuffer, true);
winforms\Managed\System\WinForms\PropertyGridInternal\DocComment.cs (1)
63SetStyle(ControlStyles.Selectable, false);
winforms\Managed\System\WinForms\PropertyGridInternal\DropDownButton.cs (1)
26SetStyle(ControlStyles.Selectable, true);
winforms\Managed\System\WinForms\PropertyGridInternal\GridToolTip.cs (1)
38SetStyle(ControlStyles.UserPaint, false);
winforms\Managed\System\WinForms\PropertyGridInternal\PropertyGridView.cs (3)
198SetStyle(ControlStyles.OptimizedDoubleBuffer, true); 199SetStyle(ControlStyles.ResizeRedraw, false); 200SetStyle(ControlStyles.UserMouse, true);
winforms\Managed\System\WinForms\RadioButton.cs (2)
78SetStyle(ControlStyles.StandardClick, false); 571if (mevent.Button == MouseButtons.Left && GetStyle(ControlStyles.UserPaint)) {
winforms\Managed\System\WinForms\RichTextBox.cs (3)
3732bool oldStyle = GetStyle(ControlStyles.UserMouse); 3733SetStyle(ControlStyles.UserMouse, true); 3735SetStyle(ControlStyles.UserMouse, oldStyle);
winforms\Managed\System\WinForms\ScrollableControl.cs (2)
112SetStyle(ControlStyles.ContainerControl, true); 113SetStyle(ControlStyles.AllPaintingInWmPaint, false);
winforms\Managed\System\WinForms\ScrollBar.cs (3)
60SetStyle(ControlStyles.UserPaint, false); 61SetStyle(ControlStyles.StandardClick, false); 62SetStyle(ControlStyles.UseTextForAccessibility, false);
winforms\Managed\System\WinForms\SplitContainer.cs (2)
157SetStyle(ControlStyles.SupportsTransparentBackColor, true); 158SetStyle(ControlStyles.OptimizedDoubleBuffer, true);
winforms\Managed\System\WinForms\Splitter.cs (1)
67SetStyle(ControlStyles.Selectable, false);
winforms\Managed\System\WinForms\SplitterPanel.cs (1)
45SetStyle(ControlStyles.ResizeRedraw, true);
winforms\Managed\System\WinForms\StatusBar.cs (2)
66base.SetStyle(ControlStyles.UserPaint | ControlStyles.Selectable, false);
winforms\Managed\System\WinForms\StatusStrip.cs (2)
50SetStyle(ControlStyles.ResizeRedraw, true); 604SetStyle(ControlStyles.SupportsTransparentBackColor, true);
winforms\Managed\System\WinForms\TabControl.cs (1)
122SetStyle(ControlStyles.UserPaint, false);
winforms\Managed\System\WinForms\TableLayoutPanel.cs (1)
104SetStyle(ControlStyles.ResizeRedraw, true);
winforms\Managed\System\WinForms\TabPage.cs (1)
53SetStyle (ControlStyles.CacheText, true);
winforms\Managed\System\WinForms\TextBoxBase.cs (8)
120SetStyle(ControlStyles.FixedHeight, textBoxFlags[autoSize]); 121SetStyle(ControlStyles.StandardClick 122| ControlStyles.StandardDoubleClick 123| ControlStyles.UseTextForAccessibility 124| ControlStyles.UserPaint, false); 272SetStyle(ControlStyles.FixedHeight, value); 851SetStyle(ControlStyles.FixedHeight, false); 855SetStyle(ControlStyles.FixedHeight, AutoSize);
winforms\Managed\System\WinForms\ToolBar.cs (11)
140SetStyle(ControlStyles.UserPaint, false); 141SetStyle(ControlStyles.FixedHeight, AutoSize); 142SetStyle(ControlStyles.FixedWidth, false); 205SetStyle(ControlStyles.FixedWidth, AutoSize); 206SetStyle(ControlStyles.FixedHeight, false); 209SetStyle(ControlStyles.FixedHeight, AutoSize); 210SetStyle(ControlStyles.FixedWidth, false); 531SetStyle(ControlStyles.FixedWidth, AutoSize); 532SetStyle(ControlStyles.FixedHeight, false); 535SetStyle(ControlStyles.FixedHeight, AutoSize); 536SetStyle(ControlStyles.FixedWidth, false);
winforms\Managed\System\WinForms\ToolStrip.cs (5)
205SetStyle(ControlStyles.OptimizedDoubleBuffer | 206ControlStyles.AllPaintingInWmPaint | 207ControlStyles.SupportsTransparentBackColor, true); 209SetStyle(ControlStyles.Selectable, false); 3882SetStyle(ControlStyles.Selectable, TabStop);
winforms\Managed\System\WinForms\ToolStripComboBox.cs (2)
608SetStyle(ControlStyles.ResizeRedraw | ControlStyles.OptimizedDoubleBuffer, true);
winforms\Managed\System\WinForms\ToolStripContainer.cs (2)
36SetStyle(ControlStyles.ResizeRedraw | ControlStyles.SupportsTransparentBackColor, true);
winforms\Managed\System\WinForms\ToolStripContentPanel.cs (3)
38SetStyle(ControlStyles.ResizeRedraw | ControlStyles.SupportsTransparentBackColor, true); 386SetStyle(ControlStyles.OptimizedDoubleBuffer, true);
winforms\Managed\System\WinForms\ToolStripDropDown.cs (3)
1160SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.OptimizedDoubleBuffer, false); 1314SetStyle(ControlStyles.ResizeRedraw, true);
winforms\Managed\System\WinForms\ToolStripPanel.cs (8)
93SetStyle(ControlStyles.ResizeRedraw | ControlStyles.OptimizedDoubleBuffer | /*ControlStyles.AllPaintingInWmPaint |*/ControlStyles.SupportsTransparentBackColor, true); 94SetStyle(ControlStyles.Selectable, false); 384SetStyle(ControlStyles.Selectable, value); 823SetStyle(ControlStyles.AllPaintingInWmPaint, false); 824SetStyle(ControlStyles.OptimizedDoubleBuffer, true); 825SetStyle(ControlStyles.CacheText, true);
winforms\Managed\System\WinForms\TrackBar.cs (10)
76SetStyle(ControlStyles.UserPaint, false); 77SetStyle(ControlStyles.UseTextForAccessibility, false); 109SetStyle(ControlStyles.FixedHeight, autoSize); 110SetStyle(ControlStyles.FixedWidth, false); 113SetStyle(ControlStyles.FixedWidth, autoSize); 114SetStyle(ControlStyles.FixedHeight, false); 449SetStyle(ControlStyles.FixedHeight, autoSize); 450SetStyle(ControlStyles.FixedWidth, false); 454SetStyle(ControlStyles.FixedHeight, false); 455SetStyle(ControlStyles.FixedWidth, autoSize);
winforms\Managed\System\WinForms\TreeView.cs (4)
188SetStyle(ControlStyles.UserPaint, false); 189SetStyle(ControlStyles.StandardClick, false); 190SetStyle(ControlStyles.UseTextForAccessibility, false); 932SetStyle(ControlStyles.ResizeRedraw, true);
winforms\Managed\System\WinForms\UpDownBase.cs (12)
107SetStyle(ControlStyles.Opaque | ControlStyles.FixedHeight | ControlStyles.ResizeRedraw, true); 108SetStyle(ControlStyles.StandardClick, false); 109SetStyle(ControlStyles.UseTextForAccessibility, false); 1266SetStyle(ControlStyles.FixedHeight | 1267ControlStyles.FixedWidth, true); 1269SetStyle(ControlStyles.Selectable, false); 1435SetStyle(ControlStyles.Opaque | ControlStyles.FixedHeight | 1436ControlStyles.FixedWidth, true); 1438SetStyle(ControlStyles.Selectable, false);
winforms\Managed\System\WinForms\UserControl.cs (1)
52 SetStyle(ControlStyles.SupportsTransparentBackColor, true);
winforms\Managed\System\WinForms\WebBrowserBase.cs (1)
112this.SetStyle(ControlStyles.UserPaint, false);
System.Windows.Forms.DataVisualization (7)
WinForm\ChartWinControl.cs (7)
207 this.SetStyle(ControlStyles.ResizeRedraw, true); 209 this.SetStyle(ControlStyles.UserPaint, true); 210 this.SetStyle(ControlStyles.AllPaintingInWmPaint, true); 211 this.SetStyle(ControlStyles.SupportsTransparentBackColor, true); 212 this.SetStyle(ControlStyles.Selectable, true); 215 this.SetStyle(ControlStyles.DoubleBuffer, true); 220 this.SetStyle(ControlStyles.UserMouse, true);
System.Workflow.ComponentModel (20)
AuthoringOM\Design\DesignerWidgets.cs (14)
1083SetStyle(ControlStyles.OptimizedDoubleBuffer | 1084ControlStyles.UserPaint | 1085ControlStyles.SupportsTransparentBackColor | 1086ControlStyles.AllPaintingInWmPaint, true); 1399SetStyle(ControlStyles.OptimizedDoubleBuffer | 1400ControlStyles.UserPaint | 1401ControlStyles.SupportsTransparentBackColor | 1402ControlStyles.AllPaintingInWmPaint, true); 1714SetStyle(ControlStyles.OptimizedDoubleBuffer | 1715ControlStyles.UserPaint | 1716ControlStyles.AllPaintingInWmPaint | 1717ControlStyles.ResizeRedraw | 1718ControlStyles.Selectable | 1719ControlStyles.SupportsTransparentBackColor, true);
AuthoringOM\Design\WorkflowView.cs (6)
160SetStyle(ControlStyles.OptimizedDoubleBuffer | ControlStyles.UserPaint | ControlStyles.Opaque | ControlStyles.AllPaintingInWmPaint | ControlStyles.Selectable | ControlStyles.EnableNotifyMessage, true);