Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
175
Apply theme to standard WPF control
posted

Hi,

I've started using the Office2013 theme on a number of Infragistics controls.

I would however like to extend the theme to standard controls like checkbox and textbox.

Ideally applying the theme would happen at an individual control or window level, not app level.

Is this possible and how would I achieve this?

Best Regards

Parents
No Data
Reply
  • 4618
    Verified Answer
    posted

    Hi Simon,

    It is certainly possible to apply supported themes at both the application level as well as for individual controls, using the Infragistics Theme Manager.

    The necessary approach for achieving this behavior for individual controls includes, assigning the desired control instance(s) to the ThemeManager and then applying the desired theme, such as in the following example:

    <ig:XamGrid x:name=”myGrid”>

        <ig:ThemeManager.Theme>

            <ig:Office2013Theme/>

        </ig:ThemeManager.Theme>

    </ig:XamGrid>


    Or if implementing in the code behind:

    ThemeManager.SetTheme(myGrid, new Office2013Theme());


    I have included the following link to the WPF online documentation which discusses this behavior in detail with supporting samples, covering both XAML and code behind approaches.

    http://help.infragistics.com/doc/WPF/2015.2/CLR4.0/?page=themeManager_Applying_Theme_to_Control.html

    If you have any further questions regarding this behavior, please let me know.

    Chris K.

Children
No Data