WPF Sentinel objects and how to check for an internal type
In .NET 4.5, you can now compare against BindingOperations.DisconnectedSource.
In .NET 4.5, you can now compare against BindingOperations.DisconnectedSource.
The WPF Viewbox control will grow / shrink its contents to the available space: http://www.wpftutorial.net/ViewBox.html Just place your TextBlock within a ViewBox: <Viewbox Stretch=”Uniform” Width=”50″ Height=”50″> <TextBlock Text=”Test” /> </Viewbox> Of course, your Viewbox is typically scaled by its container, but hopefully you get the idea!
You could set the BorderThickness for DataGridCell to 0 <DataGrid … SelectionUnit=”FullRow”> <DataGrid.CellStyle> <Style TargetType=”DataGridCell”> <Setter Property=”BorderThickness” Value=”0″/> <!– Update from comments. Remove the focus indication for the selected cell –> <Setter Property=”FocusVisualStyle” Value=”{x:Null}”/> </Style> </DataGrid.CellStyle> <!– … –> </DataGrid>
An ObservableCollection can be updated from UI exactly like any collection. The true difference is rather straightforward: ObservableCollection<T> implements INotifyCollectionChanged which provides notification when the collection is changed (you guessed ^^) It allows the binding engine to update the UI when the ObservableCollection is updated. However, BindingList<T> implements IBindingList. IBindingList provides notification on collection changes, … Read more