.TH wxSizeEvent 3erl "wx 2.4.1" "wxWidgets team." "Erlang Module Definition" .SH NAME wxSizeEvent \- Functions for wxSizeEvent class .SH DESCRIPTION .LP A size event holds information about size change events of \fIwxWindow\fR\&\&. .LP The EVT_SIZE handler function will be called when the window has been resized\&. .LP You may wish to use this for frames to resize their child windows as appropriate\&. .LP Note that the size passed is of the whole window: call \fIwxWindow:getClientSize/1\fR\& for the area which may be used by the application\&. .LP When a window is resized, usually only a small part of the window is damaged and you may only need to repaint that area\&. However, if your drawing depends on the size of the window, you may need to clear the DC explicitly and repaint the whole window\&. In which case, you may need to call \fIwxWindow:refresh/2\fR\& to invalidate the entire window\&. .LP \fIImportant\fR\& : Sizers ( see overview_sizer ) rely on size events to function correctly\&. Therefore, in a sizer-based layout, do not forget to call Skip on all size events you catch (and don\&'t catch size events at all when you don\&'t need to)\&. .LP See: {Width,Height}, Overview events .LP This class is derived (and can use functions) from: \fIwxEvent\fR\& .LP wxWidgets docs: wxSizeEvent .SH "EVENTS" .LP Use \fIwxEvtHandler:connect/3\fR\& with \fIwxSizeEventType\fR\& to subscribe to events of this type\&. .SH DATA TYPES .nf \fBwxSizeEvent()\fR\& = wx:wx_object() .br .fi .nf \fBwxSize()\fR\& = .br #wxSize{type = wxSizeEvent:wxSizeEventType(), .br size = {W :: integer(), H :: integer()}, .br rect = .br {X :: integer(), .br Y :: integer(), .br W :: integer(), .br H :: integer()}} .br .fi .nf \fBwxSizeEventType()\fR\& = size .br .fi .SH EXPORTS .LP .nf .B getSize(This) -> {W :: integer(), H :: integer()} .br .fi .br .RS .LP Types: .RS 3 This = wxSizeEvent() .br .RE .RE .RS .LP Returns the entire size of the window generating the size change event\&. .LP This is the new total size of the window, i\&.e\&. the same size as would be returned by \fIwxWindow:getSize/1\fR\& if it were called now\&. Use \fIwxWindow:getClientSize/1\fR\& if you catch this event in a top level window such as \fIwxFrame\fR\& to find the size available for the window contents\&. .RE .LP .nf .B getRect(This) -> .B {X :: integer(), .B Y :: integer(), .B W :: integer(), .B H :: integer()} .br .fi .br .RS .LP Types: .RS 3 This = wxSizeEvent() .br .RE .RE .RS .RE