Skip to main content

Type Alias: GtkDrawingAreaProps

GtkDrawingAreaProps = WidgetProps & object

Defined in: generated/jsx.ts:2711

Props for the GtkDrawingArea widget.

Type Declaration

NameTypeDescriptionDefined in
contentHeight?numberThe content height.generated/jsx.ts:2713
contentWidth?numberThe content width.generated/jsx.ts:2715
onDraw?(self, cr, width, height) => void | nullCalled to draw the contents of the drawing area. Param The drawing area widget Param The Cairo context to draw with Param The actual width of the drawing area Param The actual height of the drawing areagenerated/jsx.ts:2731
onResize?(width, height, self) => void | nullEmitted once when the widget is realized, and then each time the widget is changed while realized. This is useful in order to keep state up to date with the widget size, like for instance a backing surface.generated/jsx.ts:2723
ref?Ref<Gtk.DrawingArea>-generated/jsx.ts:2732