wpf controls - How to retain default hover effect for my custom WPF RepeatButton -


when create custom wpf control, retain usual default appearance , effects. example, includes default blue hover on button.

i have created custom tabcontrol scrollable tabs. whatever reason, repeatbutton on each side (i.e. left , right scroll arrows) have no hover effect. have found several tutorials tell me how create own hover effect controls, unfortunately these examples replace background different color (and looks different having animation fades in transparent blue while keeping underlying background). how can hover effect? there way can access standard hover effect (might storyboard?)?

edit: have discovered if remove custom style put on repeatbutton, default hover effect. perhaps question -- how did destroy hover effect, , how mildly modify appearance without destroying it? below style borked hover effect-

                        <style x:key="tabscrollerrepeatbuttonstyle" targettype="{x:type repeatbutton}">                         <setter property="template">                             <setter.value>                                 <controltemplate>                                     <border x:name="testtest" background="{templatebinding background}" borderbrush="{templatebinding borderbrush}" borderthickness="1" margin="1,0" cornerradius="2">                                         <contentpresenter horizontalalignment="center" verticalalignment="center" content="{templatebinding contentcontrol.content}"/>                                     </border>                                 </controltemplate>                             </setter.value>                         </setter> 

the best way attack problems these fire expression blend , 'edit template' control want copy styles from. doing scrollbar show default style , can copy relevant bits custom control style.


Comments

Popular posts from this blog

javascript - Enclosure Memory Copies -

php - Replacing tags in braces, even nested tags, with regex -