ExControls 2.1.0
See the version list below for details.
dotnet add package ExControls --version 2.1.0
NuGet\Install-Package ExControls -Version 2.1.0
<PackageReference Include="ExControls" Version="2.1.0" />
<PackageVersion Include="ExControls" Version="2.1.0" />
<PackageReference Include="ExControls" />
paket add ExControls --version 2.1.0
#r "nuget: ExControls, 2.1.0"
#:package ExControls@2.1.0
#addin nuget:?package=ExControls&version=2.1.0
#tool nuget:?package=ExControls&version=2.1.0
Extended controls for Windows Forms.
This library features extensions over some of the classic controls, most of which expand their ability to customize visuals and colors. The ExControls library was originally created as part of the GVDEditor program for the dark mode of the graphical interface.
These controls have been extended:
- ComboBox (also its variant in ToolStrip and DataGridView)
- DateTimePicker (partial)
- GroupBox
- CheckBox (also its variant in DataGridView)
- CheckedListBox
- MaskedTextBox
- NumericUpDown
- RadioButton
- TabControl
- TextBox
These controls have been added:
- LineSeparator
- TitleBar (custom title bar of
ExFormwith the main menu) - DockManager (dockable tool panels like Visual Studio or Rider)
These components have been extended:
- FolderBrowserDialog
Themes
ExTheme is a color palette. Ex* controls implement IThemeable and style themselves;
ExThemer.Apply(form.Controls, theme) walks the controls. Controls outside the library (DataGridView, ToolStrip,
Panel…) are styled by handlers registered with ExThemer.Register<T>.
Dock manager
ExDockManager lays out a window into the main content (Document) and tool panels (ExDockPanel) docked to the
left, right, top or bottom. Left and right zones span the full height, top and bottom ones lie between them; a zone
splits into nested rows and columns of groups, more panels in one group are tabs. The user resizes zones and groups with
splitters, hides a panel (×), collapses its group to the strip at the edge (pin, the panel slides out on a click) and
drags the caption (whole group) or a tab (one panel) with docking guides like in Visual Studio: a compass over a group
adds a tab (center) or splits the group (arrows), a compass over the document splits the document (the panel takes
only the height or width of the document, not the whole side), the guides at the edges add a column or row at the outer
edge of the zone; out of the guides it becomes a floating window (AllowFloating). The guides at the edges stay
visible, a compass near an edge moves away from them and stays while the cursor is on it. Panels are identified by
Key; the layout is saved as a single-line XML string with sizes in logical pixels:
var dock = new ExDockManager { Dock = DockStyle.Fill, Strings = new ExDockStrings { Hide = "Skryť" /* ... */ } };
Controls.Remove(content);
dock.Document.Controls.Add(content); // main content of the window
Controls.Add(dock);
dock.BringToFront(); // Fill after the docked tool strips
var errors = new ExDockPanel("errors", "Error List");
errors.Controls.Add(new ErrorListView { Dock = DockStyle.Fill });
dock.AddPanel(errors, ExDockSide.Bottom); // AddPanel(panel, tabWith) adds a tab
dock.AddPanel(output, errors, ExDockSide.Right); // splits the group of errors, output on its right
dock.SetZoneSize(ExDockSide.Bottom, 180);
dock.HidePanel(errors); // shown later by ShowPanel(errors)
dock.LoadLayout(settings.DockLayout); // after adding all panels; empty = keep, invalid = FormatException
// ...
settings.DockLayout = dock.SaveLayout();
The manager owns its panels (disposing it disposes the hidden ones too), applies a theme to the document and to all
panels (IThemeable) and raises PanelStateChanged (e.g. for a checked menu item), PanelClosing (the user hides a
panel, can be cancelled) and ActivePanelChanged. ShowPanel, HidePanel, DockPanel, FloatPanel and
SetAutoHide change the layout from code. The manager is created in code (it is not in the toolbox).
Custom title bar
ExTitleBar placed directly on an ExForm (docked to the top) replaces the system caption: the window icon on the left,
the window buttons on the right and controls such as the main MenuStrip in between (in a narrow window it collapses
into ☰). The system frame stays (shadow,
Aero Snap, Snap Layouts, animations); the free space of the title bar and empty parts of its tool strips drag the window.
It works on Windows 10+ with any FormBorderStyle except None; TitleBarBackColor and TitleBarForeColor of the
form color the title bar (an active window otherwise follows the Windows accent color on title bars), FormStyle
(Mica…) shows only in the system caption. The designer shows
the form without the system caption and frame, so the designed ClientSize matches the runtime window. Do not use
TextBox.PlaceholderText on an ExForm with UseCompositedPainting (WS_EX_COMPOSITED repaints it endlessly) -
use ExTextBox.HintText.
Visual Studio designer
In .NET projects the package brings its own designer extension (collection editor of ExOptionsView.Panels),
Visual Studio loads it automatically.
Changes in 2.1
ExDockManagerandExDockPanel(namespaceExControls.Docking): dockable tool panels with docking guides, auto-hide, floating windows and a saved layout, see Dock manager.ExThemer.KeepDefaultskeeps the properties a theme changes and restores them for the system style, so Ex* controls switched back from the custom style look like controls that never had it.ExTools.SetBorderColordraws a 1 px border in the theme color on list boxes, checked list boxes and tree views (also inDrawToBitmap).ExButton.DisabledForeColorsets the text color of a disabled button in the custom style.ExOptionsView.SearchHighlightColorandExOptionsPanel.HighlightMatcheshighlight the options matching the search.ExFormdefaults toFormStyle.Autoand keeps the system caption color;FormStyle.Defaultmade the active caption black in dark mode.ExCheckedListBoxrepaints only the items under the mouse instead of the whole list and raisesMouseMoveandMouseLeavein the custom style too.
Breaking changes in 2.0
System.Linq.Enumerableextensions renamed toExEnumerable.IsExternalInitpolyfill (.NET Framework) is internal.- Removed unused
ExStyle,ExStyleManager,IStylable,ISupportsDefaultStyle,ExApplication,ExAppTheme,ExStyleOld(members moved toExComboBoxStyle) and the unfinishedExFormDesigner(replaced byExTitleBar). ExTools.SetTitlebarAndBorderColor(IntPtr, ...)no longer swaps the text and border colors (wrong DWM attribute numbers, theFormoverload compensated them).ExForm.DarkTitleBarandTitleBarBackColorno longer reset each other (the caption color takes precedence), empty title bar colors restore the system colors also after the form is shown.
License
MIT. Toolbox icons come from .NET Windows Forms and Fluent UI System Icons (both MIT), see THIRD-PARTY-NOTICES.md in the package.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0-windows7.0 is compatible. net9.0-windows was computed. net10.0-windows was computed. net10.0-windows7.0 is compatible. |
| .NET Framework | net48 is compatible. net481 was computed. |
-
.NETFramework 4.8
- System.Resources.Extensions (>= 9.0.0)
-
net10.0-windows7.0
- Microsoft.Windows.Compatibility (>= 10.0.13)
- Microsoft.WinForms.Designer.SDK (>= 1.6.0)
-
net8.0-windows7.0
- Microsoft.Windows.Compatibility (>= 10.0.13)
- Microsoft.WinForms.Designer.SDK (>= 1.6.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 2.2.0 | 48 | 12/2/2026 |
| 2.1.0 | 76 | 11/21/2026 |
| 2.0.0 | 95 | 10/25/2026 |
| 1.0.0 | 324 | 6/22/2023 |
| 1.0.0-beta | 191 | 6/21/2023 |