ComponentOne Ribbon for WinForms
C1Ribbon (Classic) Task-Based Help / Adding Ribbon Items / Displaying Images on RibbonTab
In This Topic
    Displaying Images on RibbonTab
    In This Topic

    To display images of different sizes on RibbonTab, you can now set the images from size 16x16 to large image of size 32x32. Small images (16x16) can be easily set on RibbonTab using Image property. When an image of size other than 16X16 is applied to RibbonTab, size of the RibbonTab increases to accommodate the image. Large image (32x32) can now be set on RibbonTab by using DisableGlassEffects() method in Application.Designer.vb file of Visual Basic application and program.cs file in case of CSharp Application as shown in given code below:

    To write code in Visual Basic

    Visual Basic
    Copy Code
    C1RibbonForm.DisableGlassEffects()
    

      

    To add code in C#

    C#
    Copy Code
    C1RibbonForm.DisableGlassEffects();
    

    The AllowImageScaling property allows you to prevent image scaling issues in high-resolution applications.

    Note: Large images (32x32) cannot be displayed as it is in Custom Visual Style, however, they are scaled to a smaller size to adjust in the Tab.