How can I get KeyTipAccessText to work with ribbon buttons?

Ribbon for WPF Forum

Posted 9 years ago by Craig - Varigence, Inc.
Version: 10.1.0522
Avatar
Greetings,

In my ribbon, I have several buttons that need keyboard shortcuts. My understanding was that I just needed to assign the key I want to use to the button's KeyTipAccessText property. However, that doesn't appear to work. Specifically, pressing Alt+<key> doesn't fire the button's command and the character isn't underlined in the button's label. Is there something else I need to do?

Thanks,

-Craig

                            <apribbon:SplitButton 
                                Label="Table Column" 
                                DataContext="{Binding ElementName=navigatorFrame, Path=Editor.SelectedContext}"
                                Command="{Binding AddTableColumn}"
                                CommandParameter="{x:Type Table:AstTableColumnNode}"
                                IsEnabled="{Binding Converter={StaticResource isObjectOfTypeConverter}, ConverterParameter={x:Type Table1:AstTableViewModel}}"
                                ImageSourceLarge="{DynamicResource tableRibbonColumnImage}"
                                KeyTipAccessText="C"
                                >
                                <apribbon:Menu>
                                ...
                                </apribbon:Menu>
                            </apribbon:SplitButton>
                            <apribbon:Button 
                                Label="Import Column" 
                                DataContext="{Binding ElementName=navigatorFrame, Path=Editor.SelectedContext}"
                                Command="{Binding Import}"
                                IsEnabled="{Binding Converter={StaticResource isObjectOfTypeConverter}, ConverterParameter={x:Type Table1:AstTableViewModel}}"
                                ImageSourceLarge="{DynamicResource tableRibbonImportColumnsImage}"   
                                KeyTipAccessText="I"
                                />

Comments (1)

Posted 9 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar
Hi Craig,

Key tips have various scopes, just like in Office. For instance if you do Alt+H then you are taken into the Home tab's scope (assuming you have a Home tag with KeyTipAccessText 'H'). If these buttons are in that tab somewhere then pressing 'C' right after that will execute that Table Column button.

Thus you'd have to do 'Alt+H', then 'C'.


Actipro Software Support

The latest build of this product (v2018.1 build 0675) was released 1 month ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.