Telerik Forums
UI for WPF Forum
1 answer
85 views

I found out that the ReadOnlyBackgroundBrush from Theme setting is not applied in GridView.

In some grid I have a whole column that should not be edited from the User, while some grid is only editable when the user has the right to do it and some rows are ReadOnly depending on the state of the Row.

Are there theme colors that are dedicated for GridView or is there a generic way to apply a color to GridView and it's cells/rows in ReadOnly state? 

Stenly
Telerik team
 answered on 24 Feb 2025
1 answer
51 views

Hi,

I am working on a tool for an application based on one of the examples. I have noticed that when I create the pushpin using a Path then it is only selected if I hit exactly on the lines of the image being drawn.

This could be a general XAML question, but not really sure how this works. I would like to have the pin selected when I hit the area defined by the image.

My datatemplate:

            <DataTemplate x:Key="PositionPushPinTemplate">
                <Grid telerik:MapLayer.Location="{Binding Location}"
                      telerik:RadToolTipService.PlacementRectangle="-38 0 0 0"
                      telerik:RadToolTipService.Placement="Top"
                      telerik:RadToolTipService.ToolTipContent="{Binding}"
                      telerik:RadToolTipService.ToolTipContentTemplate="{StaticResource LocationLabelTemplate}"
                      HorizontalAlignment="Center"
                      VerticalAlignment="Top">
                    <Path Canvas.Top="2.989" Canvas.Left="3.188" 
                          Data="{Binding Icon}" 
                          Stretch="Uniform" 
                          Fill="{Binding Color}" 
                          Width="26" 
                          Height="26" 
                          Margin="0,0,0,0" 
                          RenderTransformOrigin="0.5,0.5">
                        <Path.RenderTransform>
                            <TransformGroup>
                                <TransformGroup.Children>
                                    <RotateTransform Angle="0" />
                                    <ScaleTransform ScaleX="1" ScaleY="1" />
                                </TransformGroup.Children>
                            </TransformGroup>
                        </Path.RenderTransform>
                    </Path>
                </Grid>
            </DataTemplate>
hhgm
Top achievements
Rank 1
Iron
Iron
Iron
 answered on 21 Feb 2025
1 answer
112 views

Hi,

I'm working with the Telerik RadPasswordBox and I'm currently using the Windows 11 theme along with the NoXAML DLL in a WPF project. However, I am unable to apply a dark background color to the RadPasswordBox when it's hovered over or clicked.

Here’s what I’m trying to achieve:

  • Hover Effect: When the user hovers over the RadPasswordBox, I want the background to change to a dark color.
  • Click Effect: Similarly, when the RadPasswordBox is clicked, the background should remain dark until the focus is lost.

I have tried setting the Background property in the relevant triggers, but it does not seem to work as expected. Could anyone provide guidance or a solution on how to implement this with the Windows 11 theme and NoXAML DLL?

Thank you for your help!
below is my code

 <telerik:RadPasswordBox
     x:Name="ClientIdTextBox"
     Grid.Column="1"
     Width="600"
     BorderThickness="0"
     FontSize="20"
     Foreground="#A7A3DC"
     Style="{StaticResource CustomPasswordBoxStyle}"
     WatermarkContent="ClientID">
     <telerik:RadPasswordBox.WatermarkTemplate>
         <DataTemplate>
             <TextBlock
                 Foreground="#A7A3DC"
                 Opacity="0.7"
                 Text="{Binding}" />
         </DataTemplate>
     </telerik:RadPasswordBox.WatermarkTemplate>
 </telerik:RadPasswordBox>
  <Style x:Key="CustomPasswordBoxStyle" TargetType="telerik:RadPasswordBox">
      <Setter Property="Background" Value="Transparent" />
      <Setter Property="BorderThickness" Value="0" />
      <Setter Property="Foreground" Value="#A7A3DC" />
      <Setter Property="FontSize" Value="20" />
      <Style.Triggers>
          <Trigger Property="IsMouseOver" Value="True">
              <Setter Property="Background" Value="#080812" />
          </Trigger>
          <Trigger Property="IsFocused" Value="True">
              <Setter Property="Background" Value="#080812" />
          </Trigger>
      </Style.Triggers>
  </Style>

 

Stenly
Telerik team
 answered on 21 Feb 2025
1 answer
68 views
I'm experiencing an issue with RadTabControl where I cannot navigate between tabs after implementing a custom template for RadTabItem. When I remove the custom template, the navigation works fine, but as soon as I add the template back, I lose the ability to switch between tabs.
Below is my xaml code
<UserControl
    x:Class="agent_ui.Views.SettingsView"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:local="clr-namespace:agent_ui.Views"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
    d:DesignHeight="1450"
    d:DesignWidth="800"
    mc:Ignorable="d">

    <UserControl.Resources>

        <Style TargetType="telerik:RadButton">
            <Setter Property="BorderThickness" Value="0" />
            <Setter Property="Background" Value="#ff6c1e" />
            <Setter Property="Padding" Value="10,5" />
            <Setter Property="Margin" Value="0,0,0,10" />
            <Setter Property="HorizontalAlignment" Value="Left" />
            <Setter Property="MinWidth" Value="120" />
            <Setter Property="MaxWidth" Value="160" />
        </Style>

        <Style TargetType="telerik:RadToggleButton">
            <Setter Property="BorderThickness" Value="0" />
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="Padding" Value="10,5" />
        </Style>

        <Style TargetType="telerik:RadTabControl">
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="BorderBrush" Value="Transparent" />
            <Setter Property="BorderThickness" Value="0" />
            <Setter Property="Padding" Value="0" />
            <Setter Property="Margin" Value="0" />
            <Setter Property="Template">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadTabControl">
                        <Grid Background="#1E1E1E">
                            <Grid.RowDefinitions>
                                <RowDefinition Height="Auto" />
                                <RowDefinition Height="*" />
                            </Grid.RowDefinitions>

                            <!--  Tab Header Panel  -->
                            <Border
                                Grid.Row="0"
                                MinHeight="45"
                                Background="#252525">
                                <TabPanel
                                    x:Name="HeaderPanel"
                                    IsItemsHost="True"
                                    KeyboardNavigation.TabIndex="1" />
                            </Border>

                            <!--  Content Panel  -->
                            <Border
                                x:Name="ContentPanel"
                                Grid.Row="1"
                                Background="Transparent"
                                BorderThickness="0"
                                KeyboardNavigation.DirectionalNavigation="Contained"
                                KeyboardNavigation.TabIndex="2">
                                <ContentPresenter
                                    x:Name="PART_SelectedContentHost"
                                    Margin="2"
                                    ContentSource="SelectedContent" />
                            </Border>
                        </Grid>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
        <Style TargetType="telerik:RadListBox">
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="BorderBrush" Value="#2E2F45" />
            <Setter Property="BorderThickness" Value="1" />
            <Setter Property="Padding" Value="0" />
            <Setter Property="Margin" Value="0" />
        </Style>
        <Style TargetType="telerik:RadTabItem">
            <Setter Property="Background" Value="Transparent" />
            <Setter Property="BorderBrush" Value="Transparent" />
            <Setter Property="BorderThickness" Value="0" />
            <Setter Property="Padding" Value="20,10" />
            <Setter Property="MinHeight" Value="45" />
            <Setter Property="Margin" Value="0" />
            <Setter Property="Foreground" Value="#808080" />
            <!--  Set all directional templates to ensure proper functionality  -->
            <Setter Property="TopTemplate">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadTabItem">
                        <Grid>
                            <Border
                                x:Name="Border"
                                Padding="{TemplateBinding Padding}"
                                Background="{TemplateBinding Background}"
                                BorderBrush="{TemplateBinding BorderBrush}"
                                BorderThickness="{TemplateBinding BorderThickness}">
                                <Grid>
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="*" />
                                        <RowDefinition Height="2" />
                                    </Grid.RowDefinitions>

                                    <ContentPresenter
                                        x:Name="HeaderContentPresenter"
                                        Grid.Row="0"
                                        HorizontalAlignment="Center"
                                        VerticalAlignment="Center"
                                        ContentSource="Header"
                                        RecognizesAccessKey="True" />

                                    <Rectangle
                                        x:Name="SelectionIndicator"
                                        Grid.Row="1"
                                        Height="2"
                                        Fill="#ff6c1e"
                                        Visibility="Collapsed" />
                                </Grid>
                            </Border>
                            <!--  Required parts for tab functionality  -->
                            <ContentPresenter
                                x:Name="PART_Content"
                                Margin="{TemplateBinding Padding}"
                                ContentSource="Content"
                                Visibility="Collapsed" />
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsSelected" Value="True">
                                <Setter Property="Foreground" Value="#FFFFFF" />
                                <Setter Property="Panel.ZIndex" Value="1" />
                                <Setter TargetName="SelectionIndicator" Property="Visibility" Value="Visible" />
                                <Setter Property="Background" Value="#2D2D2D" />
                            </Trigger>
                            <Trigger Property="IsMouseOver" Value="True">
                                <Setter Property="Background" Value="#2D2D2D" />
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
            <!--  Copy the same template for other directions  -->
            <Setter Property="BottomTemplate">
                <Setter.Value>
                    <ControlTemplate TargetType="telerik:RadTabItem">
                        <!--  Same template as TopTemplate  -->
                        <Grid>
                            <Border
                                x:Name="Border"
                                Padding="{TemplateBinding Padding}"
                                Background="{TemplateBinding Background}"
                                BorderBrush="{TemplateBinding BorderBrush}"
                                BorderThickness="{TemplateBinding BorderThickness}">
                                <Grid>
                                    <Grid.RowDefinitions>
                                        <RowDefinition Height="2" />
                                        <RowDefinition Height="*" />
                                    </Grid.RowDefinitions>

                                    <Rectangle
                                        x:Name="SelectionIndicator"
                                        Grid.Row="0"
                                        Height="2"
                                        Fill="#ff6c1e"
                                        Visibility="Collapsed" />

                                    <ContentPresenter
                                        x:Name="HeaderContentPresenter"
                                        Grid.Row="1"
                                        HorizontalAlignment="Center"
                                        VerticalAlignment="Center"
                                        ContentSource="Header"
                                        RecognizesAccessKey="True" />
                                </Grid>
                            </Border>
                            <ContentPresenter
                                x:Name="PART_Content"
                                Margin="{TemplateBinding Padding}"
                                ContentSource="Content"
                                Visibility="Collapsed" />
                        </Grid>
                        <ControlTemplate.Triggers>
                            <Trigger Property="IsSelected" Value="True">
                                <Setter Property="Foreground" Value="#FFFFFF" />
                                <Setter Property="Panel.ZIndex" Value="1" />
                                <Setter TargetName="SelectionIndicator" Property="Visibility" Value="Visible" />
                                <Setter Property="Background" Value="#2D2D2D" />
                            </Trigger>
                            <Trigger Property="IsMouseOver" Value="True">
                                <Setter Property="Background" Value="#2D2D2D" />
                            </Trigger>
                        </ControlTemplate.Triggers>
                    </ControlTemplate>
                </Setter.Value>
            </Setter>
        </Style>
    </UserControl.Resources>
    <Grid Margin="4">
        <Border
            Background="Transparent"
            BorderBrush="#2E2F45"
            BorderThickness="0"
            CornerRadius="5">
            <telerik:RadTabControl>
                <!--  Discovery Configuration Tab  -->
                <telerik:RadTabItem Header="Discovery Configuration">
                    <StackPanel Margin="20">
                        <TextBlock
                            Margin="0,0,0,20"
                            FontSize="18"
                            FontWeight="Bold"
                            Foreground="#ffffff"
                            Text="Add a new folder for discovery" />

                        <StackPanel Orientation="Horizontal">
                            <telerik:RadButton Command="{Binding SelectFolderClassificationCommand}">
                                <StackPanel Orientation="Horizontal ">
                                    <telerik:RadGlyph FontSize="16" Glyph="&#xe105;" />
                                    <TextBlock
                                        Margin="5,0,0,0"
                                        FontSize="18"
                                        Text=" Select Folder" />
                                </StackPanel>
                            </telerik:RadButton>
                            <TextBlock
                                Margin="10,0,0,0"
                                VerticalAlignment="Center"
                                Background="Gray"
                                Text="{Binding FolderPath}" />
                        </StackPanel>

                        <Grid>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="*" />
                            </Grid.ColumnDefinitions>

                            <StackPanel Grid.Column="0">
                                <TextBlock
                                    FontSize="18"
                                    Foreground="#ffffff"
                                    Text="Start Time" />
                                <telerik:RadDatePicker
                                    Margin="0,0,0,20"
                                    DisplayDate="{Binding DisplayTime}"
                                    SelectedDate="{Binding StartTime}" />
                            </StackPanel>

                            <StackPanel Grid.Column="1" Margin="10,0,0,0">
                                <TextBlock
                                    FontSize="18"
                                    Foreground="#ffffff"
                                    Text="End Time" />
                                <telerik:RadDatePicker
                                    DisplayDate="{Binding StartTime}"
                                    IsEnabled="{Binding IsStartTimeSelected}"
                                    SelectedDate="{Binding EndTime}" />
                            </StackPanel>
                        </Grid>

                        <TextBlock
                            Margin="0,0,0,10"
                            FontSize="18"
                            Foreground="#ffffff"
                            Text="Interval Time" />

                        <Border
                            BorderBrush="#2E2F45"
                            BorderThickness="1"
                            CornerRadius="5">
                            <Grid Margin="10,5">
                                <Grid.ColumnDefinitions>
                                    <ColumnDefinition Width="Auto" />
                                    <ColumnDefinition Width="*" />
                                </Grid.ColumnDefinitions>

                                <telerik:RadGlyph
                                    Grid.Column="0"
                                    Margin="0,0,10,0"
                                    FontSize="20"
                                    Foreground="#A7A3DC"
                                    Glyph="&#xe113;" />

                                <telerik:RadWatermarkTextBox
                                    Grid.Column="1"
                                    Width="600"
                                    Background="Transparent"
                                    BorderThickness="0"
                                    Text="{Binding IntervalTime, Mode=TwoWay}"
                                    WatermarkContent="Enter time in Mins..." />
                            </Grid>
                        </Border>

                        <telerik:RadButton
                            MinWidth="140"
                            MaxWidth="200"
                            Command="{Binding SelectFolderClassificationCommandAdd}">
                            <StackPanel Orientation="Horizontal">
                                <telerik:RadGlyph FontSize="16" Glyph="&#xe105;" />
                                <TextBlock
                                    Margin="5,0,0,0"
                                    FontSize="18"
                                    Text=" Add Folder path" />
                            </StackPanel>
                        </telerik:RadButton>

                        <TextBlock Foreground="Red" Text="{Binding DiscoveryError}" />

                        <TextBlock
                            FontSize="16"
                            Foreground="#A7A3DC"
                            Text="Add Your Folder and click scan for Discover your sensitive data" />

                        <telerik:RadListBox MaxHeight="300" ItemsSource="{Binding FolderClassifications}">
                            <telerik:RadListBox.ItemTemplate>
                                <DataTemplate>
                                    <Grid>
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="50" />
                                            <ColumnDefinition Width="20" />
                                            <ColumnDefinition Width="*" />
                                            <ColumnDefinition Width="210" />
                                            <ColumnDefinition Width="30" />
                                        </Grid.ColumnDefinitions>

                                        <telerik:RadButton
                                            Grid.Column="0"
                                            Command="{Binding RunClassification}"
                                            Content="Scan"
                                            FontSize="12" />

                                        <telerik:RadGlyph
                                            Grid.Column="1"
                                            FontSize="16"
                                            Glyph="&#xe8b7;" />

                                        <TextBlock
                                            Grid.Column="2"
                                            Margin="5,0"
                                            VerticalAlignment="Center"
                                            FontSize="12"
                                            Text="{Binding Source}" />

                                        <TextBlock
                                            Grid.Column="3"
                                            VerticalAlignment="Center"
                                            FontSize="12"
                                            Foreground="{Binding ClassificationStatusColor}"
                                            Text="{Binding ClassificationStatus}" />

                                        <telerik:RadButton Grid.Column="4" Command="{Binding DeleteCommand}">
                                            <telerik:RadGlyph FontSize="11" Glyph="&#xe10a;" />
                                        </telerik:RadButton>
                                    </Grid>
                                </DataTemplate>
                            </telerik:RadListBox.ItemTemplate>
                        </telerik:RadListBox>
                    </StackPanel>
                </telerik:RadTabItem>

                <!--  Control Configuration Tab  -->
                <telerik:RadTabItem Header="Control (File Activity) Configuration">
                    <StackPanel Margin="20">
                        <StackPanel Orientation="Horizontal">
                            <telerik:RadButton Command="{Binding SelectFolderCommand}">
                                <StackPanel Orientation="Horizontal">
                                    <telerik:RadGlyph FontSize="16" Glyph="&#xe105;" />
                                    <TextBlock
                                        Margin="5,0,0,0"
                                        FontSize="18"
                                        Text=" Select Folder" />
                                </StackPanel>
                            </telerik:RadButton>
                            <TextBlock
                                Margin="10,0,0,0"
                                VerticalAlignment="Center"
                                Background="Gray"
                                Text="{Binding ControlFolderPath}" />
                        </StackPanel>

                        <Grid>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="*" />
                                <ColumnDefinition Width="*" />
                            </Grid.ColumnDefinitions>

                            <StackPanel Grid.Column="0">
                                <TextBlock
                                    FontSize="18"
                                    Foreground="#ffffff"
                                    Text="Start Time" />
                                <telerik:RadDatePicker DisplayDate="{Binding DisplayTime}" SelectedDate="{Binding ControlStartTime}" />
                            </StackPanel>

                            <StackPanel Grid.Column="1" Margin="10,0,0,0">
                                <TextBlock
                                    FontSize="18"
                                    Foreground="#ffffff"
                                    Text="End Time" />
                                <telerik:RadDatePicker
                                    DisplayDate="{Binding ControlStartTime}"
                                    IsEnabled="{Binding IsControlStartTimeSelected}"
                                    SelectedDate="{Binding ControlEndTime}" />
                            </StackPanel>
                        </Grid>

                        <telerik:RadButton
                            MinWidth="140"
                            MaxWidth="200"
                            Command="{Binding SelectFolderCommandAdd}">
                            <StackPanel Orientation="Horizontal">
                                <telerik:RadGlyph FontSize="16" Glyph="&#xe105;" />
                                <TextBlock
                                    Margin="5,0,0,0"
                                    FontSize="18"
                                    Text=" Add Folder path" />
                            </StackPanel>
                        </telerik:RadButton>

                        <TextBlock Foreground="Red" Text="{Binding ControlError}" />

                        <TextBlock
                            FontSize="16"
                            Foreground="#A7A3DC"
                            Text="Add Your Folder and click scan for Monitoring your data" />

                        <telerik:RadListBox MaxHeight="350" ItemsSource="{Binding FolderMonitors}">
                            <telerik:RadListBox.ItemTemplate>
                                <DataTemplate>
                                    <Grid>
                                        <Grid.ColumnDefinitions>
                                            <ColumnDefinition Width="50" />
                                            <ColumnDefinition Width="20" />
                                            <ColumnDefinition Width="*" />
                                            <ColumnDefinition Width="210" />
                                            <ColumnDefinition Width="30" />
                                        </Grid.ColumnDefinitions>

                                        <telerik:RadToggleButton
                                            Grid.Column="0"
                                            Command="{Binding StartMonitoringCommand}"
                                            Content="{Binding ButtonText}"
                                            IsChecked="{Binding IsMonitoring}" />

                                        <telerik:RadGlyph
                                            Grid.Column="1"
                                            FontSize="16"
                                            Glyph="&#xe8b7;" />

                                        <TextBlock
                                            Grid.Column="2"
                                            Margin="5,0"
                                            VerticalAlignment="Center"
                                            FontSize="12"
                                            Text="{Binding FolderPath}" />

                                        <TextBlock
                                            Grid.Column="3"
                                            VerticalAlignment="Center"
                                            FontSize="12"
                                            Foreground="{Binding MonitoringStatusColor}"
                                            Text="{Binding MonitoringStatus}" />

                                        <telerik:RadButton Grid.Column="4" Command="{Binding DeleteFolderMonitoringCommand}">
                                            <telerik:RadGlyph FontSize="11" Glyph="&#xe10a;" />
                                        </telerik:RadButton>
                                    </Grid>
                                </DataTemplate>
                            </telerik:RadListBox.ItemTemplate>
                        </telerik:RadListBox>
                    </StackPanel>
                </telerik:RadTabItem>

                <!--  Agent Info Tab  -->
                <telerik:RadTabItem Header="Agent Info">
                    <StackPanel Margin="20">
                        <TextBlock
                            Margin="0,0,0,20"
                            FontSize="20"
                            Foreground="#ffffff"
                            Text="Agent Information" />

                        <!--  Client ID  -->
                        <StackPanel Margin="0,0,0,10" Orientation="Horizontal">
                            <TextBlock
                                Width="120"
                                VerticalAlignment="Center"
                                FontSize="16"
                                Foreground="#A7A3DC"
                                Text="Client ID:" />
                            <telerik:RadWatermarkTextBox
                                Width="250"
                                Background="#2E2F45"
                                BorderThickness="0"
                                IsReadOnly="True"
                                Text="{Binding ClientId}" />
                        </StackPanel>

                        <!--  Client Secret  -->
                        <StackPanel Margin="0,0,0,10" Orientation="Horizontal">
                            <TextBlock
                                Width="120"
                                VerticalAlignment="Center"
                                FontSize="16"
                                Foreground="#A7A3DC"
                                Text="Client Secret:" />
                            <telerik:RadWatermarkTextBox
                                Width="250"
                                Background="#2E2F45"
                                BorderThickness="0"
                                IsReadOnly="True"
                                Text="{Binding ClientSecret}" />
                        </StackPanel>

                        <!--  Client Secret  -->
                        <StackPanel Margin="0,0,0,10" Orientation="Horizontal">
                            <TextBlock
                                Width="120"
                                VerticalAlignment="Center"
                                FontSize="16"
                                Foreground="#A7A3DC"
                                Text="Agent Group:" />
                            <telerik:RadWatermarkTextBox
                                Width="250"
                                Background="#2E2F45"
                                BorderThickness="0"
                                IsReadOnly="True"
                                Text="{Binding AgentGroup}" />
                        </StackPanel>


                        <!--  Scan Configurations Title  -->
                        <TextBlock
                            Margin="0,20,0,10"
                            FontSize="18"
                            Foreground="#ffffff"
                            Text="Scan Configurations" />

                        <!--  Max Depth  -->
                        <StackPanel Margin="0,0,0,10" Orientation="Horizontal">
                            <TextBlock
                                Width="120"
                                VerticalAlignment="Center"
                                FontSize="16"
                                Foreground="#A7A3DC"
                                Text="Max Depth:" />
                            <telerik:RadWatermarkTextBox
                                Width="250"
                                Background="#2E2F45"
                                BorderThickness="0"
                                IsReadOnly="True"
                                Text="{Binding MaxDepth}" />
                        </StackPanel>

                        <!--  Files Per Folder  -->
                        <StackPanel Margin="0,0,0,10" Orientation="Horizontal">
                            <TextBlock
                                Width="120"
                                VerticalAlignment="Center"
                                FontSize="16"
                                Foreground="#A7A3DC"
                                Text="Files Per Folder:" />
                            <telerik:RadWatermarkTextBox
                                Width="250"
                                Background="#2E2F45"
                                BorderThickness="0"
                                IsReadOnly="True"
                                Text="{Binding MaxFilesPerFolder}" />
                        </StackPanel>

                        <!--  Files Per Scan  -->
                        <StackPanel Margin="0,0,0,10" Orientation="Horizontal">
                            <TextBlock
                                Width="120"
                                VerticalAlignment="Center"
                                FontSize="16"
                                Foreground="#A7A3DC"
                                Text="Files Per Scan:" />
                            <telerik:RadWatermarkTextBox
                                Width="250"
                                Background="#2E2F45"
                                BorderThickness="0"
                                IsReadOnly="True"
                                Text="{Binding TotalFilesPerScan}" />
                        </StackPanel>

                        <!--  Create Dump Button  -->
                        <telerik:RadButton Command="{Binding CreateDumpCommand}">
                            <StackPanel Orientation="Horizontal">
                                <telerik:RadGlyph FontSize="16" Glyph="&#xe105;" />
                                <TextBlock
                                    Margin="5,0,0,0"
                                    FontSize="18"
                                    Text=" Create Dump" />
                            </StackPanel>
                        </telerik:RadButton>
                    </StackPanel>
                </telerik:RadTabItem>
            </telerik:RadTabControl>
        </Border>
    </Grid>
</UserControl>
Stenly
Telerik team
 answered on 21 Feb 2025
2 answers
80 views

Hello, I am using the WPF-RadTimeLine control and would like to change the color and font size of the interval headings.

Hello, I am using the WPF-RadTimeLine control and would like to change the color and font size of the interval headings.

What is the procedure here?

Gerhard
Top achievements
Rank 1
Iron
Iron
 answered on 18 Feb 2025
1 answer
194 views

I need to modify the default scrollbar appearance of the Telerik WPF GridView . Currently, the scrollbar is too wide/thick for my design requirements.

I'm using Telerik UI for WPF with XAML, and despite trying multiple approaches including:

  • Modifying the ScrollViewer style
  • Attempting to override the default template
  • Trying various XAML styling techniques None of these attempts have successfully achieved the desired result.

Specific customization needs:

  • Reduce the width of the scrollbar to make it slimmer
  • Change the color to light grey
  • Add rounded corners to the scrollbar thumb
  • Make the scrollbar background transparent

I'm looking for guidance on how to achieve these styling requirements, either through built-in Telerik properties or custom XAML styling. Since I'm not using any Telerik themes, I need a solution that works with the default styling approach. If anyone has successfully customized the DataGrid scrollbar without themes, I would greatly appreciate a working example.

Current behavior is shown in the attached screenshot where you can see the default thick scrollbar. Any suggestions or solutions would be helpful.
Below is the XAML code that I have been working on

                <telerik:RadGridView 
AutoGenerateColumns="False"
ShowGroupPanel="False"
ItemsSource="{Binding LogEntries}"
RowIndicatorVisibility="Collapsed"
FrozenColumnsSplitterVisibility="Collapsed"
GridLinesVisibility="None"
IsReadOnly="True"
SelectionMode="Single"
Background="Transparent"
BorderBrush="Transparent"
BorderThickness="0"
Margin="0,10,0,0"
MaxHeight="350"
Foreground="White"
EnableRowVirtualization="True"
EnableColumnVirtualization="True">

                <telerik:RadGridView.Resources>
                    <Style TargetType="telerik:GridViewCell">
                        <Setter Property="CurrentBorderBrush" Value="Transparent" />
                    </Style>
                    <Style TargetType="telerik:GridViewHeaderCell">
                        <Setter Property="Background" Value="#363736" />
                        <Setter Property="Template">
                            <Setter.Value>
                                <ControlTemplate TargetType="telerik:GridViewHeaderCell">
                                    <Grid>
                                        <Border Background="{TemplateBinding Background}" BorderBrush="#4A4A4A" BorderThickness="0,0,1,1" />
                                        <ContentPresenter HorizontalAlignment="Center" VerticalAlignment="Center" />
                                    </Grid>
                                </ControlTemplate>
                            </Setter.Value>
                        </Setter>
                        <Style.Triggers>
                            <Trigger Property="IsMouseOver" Value="True">
                                <Setter Property="Background" Value="#363736" />
                                <Setter Property="Foreground" Value="White" />
                            </Trigger>
                        </Style.Triggers>
                    </Style>
                    <Style TargetType="telerik:GridViewDataColumn">
                        <Setter Property="Background" Value="#FF2C2C2C" />
                        <Style.Triggers>
                            <Trigger Property="IsMouseOver" Value="True">
                                <Setter Property="Background" Value="#FF2C2C2C" />
                            </Trigger>
                        </Style.Triggers>
                    </Style>
                </telerik:RadGridView.Resources>
                <telerik:RadGridView.RowStyle>
                    <Style TargetType="telerik:GridViewRow">
                        <Setter Property="BorderThickness" Value="0" />
                        <Setter Property="BorderBrush" Value="Transparent" />
                        <Setter Property="Background" Value="Transparent" />
                    </Style>
                </telerik:RadGridView.RowStyle>

                <telerik:RadGridView.Columns>
                        <telerik:GridViewDataColumn Header="Source" 
                              DataMemberBinding="{Binding Source}"/>
                        <telerik:GridViewDataColumn Header="Timestamp" 
                              DataMemberBinding="{Binding Timestamp}"/>
                        <telerik:GridViewDataColumn Header="user_name" 
                              DataMemberBinding="{Binding user_name}"/>
                        <telerik:GridViewDataColumn Header="event_name" 
                              DataMemberBinding="{Binding event_name}"/>
                        <telerik:GridViewDataColumn Header="file_name" 
                              DataMemberBinding="{Binding file_name}"/>
                        <telerik:GridViewDataColumn Header="Desc" 
                              DataMemberBinding="{Binding Desc}"/>
                        <telerik:GridViewDataColumn Header="process_name" 
                              DataMemberBinding="{Binding process_name}"/>
                    </telerik:RadGridView.Columns>
                </telerik:RadGridView>

Martin Ivanov
Telerik team
 answered on 17 Feb 2025
1 answer
614 views

Do I need to put the license key on the build machine, or only on the dev machine? (As I understand, an invalid license would cause a compile errors / warnings during build, and also watermarks when application starts, so I'm guessing that the build machine needs a license).

 

I see that the license can either be in %appdata% or in the root folder of the project, or embedded in the project as TerlerikLicense.cs with:

[assembly: global::Telerik.Licensing.EvidenceAttribute

 

You also write: "Do not commit the file to source control as this is your personal license key"

So how does it work with adding you TelerikLicense.cs to the project? Wouldn't adding it to the project is like adding it to git? (since entire project is committed)

 

Thanks

Martin Ivanov
Telerik team
 answered on 17 Feb 2025
1 answer
74 views

Hi Telerik Team,

I am currently using the RadTreeListView in a WPF project and have encountered the following issues that I am unable to resolve:

  1. Unwanted Border Around Column Headers:
    Despite setting BorderBrush and BorderThickness to Transparent or 0 for the headers, there is still a faint border around the header cells. I tried modifying the control templates based on the Telerik documentation but haven't been able to remove it.

  2. Row Hover Color Changes to Orange/Golden:
    When I hover over any row, its background color changes to an orange/golden shade, even though I have explicitly set the IsMouseOver trigger to make the row background transparent.

  3. Customizing the Toggle Button Icon from Triangle to Arrow:
    I want to replace the default triangular toggle icon (used to expand/collapse rows) with a simple arrow icon, but I’m not sure how to modify the toggle button template correctly.
    Below is a simplified version of my current RadTreeListView XAML:

    <telerik:RadTreeListView ItemsSource="{Binding Files}"  
                             Name="fileViewer"  
                             AutoGenerateColumns="False"  
                             Background="Transparent"  
                             Foreground="White"  
                             BorderThickness="0"  
                             RowIndicatorVisibility="Collapsed"  
                             CanUserSortColumns="False">  

      <telerik:RadTreeListView.Resources>  
        <Style TargetType="telerik:GridViewHeaderCell">  
          <Setter Property="BorderBrush" Value="Transparent" />  
          <Setter Property="BorderThickness" Value="0" />  
          <Setter Property="Background" Value="Transparent" />  
        </Style>  

        <Style TargetType="telerik:TreeListViewRow">  
          <Setter Property="Background" Value="Transparent" />  
          <Style.Triggers>  
            <Trigger Property="IsMouseOver" Value="True">  
              <Setter Property="Background" Value="Transparent" />  
            </Trigger>  
          </Style.Triggers>  
        </Style>  
      </telerik:RadTreeListView.Resources>  

      <telerik:RadTreeListView.Columns>  
        <telerik:GridViewDataColumn Header="Name" Width="*" DataMemberBinding="{Binding Name}" />  
        <telerik:GridViewDataColumn Header="Classification" Width="*" DataMemberBinding="{Binding Classifications}" />  
      </telerik:RadTreeListView.Columns>  
    </telerik:RadTreeListView>  

Martin Ivanov
Telerik team
 answered on 13 Feb 2025
2 answers
51 views

Hi,

Can I check if it is possible to disable having multiple radpanes in a radpanegroup - only 1 radpane in 1 radpanegroup? As I understand that I have to use radpanegroup in order to use radpane

Lim
Top achievements
Rank 1
Iron
Iron
 answered on 13 Feb 2025
1 answer
57 views

Hello,

I am working with GridViewColumnGroups in RadTreeListView. The first steps and styling worked pretty well. 

This morning, I stumbled upon an issue which I am trying to fix now - so far, without success:

I need to implement the "Thumb" and resizing for a GridViewColumnGroup by dragging it with the mouse (the same behavior as it already exists for plain columns). The reason I want to implement this is that I want to "fake" a certain behavior: There are alternating GridViewColumnGroups which each contain only one column. But the user of the application should be under the illusion that the column header cell and the column group are one cell - as if the two "melted together".

By styling the column group, I can make it look like that (I changed the background colour and set the bottom border to thickness zero - that's it). But I also need to implement the Thumb that not only the appearance but also the behavior are the same.

This leads me to the issue that a two-way binding between the column width and the column group width has to be implemented.

 

Any help here or someone with experience / a solution to this issue?

Any help is appreciated! Thanks a lot in adavance!

Alex

Stenly
Telerik team
 answered on 11 Feb 2025
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
Book
FileDialogs
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?