Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Delphi form without system menu but with close button

Tags:

delphi

By default, a form having BorderStyle=bsSizeable has a system menu (on the left) and a close button ('X', on the right). I want to get rid of the system menu and keep the close button.

The BorderIcons property lets me remove the system menu (via biSystemmenu), but now the close button is gone too.

Is there a way to do this?

Using Delphi XE

PS: it should be possible as far as Windows is concerned: IE8's "InPrivate Filtering settings" window is sizeable, has a close button and has no system menu.

like image 359
Giel Avatar asked Jan 31 '11 10:01

Giel


1 Answers

BorderStyle := bsSizeToolWin does what you want, with a slightly different appearance of the X button.

like image 67
Mikael Eriksson Avatar answered Sep 24 '22 23:09

Mikael Eriksson