Telerik Forums
UI for .NET MAUI Forum
2 answers
9 views

When I want to select a word in the first line of a text in RichTextBox, then a context menu with "Cut, copy .." appears and hides

the toolbar. So I can't do any action on the selected text. How can I disable the context menu?

Rolf
Top achievements
Rank 1
Iron
Iron
Iron
 answered on 07 Dec 2023
1 answer
4 views

Hello,

Even though I have set up VisualState for RadEntry as below; However, RadEntry always has a default background color of white when receiving focus (mouse click) - in WINDOWS platform, it only changes color as in the VisualState setting after moving the mouse out later. Please explain and guide how to solve the problem.


<VisualStateManager.VisualStateGroups>
    <VisualStateGroup x:Name="CommonStates">
        
        <VisualState x:Name="Normal">
            <VisualState.Setters>
                <Setter Property="BackgroundColor" Value="{AppThemeBinding Dark={StaticResource DarkMode_FrameBackground}, Light= {StaticResource LightMode_FrameBackground}}"/>
            </VisualState.Setters>
        </VisualState>

        <VisualState x:Name="PointerOver">
            <VisualState.Setters>
                <Setter Property="BackgroundColor" Value="#336699"/>
            </VisualState.Setters>
        </VisualState>

        <VisualState x:Name="Focused">
            <VisualState.Setters>
                <Setter Property="BackgroundColor" Value="#336699" />
            </VisualState.Setters>
        </VisualState>

    </VisualStateGroup>
</VisualStateManager.VisualStateGroups>

Didi
Telerik team
 answered on 07 Dec 2023
0 answers
3 views

Hi,

I am using the ListPickerButtonToolbarItem list picker with MVVM and binding to an observable property,

If I set the selected item to null (so none is selected) this doesnt seem to deselect it
Its not highlighted the same as when its selected but it is still styled differently to the other other items and looks selected when I go back to choose another item.

How do we deselect the item or style the selected item in the toolbar 
ListPickerButtonToolbarItem so at least it looks the same selected or not selected?

Mark
Top achievements
Rank 3
Iron
Iron
Iron
 updated question on 07 Dec 2023
1 answer
10 views

My app does not have a dark theme, only light theme. My PC is running with dark theme, and that creates some issues with styling on these dropdowns:

 

So how do I change the text color, slider color as well as font for these?

Lance | Manager Technical Support
Telerik team
 answered on 04 Dec 2023
1 answer
10 views

Is there a way to allow copying from the RadDataGrid for the purpose of pasting into another application (Excel, text document, etc.?)

Would it be possible to copy an entire row or would it be restricted to the cell only?

Lance | Manager Technical Support
Telerik team
 updated answer on 28 Nov 2023
1 answer
6 views

THe docs say this

 



I can add a HeaderItemTemplate to get what I need, but how do I add a HeaderTemplate and keep the Item Template controls?

Relatively new to XAML and using these controls..

I am trying to use the Tab control in a simar way to a previous post, with icon, label, close button to try and dynamically add, remove tabs etc

It seems when the MAUI desktop window is sized smaller, the tabs are scrollable/slidable, but its not obvious to the user, so want to show some kind of indicator (similar to what the toolbar does) maybe this a feature to add?

Feature: have scrollable buttons to scroll the Header Items like how the toolbar works


Yana
Telerik team
 answered on 28 Nov 2023
1 answer
17 views
Hi..
I created a simple custom Telerik Maui Combox control. With a similiar style as the Telerik documentation:  [Telerik Maui Controls Combobox Styling][1]


  [1]: https://docs.telerik.com/devtools/maui/controls/combobox/styling

    <Style TargetType="telerik:RadButton" x:Key="DropDownButtonStyle">
        <Setter Property="FontSize" Value="14"/>
        <Setter Property="HorizontalOptions" Value="Center"/>
        <Setter Property="VerticalOptions" Value="Center"/>
        <Setter Property="WidthRequest" Value="24"/>
        <Setter Property="HeightRequest" Value="24"/>
        <Setter Property="Padding" Value="0"/>
        <Setter Property="BackgroundColor" Value="Transparent"/>             
        <Setter Property="TextColor" Value="Blue"/>
        <Setter Property="Padding" Value="{OnPlatform Android='8, 2, 4, 2', iOS='4, 2, 12, 2', MacCatalyst='4, 0, 8, 0', WinUI='6, 0, 10, 0'}"/>
    </Style>

I just want to change the dropdown button to use a custom Icon. So I added:

    <Setter Property="BackgroundImage" Value="downarrow.png">

When I add the custom control to a view. It works!  But on initial load - the dropdown icon does not appear. Even after binding.  If I start selecting drop downs and perform other actions, the icons appear!  Why doesn't the icon appear on load/init?  It does finally appear.  How can I force it to show?  Here's the code for the control.

    <?xml version="1.0" encoding="utf-8" ?>
    <ContentView
        x:Class="ABC.CustomControls.CustomDropdown"
        xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
        xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
        xmlns:eventToCommand="http://ABC.com/schemas/ToolKits"
        xmlns:telerik="http://schemas.telerik.com/2022/xaml/maui"
        xmlns:toolkit="http://schemas.microsoft.com/dotnet/2022/maui/toolkit"
        xmlns:Image="http://ABC.com/schemas/Image"   
        x:Name="CustomDdUnique">
        <ContentView.Resources>
            <ResourceDictionary>
                <Style x:Key="DropDown_ButtonStyle" TargetType="telerik:RadButton">
                    <Setter Property="FontSize" Value="14" />
                    <Setter Property="HorizontalOptions" Value="Center" />
                    <Setter Property="VerticalOptions" Value="Center" />
                    <Setter Property="WidthRequest" Value="15" />
                    <Setter Property="HeightRequest" Value="11"/>
                    <Setter Property="Padding" Value="0" />
                    <Setter Property="Margin" Value="0,0,10,0" />
                   <Setter Property="BackgroundImage" Value="arrow_down_1.png"/>
                    <Setter Property="BackgroundColor" Value="Transparent" />
                    <Setter Property="TextColor" Value="Transparent" />
                    <!--<Setter Property="Padding" Value="{OnPlatform Android='8, 2, 4, 2', iOS='4, 2, 12, 2', MacCatalyst='4, 0, 8, 0', WinUI='-20, 0, 0, 0'}" />-->
                </Style>
            </ResourceDictionary>
        </ContentView.Resources>
        <Grid
            ColumnDefinitions="*"
            HorizontalOptions="{Binding HorizontalOptionsDD, Source={x:Reference CustomDdUnique}}"
            VerticalOptions="{Binding VerticalOptionsDD, Source={x:Reference CustomDdUnique}}"
            WidthRequest="{Binding WidthRequestDD, Source={x:Reference CustomDdUnique}}">
    
            <Border
                HeightRequest="{Binding HeightRequestDD, Source={x:Reference CustomDdUnique}}"
                Stroke="#D9D9D9"
                StrokeThickness="1"
                WidthRequest="{Binding WidthRequestDD, Source={x:Reference CustomDdUnique}}">
                <Border.StrokeShape>
                    <RoundRectangle CornerRadius="5" />
                </Border.StrokeShape>
                <telerik:RadComboBox
                    x:Name="CustomDd"       
                    BackgroundColor="{Binding BackgroundColor, Source={x:Reference CustomDdUnique}}"
                    DisplayMemberPath="{Binding DisplayMemberPath, Source={x:Reference CustomDdUnique}}"
                    DropDownButtonStyle="{StaticResource DropDown_ButtonStyle}"
                    FlowDirection="LeftToRight"
                    FontFamily="{Binding FontFamily, Source={x:Reference CustomDdUnique}}"
                    FontSize="{Binding FontSize, Source={x:Reference CustomDdUnique}}"
                    HeightRequest="{Binding HeightRequestDD, Source={x:Reference CustomDdUnique}}"
                    HorizontalOptions="Start"
                    IsClearButtonVisible="False"
                    IsDropDownOpen="{Binding IsDropDownOpen, Source={x:Reference CustomDdUnique}}"
                    ItemsSource="{Binding ItemsSource, Source={x:Reference CustomDdUnique}}"
                    MinimumWidthRequest="50"
                    Opacity="1"                
                    SelectedIndex="{Binding SelectedIndex, Source={x:Reference CustomDdUnique}, Mode=TwoWay}"
                    SelectedItem="{Binding SelectedItem, Source={x:Reference CustomDdUnique}, Mode=TwoWay}"
                    TextColor="{Binding TextColor, Source={x:Reference CustomDdUnique}}"
                    VerticalOptions="Start"
                    WidthRequest="{Binding WidthRequestDD, Source={x:Reference CustomDdUnique}}">
    
                    <telerik:RadComboBox.Behaviors>
                        <eventToCommand:EventToCommandBehavior Command="{Binding Source={x:Reference CustomDdUnique}, Path=SelectionChangedCommand}" EventName="SelectionChanged" />
                    </telerik:RadComboBox.Behaviors>
    
                </telerik:RadComboBox>
            </Border>
            <Polygon
                x:Name="ChangeIndicator"
                Fill="#B43218"
                HeightRequest="13"
                HorizontalOptions="Start"
                IsVisible="{Binding HasChanges, Source={x:Reference CustomDdUnique}}"
                Points="0,0 0,13 14,0"
                StrokeThickness="0"
                VerticalOptions="Start"
                WidthRequest="14" />
        </Grid>
    </ContentView>

I use the control like this:  Why doesn't my dropdown icon show when loaded?          

    <controls:CustomDropdown
            Margin="10,10,0,0"   
                                                        Width="30"
                                                           ItemsSource="{Binding Mapping.ListOptions}"
                                                           SelectedItem="{Binding Mapping.List, Mode=TwoWay}"
                                                           DisplayMemberPath="Name">
                                                     </controls:CustomDropdown>             


thx
Yana
Telerik team
 answered on 28 Nov 2023
1 answer
18 views

Hi,

Since migrating to MAUI .NET8 GA 8.0.3 (and Telerik 6.5) - on iOS the RadListView keeps repeatedly triggering the defined LoadOnDemand command to get more items even though list has not been scrolled by user (and there are still plenty of items off screen / bottom of list has not been reached).

I also refer to this previous post which describes how we are using the RadListView  - Grouped mode and based on advice using <Grid RowDefinitions="Auto" ...> wrapped around items to ensure items with multiple heights are rendered correctly : 
https://www.telerik.com/forums/telerik-radlistview-failing-to-render-grouped-list-items-correctly-on-ios-maui-net7

For example we have RadListView where 10 items are loaded initially - and then we load additional sets of 10 items each time from API when the LoadOnDemand command is triggered : 

- On iOS .NET8 MAUI - even when list is not even scrolled by user it & there are still plenty of items off screen it just keeps triggering the LoadOnDemand command every few seconds to ask for more items.

- On Android .NET8 MAUI, and the previous .NET7 MAUI releases (both Android/iOS) - we were not seeing this behaviour.

Note that (as per recommended implementation in docs) we have LoadOnDemandMode set to 'Automatic', IsLoadOnDemandEnabled to 'True' and a ListViewUserCommand of id = 'LoadOnDemand' defined under the Commands property.

Can please advise when a fix can be provided for this.

thanks

Niall

 

Didi
Telerik team
 answered on 27 Nov 2023
2 answers
53 views

Hello,

I'm looking for a control for .net maui for cross-platform desktop development that lets you resize the different sections of your user interface like the GridSplitter control does in WinUI.

Does one exist?

Clint
Top achievements
Rank 1
Iron
Iron
 updated answer on 26 Nov 2023
2 answers
36 views
I need to implement an indent for the group headers based on level to better show the hierarchy. Is there anything built-in for this or a recommended method? The only thing I can see to do would be to create a converter to read the level of the GroupHeader and set the margin property of it based on that value.
Clint
Top achievements
Rank 1
Iron
Iron
 answered on 26 Nov 2023
Top users last month
Abhishek
Top achievements
Rank 1
Iron
Johan
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 3
Iron
Iron
Iron
Stephan
Top achievements
Rank 2
Iron
Iron
Veteran
Omar
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?