Search code examples
winformsformsheighttitlebarformborderstyle

Get title bar height for a SizeableToolWindow .NET form


I have already written at https://stackoverflow.com/questions/13396293/getting-correct-winforms-forms-border-width-when-changing-formborderstyle-from that .NET WindowsForms package has some problems with calculating the border size. Now I need to know how to retrieve the height of the title bar part of a form with the FormBorderSize property set to 'SizableToolWindow'.


Solution

  • Sorry, it seems overlooked this thing in the managed tools before asking:

    SystemInformation.ToolWindowCaptionHeight