Home Forums WPF controls Xceed DataGrid for WPF Datagrid look and feel (Windows 7 vs. Windows 10)

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • Spiralogy
    Participant
    Post count: 1
    #50758 |

    I’ve been developing a WPF application in Windows 7 and testing it on Windows 10. I should note that I’m using the Github Extended WPF toolkit found here.

    I’m sure this is a common issue, but the appearance of the Datagrid between Windows 7 and 10 is drastically different–in short, the Windows 10 datagrid looks… well, kinda bad. I’ve attached a few pictures that show the differences between them:

    Windows 7
    Windows 7 WPF

    Windows 10
    Windows 10 WPF

    I can live with most of these changes, but the appearance of the selected cell/datarow colors are my main issue (although if there were a way to get the same look and feel of Windows 7 on Windows 10, that’d be amazing too!) For starters, I can change the default Windows theme to AeroLite, but this does not seem to affect the Xceed datagrid at all, which is already… somewhat strange.

    I’ve searched around and found XAML that I thought would change the datarow “background selection” colors, but this did not work–it seems that they’re ‘baked’ into the basic theme files (which again, why are there forced styles that we can’t change?) Keep in mind that I’m using the nuget package, and while I’ve found other posts that reference XAML theme files (usually in a Program Files directory), these files simply aren’t on my machine and I have no idea where I can locate them to change the styling for these rows.

    In conclusion, I feel like I’m missing something pretty basic and any nudge in the right direction would be greatly appreciated. Thanks!

    Evance
    Keymaster
    Post count: 3

    Hi ,

    If you want to get the same look and feel of Windows 7 on Windows 10, you can apply Windows7 theme on your data grid control as follows:

    <Grid>
    <Grid.Resources>
    <xcdg:DataGridCollectionViewSource x:Key=”mySource”
    Source=”{Binding Source={x:Static Application.Current}, Path=DataSource}”>
    </xcdg:DataGridCollectionViewSource>
    </Grid.Resources>
    <xcdg:DataGridControl x:Name=”PersonsGrid”
    ItemsSource=”{Binding Source={StaticResource mySource}}”
    Margin=”20″>
    <xcdg:DataGridControl.View>
    <xcdg:TableflowView UseDefaultHeadersFooters=”False”
    ShowRowSelectorPane=”False”>
    <xcdg:TableflowView.FixedHeaders>
    <DataTemplate>
    <xcdg:ColumnManagerRow />
    </DataTemplate>
    </xcdg:TableflowView.FixedHeaders>
    <xcdg:TableflowView.Theme>
    <xcdg:Windows7Theme/>
    </xcdg:TableflowView.Theme>
    </xcdg:TableflowView>
    </xcdg:DataGridControl.View>
    </xcdg:DataGridControl>
    </Grid>

    Thanks you,

    Evance Kafando
    Xceed Software, Inc.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.