This is a migrated thread and some comments may be shown as answers.

Scrolling in the dropdown with a grouped source.

5 Answers 25 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
keepITcool
Top achievements
Rank 1
keepITcool asked on 06 Oct 2018, 06:04 PM

I have a RadComboBox with a ListCollectionView with grouping.
My problem is that the scrollviewer scrolls between the groups, not the items...
Pressing the down/up keys correctly moves thru the items, but scrolling (either clicking or with wheel)  moves thru the groups.
Some groups may have more items than will fit in the dropdown and it's very hard to see and select them.

I need to change this. How?

 

Jurgen

5 Answers, 1 is accepted

Sort by
0
keepITcool
Top achievements
Rank 1
answered on 06 Oct 2018, 06:51 PM

I bit of fiddling and voila!

ScrollViewer.CanContentScroll = "False"

This is bound to the "Part_ScrollViewer" which surrounds the ItemsPresenter in the ControlTemplate. 
BUT: then a default ScrollViewer of the ItemsControl (or ItemsPresenter?) kicks in...

Just what the doctor ordered!

Jurgen

0
Dilyan Traykov
Telerik team
answered on 10 Oct 2018, 08:08 AM
Hello Jurgen,

I'm glad to hear that you found a solution to your issue. If I can further assist you in any way, please let me know.

Regards,
Dilyan Traykov
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
0
keepITcool
Top achievements
Rank 1
answered on 10 Oct 2018, 08:26 AM

plenty.  had to dive into the documentation, but finally got rid of Fluent's ripple. (hate it)

there is however an enigma on styling the RadToggleButton... I'm trying to set a style in order to override the Accent background/ white foreground in Fluent...  Created a dummy application and all is fine. Trying to do it  in the real project and it fails. time and time again. Driving me mad. Will upload but must go to airport now.

Later! Jurgen

0
keepITcool
Top achievements
Rank 1
answered on 10 Oct 2018, 09:01 AM

yep. solved too, but not the way I wanted or understand.

the RadToggleButtons were inside a RadToolBar.  Either putting the style in global or the toolbar resources didn't work. But when I changed the containing RadToolBar to a StackPanel .. all works as expected.
Bloody hell that was complicated and time consuming (4 hours of fiddling?).

Must dash! Jurgen

0
Dilyan Traykov
Telerik team
answered on 11 Oct 2018, 08:47 AM
Hello Jurgen,

Please let me clarify why the style for the RadToggleButtons is not applied in your scenario. The RadToolBar control uses StyleSelector mechanism to re-style its items and has predefined styles for the most commonly used controls as its content. This has been documented in the following article.

So, to correctly apply the style to the RadToggleButtons of the control, you should define it like this:

<Grid>
    <Grid.Resources>
        <Style x:Key="CustomButtonStyle" TargetType="telerik:RadToggleButton" BasedOn="{StaticResource ToolBarRadToggleButtonStyle}">
            <Setter Property="Foreground" Value="Red" />
        </Style>
        <telerik:ToolBarContainerStyleSelector x:Key="selector">
            <telerik:ToolBarContainerStyle TypeName="RadToggleButton" ContainerStyle="{StaticResource CustomButtonStyle}" />
        </telerik:ToolBarContainerStyleSelector>
    </Grid.Resources>
    <telerik:RadToolBar ItemContainerStyleSelector="{StaticResource selector}">
        <telerik:RadToggleButton Content="FILE" />
        <telerik:RadToggleButton Content="EDIT " />
        <telerik:RadToggleButton Content="VIEW" />
        <telerik:RadToggleButton Content="BUILD" />
        <telerik:RadToggleButton Content="DEBUG" />
        <telerik:RadToggleButton Content="HELP" />
    </telerik:RadToolBar>
</Grid>

I hope you find this clarification helpful.

Regards,
Dilyan Traykov
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
ComboBox
Asked by
keepITcool
Top achievements
Rank 1
Answers by
keepITcool
Top achievements
Rank 1
Dilyan Traykov
Telerik team
Share this question
or