| |
 |
How to: Change Tab Background in DXTabControl and Keep the Default Gradient and Highlight Effects
Xaml:MainWindow.xaml |
<dx:DXWindow
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:dx="http://schemas.devexpress.com/winfx/2008/xaml/core"
xmlns:dxe="http://schemas.devexpress.com/winfx/2008/xaml/editors"
xmlns:dxb="http://schemas.devexpress.com/winfx/2008/xaml/bars"
xmlns:dxcn="http://schemas.devexpress.com/winfx/2008/xaml/core/internal"
xmlns:dxmvvm="http://schemas.devexpress.com/winfx/2008/xaml/mvvm"
dx:ThemeManager.ThemeName="MetropolisLight"
x:Class="DXTabControlExample.MainWindow"
Title="Colorized tabs" Height="350" Width="550">
<Grid>
<dx:DXTabControl Name="tabControl">
<dx:DXTabItem Header="Coral" BackgroundColor="Coral"/>
<dx:DXTabItem Header="Chocolate" BackgroundColor="Chocolate"/>
<dx:DXTabItem Header="Cornsilk" BackgroundColor="Cornsilk"/>
<dx:DXTabItem Header="SandyBrown" BackgroundColor="SandyBrown"/>
<dx:DXTabItem Header="CadetBlue" BackgroundColor="CadetBlue"/>
<dx:DXTabItem Header="Violet" BackgroundColor="Violet"/>
</dx:DXTabControl>
</Grid>
</dx:DXWindow>
|
VB:Application.xaml.vb |
Imports System
Imports System.Collections.Generic
Imports System.Configuration
Imports System.Data
Imports System.Linq
Imports System.Threading.Tasks
Imports System.Windows
Namespace DXTabControlExample
Partial Public Class App
Inherits Application
Private Sub OnAppStartup_UpdateThemeName(ByVal sender As Object, ByVal e As StartupEventArgs)
DevExpress.Xpf.Core.ApplicationThemeHelper.UpdateApplicationThemeName()
End Sub
End Class
End Namespace
|
Xaml:Application.xaml |
<Application x:Class="DXTabControlExample.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
StartupUri="MainWindow.xaml" Startup="OnAppStartup_UpdateThemeName">
<Application.Resources>
</Application.Resources>
</Application>
|
Is this topic helpful?
Additional Feedback
Close
|