BTW if we can copy the rect above the control, then draw to the control and then the control specific drawing we can simulate the alpha, at least for the controls that can't be inherited from Graphic Controls.
I say:
- Panel
-- Button
Copy the button area from panel, draw in button and then draw the button things.
I don't know how this works in LCL Canvas, but I tried same trick in fpGUI to simulate alpha in trackbar background, but it worked very slow. For example: Trackbar size 1200 x 50, copy canvas fragment from parent (panel) to trackbar canvas took 4-5 seconds on each repaint :/ .
I think that Lazarus development should more focus on improving drawing quality, especially solve problem with alpha in TCustomControl and implement full alpha in GTK interface (for now, workaround is BGRA Bitmap library for drawing). We are living in an age where the visual effect of interface is very important for users (CSS, HTML5, etc) and Lazarus square controls with one color background are not impressing
. Solution for creating modern looking controls supposed to be Custom Drawn Controls, but they inherited from TCustomControl, so again problem with transparency and irregular shapes