ComponentFactory.Krypton.Toolkit.RenderOffice2013.RenderToolStrip C# (CSharp) Method

RenderToolStrip() public method

Gets a renderer for drawing the toolstrips.
public RenderToolStrip ( IPalette colorPalette ) : System.Windows.Forms.ToolStripRenderer
colorPalette IPalette Color palette to use when rendering toolstrip.
return System.Windows.Forms.ToolStripRenderer
        public override ToolStripRenderer RenderToolStrip(IPalette colorPalette)
        {
            Debug.Assert(colorPalette != null);

            // Validate incoming parameter
            if (colorPalette == null) throw new ArgumentNullException("colorPalette");

            // Use the professional renderer but pull colors from the palette
            KryptonOffice2013Renderer renderer = new KryptonOffice2013Renderer(colorPalette.ColorTable);

            // Seup the need to use rounded corners
            renderer.RoundedEdges = (colorPalette.ColorTable.UseRoundedEdges != InheritBool.False);

            return renderer;
        }
        #endregion