0

As you can see in this image, the image set on the button, gets bottom clipped for no apparent reason. The image is 24x24px big and the AutoSize property of the button is set to True.

The button is positioned directly on the window, so there can't be any layout messing with its size.

カラス
  • 5
  • 3

2 Answers2

0

There is an implicit margin inside of the <button> control. If you expand the button's height the clipping will disappear.

James Gould
  • 4,492
  • 2
  • 27
  • 50
  • Expanding the button height by exactly 2px, indeed removes the clipping, but isn't there a solution to this other than always manually increasing the button height? – カラス Oct 01 '16 at 18:04
  • @カラス not that I'm aware of, unless you use an image that looks identical to the button :-) – James Gould Oct 01 '16 at 18:28
0

Set the image as button's "BackgroundImage" property and then set the button's "BackgroundImageLayout" property as "Stretch".

Clock
  • 974
  • 3
  • 17
  • 35