Windows Develop Bookmark and Share   
 index > Windows Forms General > ManagerRenderMode in toolstrip
 

ManagerRenderMode in toolstrip

Hi all,

I have a toolstrip with all the override properties in order to change the appearance of the control. The problem is that I am unable to override the color of the right border of the toolstrip, it's like the shadow of the control.

Thanks in advance!!




uankenobi90  Monday, April 07, 2008 4:23 PM

Set the Toolstrip.renderer property to a instance of a class derived from ToolStripRenderer.

Either derive directly from the abstract class ToolStripRenderer and implement all the important methods yourself.

Or derive from ToolStripSystemRenderer or ToolStripProfessionalRenderer.

These classes have a lot of methods and it can be hard to find out which method is the one you really need.

Just inherit from the base class and foresee each and every method. inside the body of the method call the base class, so you have exactly the same implementation. No to find out which method it is you need simply comment out the call to the base class until you see that the item you want to custom paint is no longer paintet.

That particular method would then actually be the only one for you that is needed to override.

The toolstrip does not paint itself it is done indirectly by these renderers.

Philip_Stuyck__  Monday, April 07, 2008 5:50 PM

Set the Toolstrip.renderer property to a instance of a class derived from ToolStripRenderer.

Either derive directly from the abstract class ToolStripRenderer and implement all the important methods yourself.

Or derive from ToolStripSystemRenderer or ToolStripProfessionalRenderer.

These classes have a lot of methods and it can be hard to find out which method is the one you really need.

Just inherit from the base class and foresee each and every method. inside the body of the method call the base class, so you have exactly the same implementation. No to find out which method it is you need simply comment out the call to the base class until you see that the item you want to custom paint is no longer paintet.

That particular method would then actually be the only one for you that is needed to override.

The toolstrip does not paint itself it is done indirectly by these renderers.

Philip_Stuyck__  Monday, April 07, 2008 5:50 PM

You can use google to search for other answers

Custom Search

More Threads

• Multi-page .tif
• C# bring Windows Form to front
• button without focus possible for only mouse clicks?
• Best Practices - Multiple Developers
• Context Menu Event Handler Problem
• How can I create a PDF file from a XML file using C#
• how to hide the vertical scrollbar of listbox
• making datagrid cell or row blink
• Context Menu's Events and Arguments
• Loading an Image from a DLL Resources.resx