
Not only may the tab be placed in any of the four sides of the rectangle, but it may also be displaced along the side it is on. Because GraphicsBuilder supports triangles as base shapes it was also a simple matter to allow right triangles as tabs, the blue/cyan balloons show them in action. So how does the code look? I'm using aliases (I'm finding them very helpful as I keep using them) just in case you were wondering
An explanation of the properties is in order
- tw - tabWidth: the name should be self explanatory
- th - tabHeight: controls the height of the tab, it is 1/2 of tabWidth by default (the example doesn't set it so it is computed as 5)
- tl - tabLocation: defines which side the tab will be attached on, default value is 'bottom'
- td - tabDisplacement: where in the chosen side the tab will be attached, it must be a value in the range (0f..1f) and it takes into consideration whatever value you set for
arc
, meaning that the tab will be drawn between (x+arc) and (x+width+arc) - ap - anglePosition: defines where is the right angle, default value is 'none'

Keep on Groovying!