If you have any questions regarding this month’s WPF Tips & Tricks blog post, please comment below or submit a support ticket via the DevExpress Support Center. We’ll be happy to follow up.
WPF-Related Tips
- The default KeyToCommand behavior uses the KeyUp event to handle KeyGestures. You can set the EventName property to specify a different event.
To display controls in the ThemedWindow header, use the ThemedWindow.HeaderItems and ThemedWindow.ToolbarItems properties.
-
To hide the space reserved for the WPF menu item glyphs, you can set the attached BarManager.ShowGlyphsInPopupMenus property to False:
<dxb:MainMenuControl dxb:BarManager.ShowGlyphsInPopupMenus="False">
- Our WPF Data Grid can detect nested property changes if you enable the GridControl.DetectNestedPropertyChanges property.
- You can use EnumItemsSourceBehavior to bind an enumeration to the ItemsSource property of a control.
- ReadOnlyDependencyPropertyBindingBehavior allows you to bind read-only properties.
- You can prevent a dialog from closing when a dialog button is clicked. Set the CancelEventArgs.Cancel property in the button UICommand’s Command. You can find a code sample in the following section: DialogService > Define Dialog Buttons.
Interesting WPF-Related Support Tickets
WPF Data Grid
- Define ToolTip for TreeListView node images (T994154)
- Allow editing of the HyperlinkEdit column in GridControl (T1009670)
- Prevent the creation of certain columns when AutoGenerateColumns is enabled (T998481)
- TreeViewControl - How to manually set focus on the Filter Node (T999090)
WPF Editors
- Show Tree View in the combo box dropdown (T992076)
Use the LookUpEdit.PopupContentTemplate property to specify the dropdown content.
- Make the background and borders transparent in DateEdit (T1003285)
- Change TrackBarEdit's track style (T1003774)
You can use the ThumbStyle, NearTrackStyle, and FarTrackStyle properties to customize the track bar.
Charts & Map control
- Crosshair Cursor - How to hide items with zero values (T1007946)
- How to hide the SidePoint label using a binding expression (T1011714)
- How to change the custom element template font size depending on the map zoom level (T992742)
- How to generate MapCustomElements with ListSourceDataAdapter (T991982)
Miscellaneous
- How to display the Properties Panel when DiagramControl is used instead of DiagramDesignerControl (T1011018)
- Reorder default BarButtonItems from the tabbed DocumentPanel Context Menu (T997150)
- Define TileNavPane’s dropdown Height (T996936)
To specify dropdown height, declare the TileNavPaneBar implicit style:
<Style TargetType="dxnavi:TileNavPaneBar" xmlns:dxnavi=http://schemas.devexpress.com/winfx/2008/xaml/navigation/internal> <Setter Property="Height" Value="70" /> </Style>
- ThemedMessageBox – Highlight the Default and Cancel buttons (T998835)
- Assign Tooltips for Property Grid Control category buttons (T1006676)
- RadialContextMenu - How to return to the collapsed view after a BarButtonItem is clicked (T1006593)
- Scheduler - How to change the appointment subject’s alignment (T1008842)
WPF Documentation and Examples
- We recently revamped our WPF Data Grid’s Data Editing help section - Data Editing and Validation.
- The following performance-related topics have been updated: Frequent Data Updates and Managing Multi-Thread Data Updates.
- We created a new example that demonstrates how to specify ApplicationActivator for the NotificationService: How to use NotificationService to create interactive notifications.
Before we let you go…
Our online help system includes a feedback form (pictured below). If you encounter a help topic that fails to address your questions, please tell us how we can improve the topic or how we can extend its content to better serve your needs.