186 references to DesignMode
System.ComponentModel.TypeConverter (4)
System\Timers\Timer.cs (4)
85
if (
DesignMode
)
111
if (
DesignMode
)
203
if (
DesignMode
)
220
if (_synchronizingObject == null &&
DesignMode
)
System.Data.Common (1)
System\Data\Common\DbDataAdapter.cs (1)
314
if (
DesignMode
&& ((null == command) || (null == command.Connection) || string.IsNullOrEmpty(command.CommandText)))
System.IO.FileSystem.Watcher (1)
System\IO\FileSystemWatcher.cs (1)
691
return _initializing ||
DesignMode
;
System.Windows.Forms (113)
System\Windows\Forms\ActiveX\AxHost.cs (1)
865
if (
DesignMode
&& hook != _axState[s_renameEventHooked])
System\Windows\Forms\Control.cs (1)
3234
if (!IsHandleCreated ||
DesignMode
)
System\Windows\Forms\Control.Ime.cs (3)
177
if (!
DesignMode
&& ImeModeConversion.InputLanguageTable != ImeModeConversion.UnsupportedTable)
320
if (!
DesignMode
&& (inputLanguageTable != ImeModeConversion.UnsupportedTable) && Focused)
452
Debug.Assert(!
DesignMode
, "Shouldn't be updating cached ime mode at design-time");
System\Windows\Forms\Controls\Buttons\ButtonBase.cs (3)
159
if (
DesignMode
)
744
private void Animate() => Animate(!
DesignMode
&& Visible && Enabled && ParentInternal is not null);
841
if (!
DesignMode
&& AutoEllipsis && ShowToolTip && _textToolTip is not null)
System\Windows\Forms\Controls\ComboBox\ComboBox.cs (4)
1114
if (
DesignMode
)
1505
if (!
DesignMode
)
1528
if (!
DesignMode
)
1554
if (!
DesignMode
&& _childEdit is not null && m.HWnd == _childEdit.Handle)
System\Windows\Forms\Controls\DataGridView\DataGridView.cs (6)
3776
if (IsHandleCreated && !
DesignMode
)
3807
if (!_layout._dirty && !
DesignMode
)
3828
if (IsHandleCreated && !
DesignMode
)
3860
if (!_layout._dirty && !
DesignMode
)
3916
if (IsHandleCreated && !
DesignMode
)
3940
if (!_layout._dirty && !
DesignMode
)
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (5)
552
if (
DesignMode
11468
if (
DesignMode
)
14653
OnDataError(displayErrorDialogIfNoHandler: !
DesignMode
, e);
15012
if (
DesignMode
)
30046
if (nmhdr->code == PInvoke.TTN_GETDISPINFOW && !
DesignMode
)
System\Windows\Forms\Controls\DataGridView\DataGridView.ToolTip.cs (1)
23
if (_dataGridView.
DesignMode
|| !_dataGridView.IsHandleCreated)
System\Windows\Forms\Controls\Labels\Label.cs (2)
849
internal void Animate() => Animate(!
DesignMode
&& Visible && Enabled && ParentInternal is not null);
1150
if (!_controlToolTip && !
DesignMode
&& AutoEllipsis && _showToolTip && _textToolTip is not null)
System\Windows\Forms\Controls\ListView\ListView.cs (3)
1870
bool keepTopItem = IsHandleCreated && VirtualMode && View == View.Details && !
DesignMode
;
1879
if (IsHandleCreated && VirtualMode && !
DesignMode
)
4622
if (VirtualMode && VirtualListSize > -1 && !
DesignMode
)
System\Windows\Forms\Controls\ListView\ListView.ListViewNativeItemCollection.cs (1)
33
public bool OwnerIsDesignMode => _owner.
DesignMode
;
System\Windows\Forms\Controls\Menus\MenuStrip.cs (2)
169
if (!TabStop && !
DesignMode
&& IsAccessibilityObjectCreated)
187
if (!TabStop && !
DesignMode
&& IsAccessibilityObjectCreated)
System\Windows\Forms\Controls\PictureBox\PictureBox.cs (2)
498
if (!
DesignMode
)
972
private void Animate() => Animate(animate: !
DesignMode
&& Visible && Enabled && ParentInternal is not null);
System\Windows\Forms\Controls\ProgressBar\ProgressBar.cs (2)
58
else if (Style == ProgressBarStyle.Marquee && !
DesignMode
)
239
if (!
DesignMode
)
System\Windows\Forms\Controls\TabControl\TabControl.cs (4)
288
if (ShowToolTips && !
DesignMode
)
1648
if (
DesignMode
&& IsHandleCreated)
1862
if (c is not null && !
DesignMode
)
1976
if (c is not null && !
DesignMode
)
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
121
if (
DesignMode
)
System\Windows\Forms\Controls\TextBox\MaskedTextBox.cs (2)
462
if (!_flagState[s_isNullMask] && !Focused && !MaskFull && !
DesignMode
)
1708
else if (
DesignMode
) // Not RO and at design time, always show prompt.
System\Windows\Forms\Controls\TextBox\TextBoxBase.cs (1)
552
get => (
DesignMode
|| CanEnableIme) ? base.ImeModeBase : ImeMode.Disable;
System\Windows\Forms\Controls\ToolStrips\StatusStrip.cs (1)
166
if (
DesignMode
)
System\Windows\Forms\Controls\ToolStrips\ToolStrip.cs (9)
580
if (
DesignMode
&& actualDock == DockStyle.Left)
588
if (
DesignMode
&& Dock == DockStyle.Left)
1140
return
DesignMode
;
1304
if (!
DesignMode
)
1322
if (!
DesignMode
)
2442
if (!
DesignMode
)
3371
if (!
DesignMode
)
3977
if (!
DesignMode
&& !TabStop && (Focused || ContainsFocus))
4672
return new ReadOnlyControlCollection(this, isReadOnly: !
DesignMode
);
System\Windows\Forms\Controls\ToolStrips\ToolStripContainer.ToolStripContainerTypedControlCollection.cs (2)
47
if (!_owner.
DesignMode
)
63
if (!_owner.
DesignMode
)
System\Windows\Forms\Controls\ToolStrips\ToolStripControlHost.cs (1)
88
public override bool CanSelect => _control is not null && (
DesignMode
|| _control.CanSelect);
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDown.cs (3)
322
if (IsHandleCreated && !
DesignMode
)
953
if (
DesignMode
)
1754
if (!
DesignMode
&& IsFirstDropDown && OwnerItem is not null && TopLevel)
System\Windows\Forms\Controls\ToolStrips\ToolStripDropDownItem.cs (2)
575
if (Enabled ||
DesignMode
)
594
if (Enabled ||
DesignMode
)
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.cs (8)
1215
internal bool IsInDesignMode =>
DesignMode
;
1389
if (
DesignMode
)
1765
=> CanSelect && !
DesignMode
&& (_state[s_stateSelected] ||
1794
=>
DesignMode
|| ToolStripManager.ShowMenuFocusCues;
2024
=> Animate(!
DesignMode
&& Visible && Enabled && ParentInternal is not null);
2409
if (!
DesignMode
)
2452
if (!
DesignMode
)
3023
if (!CanSelect || !Enabled ||
DesignMode
)
System\Windows\Forms\Controls\ToolStrips\ToolStripLabel.cs (1)
67
get { return (IsLink ||
DesignMode
); }
System\Windows\Forms\Controls\ToolStrips\ToolStripMenuItem.cs (1)
996
if (!
DesignMode
)
System\Windows\Forms\Controls\ToolStrips\ToolStripPanel.cs (1)
165
return
DesignMode
;
System\Windows\Forms\Controls\ToolStrips\ToolStripSeparator.cs (1)
48
public override bool CanSelect =>
DesignMode
;
System\Windows\Forms\Controls\TreeView\TreeView.cs (2)
378
if (ShowNodeToolTips && IsHandleCreated && !
DesignMode
)
1876
if (ShowNodeToolTips && !
DesignMode
)
System\Windows\Forms\Controls\WebBrowser\WebBrowserBase.cs (6)
404
if (!
DesignMode
)
727
if (
DesignMode
)
794
internal bool IsUserMode => Site is null || !
DesignMode
;
906
if (!
DesignMode
)
1046
if (
DesignMode
)
1085
bool resetExtents =
DesignMode
;
System\Windows\Forms\DataBinding\BindingNavigator.cs (2)
515
if (!
DesignMode
)
573
_countItem.Text =
DesignMode
? CountItemFormat : string.Format(CultureInfo.CurrentCulture, CountItemFormat, count);
System\Windows\Forms\DataBinding\BindingSource.cs (2)
264
if (_state.HasFlag(BindingSourceStates.Initializing) ||
DesignMode
)
301
if (_state.HasFlag(BindingSourceStates.Initializing) ||
DesignMode
)
System\Windows\Forms\Form.ControlCollection.cs (1)
33
if (!_owner.TopLevel && !_owner.
DesignMode
)
System\Windows\Forms\Form.cs (6)
462
Debug.Assert(!
DesignMode
, "Form designer should not allow base size set in design mode.");
546
Control toLayout =
DesignMode
|| ParentInternal is null ? this : ParentInternal;
1965
if (!value && IsMdiContainer && !
DesignMode
)
4079
if (!
DesignMode
&& Enabled && Active)
4110
if (
DesignMode
)
4233
if (_formState[s_formStateAutoScaling] == 1 && !
DesignMode
)
System\Windows\Forms\Layout\Containers\SplitContainer.cs (6)
1259
if (
DesignMode
&& Width != DefaultSize.Width && value + Panel2MinSize + SplitterWidth > Width)
1266
if (
DesignMode
&& Height != DefaultSize.Height && value + Panel2MinSize + SplitterWidth > Height)
1288
if (
DesignMode
&& Width != DefaultSize.Width && value + Panel1MinSize + SplitterWidth > Width)
1295
if (
DesignMode
&& Height != DefaultSize.Height && value + Panel1MinSize + SplitterWidth > Height)
1317
if (
DesignMode
&& value + Panel1MinSize + Panel2MinSize > Width)
1324
if (
DesignMode
&& value + Panel1MinSize + Panel2MinSize > Height)
System\Windows\Forms\Layout\Containers\SplitContainer.SplitContainerTypedControlCollection.cs (2)
24
if (value is SplitterPanel && !_owner.
DesignMode
&& IsReadOnly)
40
if (_owner.
DesignMode
)
System\Windows\Forms\NotifyIcon.cs (2)
560
if (
DesignMode
)
629
if (
DesignMode
)
System\Windows\Forms\Panels\Panel.cs (1)
220
if (
DesignMode
&& _borderStyle == BorderStyle.None)
System\Windows\Forms\Timer.cs (2)
104
if (
DesignMode
)
154
if (Enabled && !
DesignMode
)
System\Windows\Forms\ToolTip\ToolTip.cs (6)
115
if (!
DesignMode
&& GetHandleCreated())
852
&& handlesCreated && !
DesignMode
)
911
if (_created.Contains(control) && handlesCreated && !
DesignMode
)
1127
if (
DesignMode
)
1245
if (exists && !empty && handlesCreated && !
DesignMode
)
1251
else if (empty && exists && !
DesignMode
)
System\Windows\Forms\UserControl.cs (1)
81
Control toLayout =
DesignMode
|| ParentInternal is null ? this : ParentInternal;
System.Windows.Forms.Design.Tests (1)
System\ComponentModel\Design\ByteViewerTests.cs (1)
1030
public new bool DesignMode => base.
DesignMode
;
System.Windows.Forms.Tests (64)
System\Windows\Forms\AxHostTests.cs (1)
3188
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\BindingSourceTests.cs (1)
837
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ButtonBaseTests.cs (1)
9291
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ButtonTests.cs (1)
3699
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\CheckBoxTests.cs (1)
654
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ColorDialogTests.cs (1)
367
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ColumnHeaderTests.cs (1)
1663
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ComboBoxTests.cs (1)
2843
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\CommonDialogTests.cs (1)
271
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ContainerControlTests.cs (1)
1433
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ControlTests.cs (1)
1166
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\DataGridViewTextBoxEditingControlTests.cs (1)
2126
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\DateTimePickerTests.cs (1)
1028
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\Design\ComponentEditorFormTests.cs (1)
402
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\Design\ComponentEditorPageTests.cs (1)
905
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\DomainUpDownTests.cs (1)
1492
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ErrorProviderTests.cs (1)
1367
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\FileDialogTests.cs (1)
830
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\FlowLayoutPanelTests.cs (1)
452
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\FontDialogTests.cs (1)
756
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\FormTests.cs (1)
2712
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\GroupBoxTests.cs (1)
2317
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\HelpProviderTests.cs (1)
567
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\HScrollBarTests.cs (1)
266
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\LabelTests.cs (1)
901
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ListBoxTests.cs (1)
6424
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ListControlTests.cs (1)
2932
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ListViewTests.cs (1)
6119
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\MenuStripTests.cs (1)
876
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\MonthCalendarTests.cs (1)
4748
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\PanelTests.cs (1)
1174
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\PictureBoxTests.cs (1)
2860
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ProgressBarTests.cs (1)
2604
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\PropertyGridTests.cs (1)
4165
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\RadioButtonTests.cs (1)
1547
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\RichTextBoxTests.cs (1)
10944
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ScrollableControlTests.cs (1)
2592
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ScrollBarTests.cs (1)
3180
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\SplitterTests.cs (1)
2325
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\StatusStripTests.cs (1)
1298
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\TabControlTests.cs (1)
5741
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\TableLayoutPanelTests.cs (1)
2191
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\TabPageTests.cs (1)
5255
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\TimerTests.cs (1)
467
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripButtonTests.cs (1)
1732
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripContentPanelTests.cs (1)
2036
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripControlHostTests.cs (1)
4651
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripDropDownItemTests.cs (1)
521
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripDropDownTests.cs (1)
5116
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripItemTests.cs (1)
15509
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripMenuItemTests.cs (1)
441
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripPanelTests.cs (1)
379
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripSeparatorTests.cs (1)
1643
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolStripTests.cs (1)
7552
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\ToolTipTests.cs (1)
919
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\TreeViewTests.cs (1)
7592
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\UpDownBaseTests.cs (1)
3125
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\UserControlTests.cs (1)
1817
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\VScrollBarTests.cs (1)
256
public new bool DesignMode => base.
DesignMode
;
System\Windows\Forms\WebBrowserTests.cs (1)
4686
public new bool DesignMode => base.
DesignMode
;
TextBoxBaseTests.cs (1)
7703
public new bool DesignMode => base.
DesignMode
;
TextBoxTests.cs (1)
701
public new bool DesignMode => base.
DesignMode
;
TrackBarTests.cs (1)
3298
public new bool DesignMode => base.
DesignMode
;
WebBrowserBaseTests.cs (1)
906
public new bool DesignMode => base.
DesignMode
;
WindowsFormsIntegration (2)
System\Windows\Integration\ElementHost.cs (2)
312
DesignerProperties.SetIsInDesignMode(childFrameworkElement, this.
DesignMode
);
791
if (!
DesignMode
&& m.WParam == IntPtr.Zero)