Here is this month’s edition of our WPF Tips & Tricks blog post. Hopefully you’ll find the following technical support tickets of value in your current WPF project.
We also created a new example that demonstrates how to create a real-time chart and compiled a KB article describing the multi-select capabilities of our WPF Data Editors.
Should you have any questions, feel free to comment below.
KB ARTICLE:
- How to implement multi-select when using DevExpress WPF Data Editors (ComboBoxEdit, LookUpEdit, ListBoxEdit) (T889444)
Our ComboBoxEdit, LookUpEdit, and ListBoxEdit allow end-users to select multiple items. In this KB article, we describe how to enable multiple selection and how to bind these editors to data and use them within WPF Data Grid cells.
EXAMPLE:
- How to: Create a Real-Time Chart (T894632)
TICKETS:
WPF Data Grid
- How to change the fill color in DataBarFormatConditions based upon a specific cell value (T898500)
- How to format tooltip values defined via CellToolTipBinding (T897646)
The Binding mechanism uses the
FormatString
property value only if the target property is aString
. To format cell tooltips defined via CellToolTipBinding, you can implement a custom converter or use our DXBinding feature:<dxg:GridColumn FieldName="Date" CellToolTipBinding="{DXBinding Expr='Date.ToString(`ddd, d MMM yyyy`)'}"> ... </dxg:GridColumn>
- How to center cell content in WPF Data Grid columns (T893136)
- How to merge a specific cell range with the same value in a WPF Data Grid column (T893139)
- How to hide WPF Data Grid control bands during print operations (T890413)
WPF Editors
- How to display TreeListView in LookUpEdit's popup and select child and parent nodes (T892988)
- How to implement a custom DateEdit and correct values automatically (T888590)
- How to keep a popup closed during text input in LookUpEdit (T892998)
- How to enable smart column generation in the LookUpEdit’s GridControl (T890940)
LookUpEdit does not enable smart column generation in its GridControl. To enable this feature, you can override the Embedded GridControl or set the
EnableSmartColumnsGeneration
property toTrue
at the implicit style level:<Window.Resources> <Style TargetType="dxg:GridControl"> <Setter Property="EnableSmartColumnsGeneration" Value="True"/> </Style> </Window.Resources>
WPF Docking
- How to display a hidden LayoutPanel when the mouse cursor hovers over the AutoHideGroup tray (T890480)
WPF Charting and Maps
- Legend - How to maintain Series checkbox state when new data is added in Series Template data binding mode (T893864)
- How to ensure that the topmost Y-Axis label is displayed (T895008)
- How to bind vector items to a view model in Map Editor mode (T895626)
- How to set MapControl’s background color when a map is exported to an image (T889416)
WPF Ribbon & Bars
- How to define BarButtonItem's tooltip duration when a DX theme with lightweight templates is used (T895793)
- How to stretch items in RibbonStatusBarControl (T893029)
WPF Scheduler
Other Controls
- How to enable the MouseWheel event in the Adorner Control when DX themes are used (T895687)
We patch ScrollViewer's default scrolling logic in our themes. With this, we implemented horizontal scrolling via the mouse, supported touch mouses, etc. To keep using default scrolling logic, set the
ScrollBarExtensions.HandlesDefaultMouseScrolling
attached property toFalse
:xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core" <UserControl.Resources> <Style TargetType="ScrollViewer"> <Setter Property="dx:ScrollBarExtensions.HandlesDefaultMouseScrolling" Value="False"/> </Style> </UserControl.Resources>
If you’ve come across a WPF-related support ticket you’d like to share with the rest of the DevExpress community, feel free to share the link in the comments section.