WidgetPainter.drawThemed

Draws the general pattern of a widget if you don't need anything particularly special and/or control the other details through your widget's style theme hints.

It gives your draw delegate a Rectangle representing the coordinates inside your border and padding.

If you change teh clip rectangle, you should change it back before you return.

More...
struct WidgetPainter
void
drawThemed
(
scope Rectangle delegate drawBody
)

Detailed Description

The sequence it uses is: background content (delegated to you) border focused outline selected overlay

Example code:

void paint(WidgetPainter painter) {
	painter.drawThemed((bounds) {
		return bounds; // if the selection overlay should be contained, you can return it here.
	});
}

Meta