nobody at rubyforge.org
2007-Apr-30 21:32 UTC
[Wxruby-development] [997] branches/wxruby2/wxwidgets_282: Window - 2.6 -> 2.8 API, new methods and deprecations; update doc
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type"
content="text/html; charset=utf-8" /><style
type="text/css"><!--
#msg dl { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:'':'';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer { font-family:
verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;
font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fc0 solid; padding:
6px; }
#msg ul, pre { overflow: auto; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid;
padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family:
verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch
.binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<title>[997] branches/wxruby2/wxwidgets_282: Window - 2.6 -> 2.8 API,
new methods and deprecations; update doc</title>
</head>
<body>
<div id="msg">
<dl>
<dt>Revision</dt> <dd>997</dd>
<dt>Author</dt> <dd>brokentoy</dd>
<dt>Date</dt> <dd>2007-04-30 17:32:08 -0400 (Mon, 30 Apr
2007)</dd>
</dl>
<h3>Log Message</h3>
<pre>Window - 2.6 -> 2.8 API, new methods and deprecations; update
doc</pre>
<h3>Modified Paths</h3>
<ul>
<li><a
href="#brancheswxruby2wxwidgets_282doctextilewindowtxtl">branches/wxruby2/wxwidgets_282/doc/textile/window.txtl</a></li>
<li><a
href="#brancheswxruby2wxwidgets_282swigclassesincludewxWindowh">branches/wxruby2/wxwidgets_282/swig/classes/include/wxWindow.h</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a
id="brancheswxruby2wxwidgets_282doctextilewindowtxtl"></a>
<div class="modfile"><h4>Modified:
branches/wxruby2/wxwidgets_282/doc/textile/window.txtl (996 =>
997)</h4>
<pre class="diff"><span>
<span class="info">---
branches/wxruby2/wxwidgets_282/doc/textile/window.txtl        2007-04-30
21:25:48 UTC (rev 996)
+++
branches/wxruby2/wxwidgets_282/doc/textile/window.txtl        2007-04-30
21:32:08 UTC (rev 997)
</span><span class="lines">@@ -32,7 +32,7 @@
</span><span class="cx"> |@NO_FULL_REPAINT_ON_RESIZE@|On
Windows, this style used to disable repaintingthe window completely when its
size is changed. Since this behaviour is now the default, the style is now
obsoleteand no longer has an effect.|
</span><span class="cx"> |@VSCROLL@|Use this style to
enable a vertical scrollbar.|
</span><span class="cx"> |@HSCROLL@|Use this style to
enable a horizontal scrollbar.|
</span><del>-|@ALWAYS_SHOW_SB@|If a window has scrollbars,disable
them instead of hiding them when they are not needed (i.e. when thesize of the
window is big enough to not require the scrollbars to navigate it).This style is
currently only implemented for MSW and Universal and doesnothing on the other
platforms.|
</del><ins>+|@ALWAYS_SHOW_SB@|If a window has scrollbars,disable
them instead of hiding them when they are not needed (i.e. when thesize of the
window is big enough to not require the scrollbars to navigate it).This style is
currently implemented for MSW, GTK and Universal and doesnothing on the other
platforms.|
</ins><span class="cx"> |@CLIP_CHILDREN@|Use this style to
eliminate flicker caused by the background beingrepainted, then children being
painted over them. Windows only.|
</span><span class="cx"> |@FULL_REPAINT_ON_RESIZE@|Use
this style to forcea complete redraw of the window whenever it is resized
instead of redrawingjust the part of the window affected by resizing. Note that
this was thebehaviour by default before 2.5.1 release and that if you experience
redrawproblems with code which previously used to work you may want to try
this.Currently this style applies on GTK+ 2 and Windows only, and full
repainting is alwaysdone on other platforms.|
</span><span class="cx">
</span><span class="lines">@@ -55,6 +55,8 @@
</span><span class="cx">
</span><span class="cx"> "Event handling
overview":eventhandlingoverview.html
</span><span class="cx">
</span><ins>+"Window sizing
overview":windowsizingoverview.html
+
</ins><span class="cx"> <div id="methods">
</span><span class="cx">
</span><span class="cx"> h2. Methods
</span><span class="lines">@@ -82,8 +84,8 @@
</span><span class="cx"> *
"Window#find_focus":#Window_findfocus
</span><span class="cx"> *
"Window#find_window":#Window_findwindow
</span><span class="cx"> *
"Window#find_window_by_id":#Window_findwindowbyid
</span><ins>+*
"Window#find_window_by_label":#Window_findwindowbylabel
</ins><span class="cx"> *
"Window#find_window_by_name":#Window_findwindowbyname
</span><del>-*
"Window#find_window_by_label":#Window_findwindowbylabel
</del><span class="cx"> *
"Window#fit":#Window_fit
</span><span class="cx"> *
"Window#fit_inside":#Window_fitinside
</span><span class="cx"> *
"Window#freeze":#Window_freeze
</span><span class="lines">@@ -91,10 +93,10 @@
</span><span class="cx"> *
"Window#get_accessible":#Window_getaccessible
</span><span class="cx"> *
"Window#get_background_colour":#Window_getbackgroundcolour
</span><span class="cx"> *
"Window#get_background_style":#Window_getbackgroundstyle
</span><del>-*
"Window#get_best_fitting_size":#Window_getbestfittingsize
</del><ins>+*
"Window#get_effective_min_size":#Window_geteffectiveminsize
</ins><span class="cx"> *
"Window#get_best_size":#Window_getbestsize
</span><ins>+* "Window#get_capture":#Window_getcapture
</ins><span class="cx"> *
"Window#get_caret":#Window_getcaret
</span><del>-* "Window#get_capture":#Window_getcapture
</del><span class="cx"> *
"Window#get_char_height":#Window_getcharheight
</span><span class="cx"> *
"Window#get_char_width":#Window_getcharwidth
</span><span class="cx"> *
"Window#get_children":#Window_getchildren
</span><span class="lines">@@ -112,6 +114,7 @@
</span><span class="cx"> *
"Window#get_foreground_colour":#Window_getforegroundcolour
</span><span class="cx"> *
"Window#get_grand_parent":#Window_getgrandparent
</span><span class="cx"> *
"Window#get_handle":#Window_gethandle
</span><ins>+*
"Window#get_help_text_at_point":#Window_gethelptextatpoint
</ins><span class="cx"> *
"Window#get_help_text":#Window_gethelptext
</span><span class="cx"> *
"Window#get_id":#Window_getid
</span><span class="cx"> *
"Window#get_label":#Window_getlabel
</span><span class="lines">@@ -121,6 +124,8 @@
</span><span class="cx"> *
"Window#get_parent":#Window_getparent
</span><span class="cx"> *
"Window#get_position":#Window_getposition
</span><span class="cx"> *
"Window#get_rect":#Window_getrect
</span><ins>+*
"Window#get_screen_position":#Window_getscreenposition
+* "Window#get_screen_rect":#Window_getscreenrect
</ins><span class="cx"> *
"Window#get_scroll_pos":#Window_getscrollpos
</span><span class="cx"> *
"Window#get_scroll_range":#Window_getscrollrange
</span><span class="cx"> *
"Window#get_scroll_thumb":#Window_getscrollthumb
</span><span class="lines">@@ -131,19 +136,25 @@
</span><span class="cx"> *
"Window#get_update_region":#Window_getupdateregion
</span><span class="cx"> *
"Window#get_validator":#Window_getvalidator
</span><span class="cx"> *
"Window#get_virtual_size":#Window_getvirtualsize
</span><ins>+*
"Window#get_window_border_size":#Window_getwindowbordersize
</ins><span class="cx"> *
"Window#get_window_style_flag":#Window_getwindowstyleflag
</span><span class="cx"> *
"Window#get_window_variant":#Window_getwindowvariant
</span><span class="cx"> *
"Window#has_capture":#Window_hascapture
</span><ins>+* "Window#has_flag":#Window_hasflag
+* "Window#has_multiple_pages":#Window_hasmultiplepages
</ins><span class="cx"> *
"Window#has_scrollbar":#Window_hasscrollbar
</span><span class="cx"> *
"Window#has_transparent_background":#Window_hastransparentbackground
</span><span class="cx"> *
"Window#hide":#Window_hide
</span><span class="cx"> *
"Window#inherit_attributes":#Window_inheritattributes
</span><span class="cx"> *
"Window#init_dialog":#Window_initdialog
</span><span class="cx"> *
"Window#invalidate_best_size":#Window_invalidatebestsize
</span><ins>+*
"Window#is_double_buffered":#Window_isdoublebuffered
</ins><span class="cx"> *
"Window#is_enabled":#Window_isenabled
</span><span class="cx"> *
"Window#is_exposed":#Window_isexposed
</span><ins>+* "Window#is_frozen":#Window_isfrozen
</ins><span class="cx"> *
"Window#is_retained":#Window_isretained
</span><span class="cx"> *
"Window#is_shown":#Window_isshown
</span><ins>+*
"Window#is_shown_on_screen":#Window_isshownonscreen
</ins><span class="cx"> *
"Window#is_top_level":#Window_istoplevel
</span><span class="cx"> *
"Window#layout":#Window_layout
</span><span class="cx"> *
"Window#line_down":#Window_linedown
</span><span class="lines">@@ -178,19 +189,14 @@
</span><span class="cx"> *
"Window#set_auto_layout":#Window_setautolayout
</span><span class="cx"> *
"Window#set_background_colour":#Window_setbackgroundcolour
</span><span class="cx"> *
"Window#set_background_style":#Window_setbackgroundstyle
</span><del>-*
"Window#set_best_fitting_size":#Window_setbestfittingsize
</del><ins>+*
"Window#set_initial_size":#Window_setinitialsize
</ins><span class="cx"> *
"Window#set_caret":#Window_setcaret
</span><span class="cx"> *
"Window#set_client_size":#Window_setclientsize
</span><ins>+*
"Window#set_constraints":#Window_setconstraints
</ins><span class="cx"> *
"Window#set_containing_sizer":#Window_setcontainingsizer
</span><span class="cx"> *
"Window#set_cursor":#Window_setcursor
</span><del>-*
"Window#set_constraints":#Window_setconstraints
</del><ins>+*
"Window#set_drop_target":#Window_setdroptarget
</ins><span class="cx"> *
"Window#set_initial_best_size":#Window_setinitialbestsize
</span><del>-* "Window#set_max_size":#Window_setmaxsize
-* "Window#set_min_size":#Window_setminsize
-* "Window#set_own_background_colour":#Window_setownbackgroundcolour
-* "Window#set_own_font":#Window_setownfont
-* "Window#set_own_foreground_colour":#Window_setownforegroundcolour
-* "Window#set_drop_target":#Window_setdroptarget
</del><span class="cx"> *
"Window#set_event_handler":#Window_seteventhandler
</span><span class="cx"> *
"Window#set_extra_style":#Window_setextrastyle
</span><span class="cx"> *
"Window#set_focus":#Window_setfocus
</span><span class="lines">@@ -200,7 +206,12 @@
</span><span class="cx"> *
"Window#set_help_text":#Window_sethelptext
</span><span class="cx"> *
"Window#set_id":#Window_setid
</span><span class="cx"> *
"Window#set_label":#Window_setlabel
</span><ins>+* "Window#set_max_size":#Window_setmaxsize
+* "Window#set_min_size":#Window_setminsize
</ins><span class="cx"> *
"Window#set_name":#Window_setname
</span><ins>+*
"Window#set_own_background_colour":#Window_setownbackgroundcolour
+* "Window#set_own_font":#Window_setownfont
+* "Window#set_own_foreground_colour":#Window_setownforegroundcolour
</ins><span class="cx"> *
"Window#set_palette":#Window_setpalette
</span><span class="cx"> *
"Window#set_scrollbar":#Window_setscrollbar
</span><span class="cx"> *
"Window#set_scroll_page":#Window_setscrollpage
</span><span class="lines">@@ -221,6 +232,7 @@
</span><span class="cx"> *
"Window#should_inherit_colours":#Window_shouldinheritcolours
</span><span class="cx"> *
"Window#show":#Window_show
</span><span class="cx"> *
"Window#thaw":#Window_thaw
</span><ins>+*
"Window#toggle_window_style":#Window_togglewindowstyle
</ins><span class="cx"> *
"Window#transfer_data_from_window":#Window_transferdatafromwindow
</span><span class="cx"> *
"Window#transfer_data_to_window":#Window_transferdatatowindow
</span><span class="cx"> *
"Window#unregister_hot_key":#Window_unregisterhotkey
</span><span class="lines">@@ -245,11 +257,11 @@
</span><span class="cx"> h4. Parameters
</span><span class="cx">
</span><span class="cx"> * _parent_ Pointer to a parent
window.
</span><del>-* _id_ Window identifier. If -1, will automatically
create an identifier.
-* _pos_ Window position. DefaultPosition is (-1, -1) which indicates that
Widgets
</del><ins>+* _id_ Window identifier. If ID_ANY, will automatically
create an identifier.
+* _pos_ Window position. DefaultPosition indicates that Widgets
</ins><span class="cx"> should generate a default position
for the window. If using the Window class directly, supply
</span><span class="cx"> an actual position.
</span><del>-* _size_ Window size. DefaultSize is (-1, -1) which
indicates that Widgets
</del><ins>+* _size_ Window size. DefaultSize indicates that Widgets
</ins><span class="cx"> should generate a default size for
the window. If no suitable size can be found, the
</span><span class="cx"> window will be sized to 20x20
pixels so that the window is visible but obviously not
</span><span class="cx"> correctly sized.
</span><span class="lines">@@ -294,11 +306,18 @@
</span><span class="cx"> and when the mouse is released
the capture returns to the window which had had
</span><span class="cx"> captured it previously and it is
only really released if there were no previous
</span><span class="cx"> window. In particular, this means
that you must release the mouse as many times
</span><del>-as you capture it.
</del><ins>+as you capture it, unless the window receives
+the "MouseCaptureLostEvent":mousecapturelostevent.html event.
</ins><span class="cx">
</span><ins>+Any application which captures the mouse in the
beginning of some operation
+must handle "MouseCaptureLostEvent":mousecapturelostevent.html
+and cancel this operation when it receives the event. The event handler must
+not recapture mouse.
+
</ins><span class="cx"> h4. See also
</span><span class="cx">
</span><span class="cx">
"Window#release_mouse":window.html#Window_releasemouse
</span><ins>+"MouseCaptureLostEvent":mousecapturelostevent.html
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> h3(#Window_center). Window#center
</span><span class="lines">@@ -691,7 +710,11 @@
</span><span class="cx"> controls so it is mostly just a
hint to Widgets and not a mandatory
</span><span class="cx"> directive.
</span><span class="cx">
</span><ins>+h4. See also
</ins><span class="cx">
</span><ins>+"WindowUpdateLocker":windowupdatelocker.html
+
+
</ins><span class="cx"> h3(#Window_getacceleratortable).
Window#get_accelerator_table
</span><span class="cx">
</span><span class="cx">
"AcceleratorTable":acceleratortable.html *get_accelerator_table*()
</span><span class="lines">@@ -734,15 +757,17 @@
</span><span class="cx">
</span><span class="cx">
"Window#set_background_colour":window.html#Window_setbackgroundcolour,
"Window#get_foreground_colour":window.html#Window_getforegroundcolour,
"Window#set_background_style":window.html#Window_setbackgroundstyle
</span><span class="cx">
</span><del>-h3(#Window_getbestfittingsize).
Window#get_best_fitting_size
</del><ins>+h3(#Window_geteffectiveminsize).
Window#get_effective_min_size
</ins><span class="cx">
</span><del>- "Size":size.html *get_best_fitting_size*()
</del><ins>+ "Size":size.html *get_effective_min_size*()
</ins><span class="cx">
</span><del>-Merges the window''s best size into the min
size and returns the result.
</del><ins>+Merges the window''s best size into the min size
and returns the
+result. This is the value used by sizers to determine the appropriate
+ammount of sapce to allocate for the widget.
</ins><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><del>-"Window#get_best_size":window.html#Window_getbestsize,
"Window#set_best_fitting_size":window.html#Window_setbestfittingsize,
"Window#set_size_hints":window.html#Window_setsizehints
</del><ins>+"Window#get_best_size":window.html#Window_getbestsize,
"Window#set_initial_size":window.html#Window_setinitialsize
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> h3(#Window_getbestsize).
Window#get_best_size
</span><span class="lines">@@ -757,13 +782,6 @@
</span><span class="cx"> "Fit":windowfit.html.
</span><span class="cx">
</span><span class="cx">
</span><del>-h3(#Window_getcaret). Window#get_caret
-
- "Caret":caret.html *get_caret*()
-
-Returns the "caret":caret.html associated with the window.
-
-
</del><span class="cx"> h3(#Window_getcapture).
Window#get_capture
</span><span class="cx">
</span><span class="cx"> "Window":window.html
*get_capture*()
</span><span class="lines">@@ -775,9 +793,17 @@
</span><span class="cx">
"Window#has_capture":window.html#Window_hascapture,
</span><span class="cx">
"Window#capture_mouse":window.html#Window_capturemouse,
</span><span class="cx">
"Window#release_mouse":window.html#Window_releasemouse,
</span><ins>+"MouseCaptureLostEvent":mousecapturelostevent.html
</ins><span class="cx">
"MouseCaptureChangedEvent":mousecapturechangedevent.html
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_getcaret). Window#get_caret
+
+ "Caret":caret.html *get_caret*()
+
+Returns the "caret":caret.html associated with the window.
+
+
</ins><span class="cx"> h3(#Window_getcharheight).
Window#get_char_height
</span><span class="cx">
</span><span class="cx"> Integer *get_char_height*()
</span><span class="lines">@@ -989,6 +1015,22 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_gethelptextatpoint).
Window#get_help_text_at_point
+
+ String *get_help_text_at_point*(%(arg-type)Point% point,
%(arg-type)HelpEvent::Origin% origin)
+
+Gets the help text to be used as context-sensitive help for this window. This
+method should be overridden if the help message depends on the position inside
+the window, otherwise "get_help_text":#Window_gethelptext can be
used.
+
+h4. Parameters
+
+* _point_ Coordinates of the mouse at the moment of help event emission.
+* _origin_ Help event origin, see also
"HelpEvent#get_origin":helpevent.html#HelpEvent_getorigin.
+
+2.7.0
+
+
</ins><span class="cx"> h3(#Window_gethelptext).
Window#get_help_text
</span><span class="cx">
</span><span class="cx"> String *get_help_text*()
</span><span class="lines">@@ -1000,7 +1042,7 @@
</span><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><del>-"set_help_text":#Window_sethelptext,
"HelpProvider":helpprovider.html
</del><ins>+"set_help_text":#Window_sethelptext,
"get_help_text_at_point":#Window_gethelptextatpoint,
"HelpProvider":helpprovider.html
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> h3(#Window_getid). Window#get_id
</span><span class="lines">@@ -1012,7 +1054,7 @@
</span><span class="cx"> h4. Remarks
</span><span class="cx">
</span><span class="cx"> Each window has an integer
identifier. If the application has not provided one
</span><del>-(or the default Id -1) an unique identifier with a
negative value will be generated.
</del><ins>+(or the default ID_ANY) an unique identifier with a
negative value will be generated.
</ins><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><span class="lines">@@ -1039,14 +1081,16 @@
</span><span class="cx"> "Size":size.html
*get_max_size*()
</span><span class="cx">
</span><span class="cx"> Returns the maximum size of the
window, an indication to the sizer layout mechanism
</span><del>-that this is the maximum possible size.
</del><ins>+that this is the maximum possible size.
</ins><span class="cx">
</span><span class="cx"> h3(#Window_getminsize).
Window#get_min_size
</span><span class="cx">
</span><span class="cx"> "Size":size.html
*get_min_size*()
</span><span class="cx">
</span><span class="cx"> Returns the minimum size of the
window, an indication to the sizer layout mechanism
</span><del>-that this is the minimum required size.
</del><ins>+that this is the minimum required size. It normally just
returns the value set
+by "set_min_size":#Window_setminsize, but it can be overridden to do
the
+calculation on demand.
</ins><span class="cx">
</span><span class="cx"> h3(#Window_getname).
Window#get_name
</span><span class="cx">
</span><span class="lines">@@ -1083,21 +1127,61 @@
</span><span class="cx">
</span><span class="cx"> h4. Parameters
</span><span class="cx">
</span><del>-* _x_ Receives the x position of the window.
-* _y_ Receives the y position of the window.
</del><ins>+* _x_ Receives the x position of the window if non-.
+* _y_ Receives the y position of the window if non-.
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">
</span><ins>+h4. See also
+
+"get_screen_position":#Window_getscreenposition
+
+
</ins><span class="cx"> h3(#Window_getrect).
Window#get_rect
</span><span class="cx">
</span><span class="cx"> "Rect":rect.html
*get_rect*()
</span><span class="cx">
</span><span class="cx"> Returns the size and position of
the window as a "Rect":rect.html object.
</span><span class="cx">
</span><ins>+h4. See also
</ins><span class="cx">
</span><ins>+"get_screen_rect":#Window_getscreenrect
+
+
+h3(#Window_getscreenposition). Window#get_screen_position
+
+ *get_screen_position*(%(arg-type)Integer% x, %(arg-type)Integer% y)
+
+ "Point":point.html *get_screen_position*()
+
+Returns the window position in screen coordinates, whether the window is a
+child window or a top level one.
+
+h4. Parameters
+
+* _x_ Receives the x position of the window on the screen if non-.
+* _y_ Receives the y position of the window on the screen if non-.
+
+h4. See also
+
+"get_position":#Window_getposition
+
+
+h3(#Window_getscreenrect). Window#get_screen_rect
+
+ "Rect":rect.html *get_screen_rect*()
+
+Returns the size and position of the window on the screen as a
+"Rect":rect.html object.
+
+h4. See also
+
+"get_rect":#Window_getrect
+
+
</ins><span class="cx"> h3(#Window_getscrollpos).
Window#get_scroll_pos
</span><span class="cx">
</span><span class="cx"> Integer
*get_scroll_pos*(%(arg-type)Integer% orientation)
</span><span class="lines">@@ -1226,6 +1310,14 @@
</span><span class="cx">
"get_size":#Window_getsize,
"get_client_size":#Window_getclientsize
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_getwindowbordersize).
Window#get_window_border_size
+
+ "Size":size.html *get_window_border_size*()
+
+Returns the size of the left/right and top/bottom borders of this window in x
+and y components of the result respectively.
+
+
</ins><span class="cx"> h3(#Window_getwindowstyleflag).
Window#get_window_style_flag
</span><span class="cx">
</span><span class="cx"> Integer
*get_window_style_flag*()
</span><span class="lines">@@ -1252,9 +1344,29 @@
</span><span class="cx">
</span><span class="cx">
"Window#capture_mouse":window.html#Window_capturemouse,
</span><span class="cx">
"Window#release_mouse":window.html#Window_releasemouse,
</span><ins>+"MouseCaptureLostEvent":mousecapturelostevent.html
</ins><span class="cx">
"MouseCaptureChangedEvent":mousecapturechangedevent.html
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_hasflag). Window#has_flag
+
+ Boolean *has_flag*(%(arg-type)Integer% flag)
+
+Returns @true@ if the window has the given flag bit set.
+
+
+h3(#Window_hasmultiplepages). Window#has_multiple_pages
+
+ Boolean *has_multiple_pages*()
+
+This method should be overridden to return @true@ if this window has
+multiple pages. All standard class with multiple pages such as
+"Notebook":notebook.html, "Listbook":listbook.html and
+"Treebook":treebook.html already override it to return @true@
+and user-defined classes with similar behaviour should do it as well to allow
+the library to handle such windows appropriately.
+
+
</ins><span class="cx"> h3(#Window_hasscrollbar).
Window#has_scrollbar
</span><span class="cx">
</span><span class="cx"> Boolean
*has_scrollbar*(%(arg-type)Integer% orient)
</span><span class="lines">@@ -1329,6 +1441,19 @@
</span><span class="cx"> Resets the cached best size value
so it will be recalculated the next time it is needed.
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_isdoublebuffered). Window#is_double_buffered
+
+ Boolean *is_double_buffered*()
+
+Returns if the window contents is double-buffered by the system, i.e. if
+any drawing done on the window is really done on a temporary backing surface
+and transferred to the screen all at once later.
+
+h4. See also
+
+"BufferedDC":buffereddc.html
+
+
</ins><span class="cx"> h3(#Window_isenabled).
Window#is_enabled
</span><span class="cx">
</span><span class="cx"> Boolean *is_enabled*()
</span><span class="lines">@@ -1357,6 +1482,18 @@
</span><span class="cx">
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_isfrozen). Window#is_frozen
+
+ Boolean *is_frozen*()
+
+Returns if the window is currently frozen by a call to
+"Freeze()":windowfreeze.html.
+
+h4. See also
+
+"Thaw()":windowthaw.html
+
+
</ins><span class="cx"> h3(#Window_isretained).
Window#is_retained
</span><span class="cx">
</span><span class="cx"> Boolean *is_retained*()
</span><span class="lines">@@ -1374,7 +1511,23 @@
</span><span class="cx">
</span><span class="cx"> Returns @true@ if the window is
shown, @false@ if it has been hidden.
</span><span class="cx">
</span><ins>+h4. See also
</ins><span class="cx">
</span><ins>+"Window#is_shown_on_screen":window.html#Window_isshownonscreen
+
+
+h3(#Window_isshownonscreen). Window#is_shown_on_screen
+
+ Boolean *is_shown_on_screen*()
+
+Returns @true@ if the window is physically visible on the screen, i.e. it
+is shown and all its parents up to the toplevel window are shown as well.
+
+h4. See also
+
+"Window#is_shown":window.html#Window_isshown
+
+
</ins><span class="cx"> h3(#Window_istoplevel).
Window#is_top_level
</span><span class="cx">
</span><span class="cx"> Boolean *is_top_level*()
</span><span class="lines">@@ -1409,7 +1562,7 @@
</span><span class="cx">
</span><span class="cx"> *lower*()
</span><span class="cx">
</span><del>-Lowers the window to the bottom of the window
hierarchy.
</del><ins>+Lowers the window to the bottom of the window hierarchy
(z-order).
</ins><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><span class="lines">@@ -1639,9 +1792,9 @@
</span><span class="cx">
</span><span class="cx"> *raise*()
</span><span class="cx">
</span><del>-Raises the window to the top of the window hierarchy.
</del><ins>+Raises the window to the top of the window hierarchy
(z-order).
</ins><span class="cx">
</span><del>-In current version of Widgets this works both for
manage and child windows.
</del><ins>+In current version of Widgets this works both for
managed and child windows.
</ins><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><span class="lines">@@ -1727,6 +1880,7 @@
</span><span class="cx">
"Window#capture_mouse":window.html#Window_capturemouse,
</span><span class="cx">
"Window#has_capture":window.html#Window_hascapture,
</span><span class="cx">
"Window#release_mouse":window.html#Window_releasemouse,
</span><ins>+"MouseCaptureLostEvent":mousecapturelostevent.html
</ins><span class="cx">
"MouseCaptureChangedEvent":mousecapturechangedevent.html
</span><span class="cx">
</span><span class="cx">
</span><span class="lines">@@ -1774,7 +1928,7 @@
</span><span class="cx">
</span><span class="cx"> Reparents the window, i.e the
window will be removed from its
</span><span class="cx"> current parent window (e.g. a
non-standard toolbar in a Frame)
</span><del>-and then re-inserted into another. Available on Windows
and GTK.
</del><ins>+and then re-inserted into another.
</ins><span class="cx">
</span><span class="cx"> h4. Parameters
</span><span class="cx">
</span><span class="lines">@@ -1830,9 +1984,7 @@
</span><span class="cx">
</span><span class="cx"> h4. Remarks
</span><span class="cx">
</span><del>-This function is currently only implemented under MSW
and TextCtrl under
-GTK (it also works for ScrolledWindow derived classes under all
-platforms).
</del><ins>+This function is currently only implemented under MSW
and GTK.
</ins><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><span class="lines">@@ -1849,14 +2001,14 @@
</span><span class="cx">
</span><span class="cx"> * _dx_ Amount to scroll
horizontally.
</span><span class="cx"> * _dy_ Amount to scroll
vertically.
</span><del>-* _rect_ Rectangle to invalidate. If this is NULL, the
whole window is invalidated. If you
-pass a rectangle corresponding to the area of the window exposed by the scroll,
your painting handler
-can optimize painting by checking for the invalidated region. This parameter is
ignored under GTK.
</del><ins>+* _rect_ Rectangle to scroll, if it is , the whole
window is
+scrolled (this is always the case under GTK which doesn''t support this
+parameter)
</ins><span class="cx">
</span><span class="cx"> h4. Remarks
</span><span class="cx">
</span><del>-Use this function to optimise your scrolling
implementations, to minimise the area that must be
-redrawn. Note that it is rarely required to call this function from a user
program.
</del><ins>+Note that you can often use
"ScrolledWindow":scrolledwindow.html
+instead of using this function directly.
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> h3(#Window_setacceleratortable).
Window#set_accelerator_table
</span><span class="lines">@@ -1881,16 +2033,21 @@
</span><span class="cx">
*set_auto_layout*(%(arg-type)Boolean% autoLayout)
</span><span class="cx">
</span><span class="cx"> Determines whether the
"Window#layout":window.html#Window_layout function will
</span><del>-be called automatically when the window is resized. It
is called implicitly by
-"Window#set_sizer":window.html#Window_setsizer but if you use
</del><ins>+be called automatically when the window is resized.
Please note that this only
+happens for the windows usually used to contain children, namely
+"Panel":panel.html and "TopLevelWindow":toplevelwindow.html
+(and the classes deriving from them).
+
+This method is called implicitly by
+"Window#set_sizer":window.html#Window_setsizer but if you use
</ins><span class="cx">
"Window#set_constraints":window.html#Window_setconstraints you should
call it
</span><span class="cx"> manually or otherwise the window
layout won''t be correctly updated when its
</span><span class="cx"> size changes.
</span><span class="cx">
</span><span class="cx"> h4. Parameters
</span><span class="cx">
</span><del>-* _autoLayout_ Set this to @true@ if you wish the
Layout function to be called
-from within Window::OnSize functions.
</del><ins>+* _autoLayout_ Set this to if you wish the Layout
function to be
+called automatically when the window is resized.
</ins><span class="cx">
</span><span class="cx"> h4. See also
</span><span class="cx">
</span><span class="lines">@@ -1948,9 +2105,9 @@
</span><span class="cx">
"Window#set_background_colour":window.html#Window_setbackgroundcolour,
"Window#get_foreground_colour":window.html#Window_getforegroundcolour,
"Window#get_background_style":window.html#Window_getbackgroundstyle
</span><span class="cx">
</span><span class="cx">
</span><del>-h3(#Window_setbestfittingsize).
Window#set_best_fitting_size
</del><ins>+h3(#Window_setinitialsize). Window#set_initial_size
</ins><span class="cx">
</span><del>- *set_best_fitting_size*(%(arg-type)Size% size =
DEFAULT_SIZE)
</del><ins>+ *set_initial_size*(%(arg-type)Size% size =
DEFAULT_SIZE)
</ins><span class="cx">
</span><span class="cx"> A _smart_ SetSize that will fill
in default size components with the
</span><span class="cx"> window''s _best_ size
values. Also sets the window''s minsize to
</span><span class="lines">@@ -1959,9 +2116,13 @@
</span><span class="cx"> size instead of the results of
GetBestSize to determine the minimum
</span><span class="cx"> needs of the window for layout.
</span><span class="cx">
</span><ins>+Most controls will use this to set their initial size,
and their min
+size to the passed in value (if any.)
+
+
</ins><span class="cx"> h4. See also
</span><span class="cx">
</span><del>-"Window#set_size":window.html#Window_setsize,
"Window#get_best_size":window.html#Window_getbestsize,
"Window#get_best_fitting_size":window.html#Window_getbestfittingsize,
"Window#set_size_hints":window.html#Window_setsizehints
</del><ins>+"Window#set_size":window.html#Window_setsize,
"Window#get_best_size":window.html#Window_getbestsize,
"Window#get_effective_min_size":window.html#Window_geteffectiveminsize
</ins><span class="cx">
</span><span class="cx">
</span><span class="cx"> h3(#Window_setcaret).
Window#set_caret
</span><span class="lines">@@ -2062,64 +2223,33 @@
</span><span class="cx">
</span><span class="cx">
"set_size":#Window_setsize
</span><span class="cx">
</span><del>-h3(#Window_setinitialbestsize).
Window#set_initial_best_size
</del><ins>+h3(#Window_setcontainingsizer).
Window#set_containing_sizer
</ins><span class="cx">
</span><del>- *set_initial_best_size*(%(arg-type)Size% size)
</del><ins>+ *set_containing_sizer*(%(arg-type)Sizer% sizer)
</ins><span class="cx">
</span><del>-Sets the initial window size if none is given (i.e. at
least one of the
-components of the size passed to ctor/Create() is DefaultCoord).
</del><ins>+This normally does not need to be called by user code.
It is called
+when a window is added to a sizer, and is used so the window can
+remove itself from the sizer when it is destroyed.
</ins><span class="cx">
</span><del>-h3(#Window_setmaxsize). Window#set_max_size
</del><span class="cx">
</span><del>- *set_max_size*(%(arg-type)Size% size)
</del><ins>+h3(#Window_setcursor). Window#set_cursor
</ins><span class="cx">
</span><del>-Sets the maximum size of the window, to indicate to the
sizer layout mechanism
-that this is the maximum possible size.
</del><ins>+ *set_cursor*(%(arg-type)Cursor% cursor)
</ins><span class="cx">
</span><del>-h3(#Window_setminsize). Window#set_min_size
</del><ins>+Sets the window''s cursor. Notice that the
window cursor also sets it for the
+children of the window implicitly.
</ins><span class="cx">
</span><del>- *set_min_size*(%(arg-type)Size% size)
</del><ins>+The _cursor_ may be @NullCursor@ in which case the
window cursor will
+be reset back to default.
</ins><span class="cx">
</span><del>-Sets the minimum size of the window, to indicate to the
sizer layout mechanism
-that this is the minimum required size. You may need to call this
-if you change the window size after construction and before adding
-to its parent sizer.
</del><ins>+h4. Parameters
</ins><span class="cx">
</span><del>-h3(#Window_setownbackgroundcolour).
Window#set_own_background_colour
</del><ins>+* _cursor_ Specifies the cursor that the window should
normally display.
</ins><span class="cx">
</span><del>- *set_own_background_colour*(%(arg-type)Colour%
colour)
-
-Sets the background colour of the window but prevents it from being inherited
-by the children of this window.
-
</del><span class="cx"> h4. See also
</span><span class="cx">
</span><del>-"set_background_colour":#Window_setbackgroundcolour,
"inherit_attributes":#Window_inheritattributes
</del><ins>+"::SetCursor":setcursor.html,
"Cursor":cursor.html
</ins><span class="cx">
</span><del>-
-h3(#Window_setownfont). Window#set_own_font
-
- *set_own_font*(%(arg-type)Font% font)
-
-Sets the font of the window but prevents it from being inherited by the
-children of this window.
-
-h4. See also
-
-"set_font":#Window_setfont,
"inherit_attributes":#Window_inheritattributes
-
-
-h3(#Window_setownforegroundcolour). Window#set_own_foreground_colour
-
- *set_own_foreground_colour*(%(arg-type)Colour% colour)
-
-Sets the foreground colour of the window but prevents it from being inherited
-by the children of this window.
-
-h4. See also
-
-"set_foreground_colour":#Window_setforegroundcolour,
"inherit_attributes":#Window_inheritattributes
-
</del><span class="cx"> h3(#Window_setdroptarget).
Window#set_drop_target
</span><span class="cx">
</span><span class="cx">
*set_drop_target*(%(arg-type)DropTarget% target)
</span><span class="lines">@@ -2132,6 +2262,13 @@
</span><span class="cx">
</span><span class="cx">
"Window#get_drop_target":window.html#Window_getdroptarget,
</span><span class="cx">
</span><ins>+h3(#Window_setinitialbestsize).
Window#set_initial_best_size
+
+ *set_initial_best_size*(%(arg-type)Size% size)
+
+Sets the initial window size if none is given (i.e. at least one of the
+components of the size passed to ctor/Create() is DefaultCoord).
+
</ins><span class="cx"> h3(#Window_seteventhandler).
Window#set_event_handler
</span><span class="cx">
</span><span class="cx">
*set_event_handler*(%(arg-type)EvtHandler% handler)
</span><span class="lines">@@ -2209,6 +2346,12 @@
</span><span class="cx"> see
"inherit_attributes":#Window_inheritattributes for more
</span><span class="cx"> explanations.
</span><span class="cx">
</span><ins>+Please notice that the given font is not automatically
used for
+"PaintDC":paintdc.html objects associated with this window, you need
to
+call "DC::SetFont()":dcsetfont.html too. However this font is used by
+any standard controls for drawing their text as well as by
+"Window::GetTextExtent()":windowgettextextent.html.
+
</ins><span class="cx"> h4. Parameters
</span><span class="cx">
</span><span class="cx"> * _font_ Font to associate with
this window, pass
</span><span class="lines">@@ -2299,6 +2442,22 @@
</span><span class="cx">
"Window#get_label":window.html#Window_getlabel
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_setmaxsize). Window#set_max_size
+
+ *set_max_size*(%(arg-type)Size% size)
+
+Sets the maximum size of the window, to indicate to the sizer layout mechanism
+that this is the maximum possible size.
+
+h3(#Window_setminsize). Window#set_min_size
+
+ *set_min_size*(%(arg-type)Size% size)
+
+Sets the minimum size of the window, to indicate to the sizer layout mechanism
+that this is the minimum required size. You may need to call this
+if you change the window size after construction and before adding
+to its parent sizer.
+
</ins><span class="cx"> h3(#Window_setname).
Window#set_name
</span><span class="cx">
</span><span class="cx"> *set_name*(%(arg-type)String%
name)
</span><span class="lines">@@ -2314,6 +2473,42 @@
</span><span class="cx">
"Window#get_name":window.html#Window_getname
</span><span class="cx">
</span><span class="cx">
</span><ins>+h3(#Window_setownbackgroundcolour).
Window#set_own_background_colour
+
+ *set_own_background_colour*(%(arg-type)Colour% colour)
+
+Sets the background colour of the window but prevents it from being inherited
+by the children of this window.
+
+h4. See also
+
+"set_background_colour":#Window_setbackgroundcolour,
"inherit_attributes":#Window_inheritattributes
+
+
+h3(#Window_setownfont). Window#set_own_font
+
+ *set_own_font*(%(arg-type)Font% font)
+
+Sets the font of the window but prevents it from being inherited by the
+children of this window.
+
+h4. See also
+
+"set_font":#Window_setfont,
"inherit_attributes":#Window_inheritattributes
+
+
+h3(#Window_setownforegroundcolour). Window#set_own_foreground_colour
+
+ *set_own_foreground_colour*(%(arg-type)Colour% colour)
+
+Sets the foreground colour of the window but prevents it from being inherited
+by the children of this window.
+
+h4. See also
+
+"set_foreground_colour":#Window_setforegroundcolour,
"inherit_attributes":#Window_inheritattributes
+
+
</ins><span class="cx"> h3(#Window_setpalette).
Window#set_palette
</span><span class="cx">
</span><span class="cx">
*set_palette*(%(arg-type)Palette% palette)
</span><span class="lines">@@ -2760,7 +2955,32 @@
</span><span class="cx">
</span><span class="cx">
"Window#register_hot_key":window.html#Window_registerhotkey
</span><span class="cx">
</span><ins>+h4. See also
</ins><span class="cx">
</span><ins>+"WindowUpdateLocker":windowupdatelocker.html
+
+
+h3(#Window_togglewindowstyle). Window#toggle_window_style
+
+ Boolean *toggle_window_style*(%(arg-type)Integer% flag)
+
+Turns the given flag on if it''s currently turned off and vice versa.
+This function cannot be used if the value of the flag is $0$ (which is often
+the case for default flags).
+
+Also, please notice that not all styles can be changed after the control
+creation.
+
+h4. Return value
+
+Returns if the style was turned on by this function, if it was
+switched off.
+
+h4. See also
+
+"Window#set_window_style_flag":window.html#Window_setwindowstyleflag,
"Window#has_flag":window.html#Window_hasflag
+
+
</ins><span class="cx"> h3(#Window_update). Window#update
</span><span class="cx">
</span><span class="cx"> *update*()
</span></span></pre></div>
<a
id="brancheswxruby2wxwidgets_282swigclassesincludewxWindowh"></a>
<div class="modfile"><h4>Modified:
branches/wxruby2/wxwidgets_282/swig/classes/include/wxWindow.h (996 =>
997)</h4>
<pre class="diff"><span>
<span class="info">---
branches/wxruby2/wxwidgets_282/swig/classes/include/wxWindow.h        2007-04-30
21:25:48 UTC (rev 996)
+++
branches/wxruby2/wxwidgets_282/swig/classes/include/wxWindow.h        2007-04-30
21:32:08 UTC (rev 997)
</span><span class="lines">@@ -68,6 +68,8 @@
</span><span class="cx"> wxColour GetForegroundColour()
;
</span><span class="cx"> wxWindow* GetGrandParent()
const;
</span><span class="cx"> void* GetHandle() const;
</span><ins>+ virtual wxString GetHelpTextAtPoint(const wxPoint
point,
+                                                                        
wxHelpEvent::Origin origin) const;
</ins><span class="cx"> wxString GetHelpText() const;
</span><span class="cx"> int GetId() const;
</span><span class="cx"> virtual wxString GetLabel()
const;
</span><span class="lines">@@ -79,6 +81,9 @@
</span><span class="cx"> virtual int GetScrollThumb(int
orientation ) ;
</span><span class="cx"> virtual int GetScrollPos(int
orientation ) ;
</span><span class="cx"> virtual int GetScrollRange(int
orientation ) ;
</span><ins>+ virtual void GetScreenPosition(int* x, int* y) const;
+ wxPoint GetScreenPosition() const;
+ virtual wxRect GetScreenRect() const;
</ins><span class="cx"> void GetSize(int* width , int*
height ) const;
</span><span class="cx"> wxSize GetSize() const;
</span><span class="cx"> wxSizer * GetSizer() const;
</span><span class="lines">@@ -88,13 +93,19 @@
</span><span class="cx"> wxValidator* GetValidator();
</span><span class="cx"> void GetVirtualSize(int* width
, int* height ) const;
</span><span class="cx"> wxSize GetVirtualSize() const;
</span><ins>+ wxSize GetWindowBorderSize() const;
</ins><span class="cx"> long GetWindowStyleFlag() const;
</span><span class="cx"> virtual bool HasCapture()
const;
</span><ins>+ bool HasFlag(int flag) const;
+ virtual bool HasMultiplePages() const;
</ins><span class="cx"> bool Hide() ;
</span><span class="cx"> void InitDialog() ;
</span><ins>+ virtual bool IsDoubleBuffered() const;
</ins><span class="cx"> virtual bool IsEnabled() const;
</span><ins>+ virtual bool IsFrozen() const;
</ins><span class="cx"> virtual bool IsRetained() const;
</span><span class="cx"> virtual bool IsShown() const;
</span><ins>+ virtual bool IsShownOnScreen() const;
</ins><span class="cx"> bool IsTopLevel() const;
</span><span class="cx"> void Layout() ;
</span><span class="cx"> void Lower() ;
</span><span class="lines">@@ -141,7 +152,8 @@
</span><span class="cx"> void SetFont(const wxFont&
font ) ;
</span><span class="cx"> virtual bool
SetForegroundColour(const wxColour& colour );
</span><span class="cx"> virtual void SetHelpText(const
wxString& helpText ) ;
</span><del>- void SetId(int id ) ;
</del><ins>+ void SetId(int id );
+ void SetInitialSize(const wxSize& size = wxDefaultSize);
</ins><span class="cx"> virtual void SetName(const
wxString& name ) ;
</span><span class="cx"> #if 0 // deprecated
</span><span class="cx"> virtual void SetPalette(const
wxPalette* palette );
</span><span class="lines">@@ -193,8 +205,6 @@
</span><span class="cx"> wxWindowVariant
GetWindowVariant() const;
</span><span class="cx">
        void
InvalidateBestSize();
</span><span class="cx">
        void
CacheBestSize(const wxSize& size) const;
</span><del>-        wxSize
GetBestFittingSize() const;
-        void
SetBestFittingSize(const wxSize& size=wxDefaultSize);
</del><span class="cx"> virtual wxSize GetMaxSize()
const;
</span><span class="cx"> virtual wxSize GetMinSize()
const;
</span><span class="cx"> void SetMinSize(const
wxSize& minSize);
</span><span class="lines">@@ -231,6 +241,7 @@
</span><span class="cx"> bool PageDown();
</span><span class="cx">
        virtual
void SetLabel(const wxString& label);
</span><span class="cx">
        wxAcceleratorTable
*GetAcceleratorTable();
</span><ins>+        bool
ToggleWindowStyle(int flag);
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>
Apparently Analagous Threads
- [785] trunk/wxruby2/doc/textile/window.txtl: Remove set_constraints, correct docs for set_dimensions and set_size
- [969] branches/wxruby2/wxwidgets_282/doc/textile/window.txtl: Cleanup and fixing of broken links.
- [996] branches/wxruby2/wxwidgets_282: TopLevelWindow: add some 2.8 methods; document; add missing CentreOnScreen
- [963] branches/wxruby2/wxwidgets_282/doc/textile/dialog.txtl: Added a few missing methods and cleaned up a bit.
- [766] trunk/wxruby2: Added item_data aliases for client_data functions, update doc & tests;
