2.8.5 rc2, wxGTK top level positioning

Arne Steinarson asteinarson at gmail.com
Mon Aug 27 07:32:39 PDT 2007


>>         one cannot
>>         > know this value,
>>         Why?
>> Maybe one could, but wxSystemSettings don't give those values,
>
>wxSystemSettings in wxGTK has supported querying the frame extents for a
>long time now if you pass a wxWindow (that is a wxTopLevelWindow) to
>GetMetric second argument. The requirement is that the passed

The patch uses this while setting up the window (in
wxTopLevelWindowGTK::Create).
We cannot ask about a window which does not yet exist.

>> created, it
>> knows the offsets.
>
>The decoration changes can change during the lifetime of the process. If
>you don't react to the relevant style-changed type of notifications the
>cache will be wrong at that point.

The cache is updated each time the actual frame size is read back from GTK
(using gdk_window_get_frame_extents). This happens when the window is moved
or resized.

>Due to not having been following the whole issue, I might be somewhat
>off in my assumptions that GetMetric would work here.

Could be so :-).


Regards
// ATS
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wxwidgets.org/pipermail/wx-dev/attachments/20070827/e58c2=
a58/attachment.htm


More information about the wx-dev mailing list