]>
git.saurik.com Git - wxWidgets.git/blob - interface/vscroll.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: interface of wxVarHScrollHelper
4 // Author: wxWidgets team
6 // Licence: wxWindows license
7 /////////////////////////////////////////////////////////////////////////////
10 @class wxVarScrollHelperBase
13 This class provides all common base functionality for scroll calculations
14 shared among all variable scrolled window implementations as well as
15 automatic scrollbar functionality, saved scroll positions, controlling
16 target windows to be scrolled, as well as defining all required virtual
17 functions that need to be implemented for any orientation specific work.
19 Documentation of this class is provided specifically for referencing use
20 of the functions provided by this class for use with the variable scrolled
21 windows that derive from here. You will likely want to derive your window
22 from one of the already implemented variable scrolled windows rather than
23 from wxVarScrollHelperBase directly.
28 @see wxHScrolledWindow, wxHVScrolledWindow, wxVScrolledWindow
30 class wxVarScrollHelperBase
34 Constructor taking the target window to be scrolled by this helper
35 class. This will attach scroll event handlers to the target window to
36 catch and handle scroll events appropriately.
38 wxVarScrollHelperBase(wxWindow
* winToScroll
);
41 Virtual destructor for detaching scroll event handlers attached with
44 virtual ~wxVarScrollHelperBase();
47 Translates the logical coordinate given to the current device
48 coordinate. For example, if the window is scrolled 10 units and each
49 scroll unit represents 10 device units (which may not be the case since
50 this class allows for variable scroll unit sizes), a call to this
51 function with a coordinate of 15 will return -85.
53 @see CalcUnscrolledPosition()
55 int CalcScrolledPosition(int coord
) const;
58 Translates the device coordinate given to the corresponding logical
59 coordinate. For example, if the window is scrolled 10 units and each
60 scroll unit represents 10 device units (which may not be the case since
61 this class allows for variable scroll unit sizes), a call to this
62 function with a coordinate of 15 will return 115.
64 @see CalcScrolledPosition()
66 int CalcUnscrolledPosition(int coord
) const;
69 With physical scrolling on (when this is @true), the device origin is
70 changed properly when a wxPaintDC is prepared, children are actually
71 moved and laid out properly, and the contents of the window (pixels)
72 are actually moved. When this is @false, you are responsible for
73 repainting any invalidated areas of the window yourself to account for
74 the new scroll position.
76 void EnablePhysicalScrolling(bool scrolling
= true);
79 When the number of scroll units change, we try to estimate the total
80 size of all units when the full window size is needed (i.e. to
81 calculate the scrollbar thumb size). This is a rather expensive
82 operation in terms of unit access, so if the user code may estimate the
83 average size better or faster than we do, it should override this
84 function to implement its own logic. This function should return the
85 best guess for the total virtual window size.
87 @note Although returning a totally wrong value would still work, it
88 risks resulting in very strange scrollbar behaviour so this
89 function should really try to make the best guess possible.
91 virtual wxCoord
EstimateTotalSize() const;
94 This function needs to be overridden in the in the derived class to
95 return the window size with respect to the opposing orientation. If
96 this is a vertical scrolled window, it should return the height.
98 @see GetOrientationTargetSize()
100 virtual int GetNonOrientationTargetSize() const;
103 This function need to be overridden to return the orientation that this
104 helper is working with, either @c wxHORIZONTAL or @c wxVERTICAL.
106 virtual wxOrientation
GetOrientation() const;
109 This function needs to be overridden in the in the derived class to
110 return the window size with respect to the orientation this helper is
111 working with. If this is a vertical scrolled window, it should return
114 @see GetNonOrientationTargetSize()
116 virtual int GetOrientationTargetSize() const;
119 This function will return the target window this helper class is
122 @see SetTargetWindow()
124 wxWindow
* GetTargetWindow() const;
127 Returns the index of the first visible unit based on the scroll
130 size_t GetVisibleBegin() const;
133 Returns the index of the last visible unit based on the scroll
134 position. This includes the last unit even if it is only partially
137 size_t GetVisibleEnd() const;
140 Returns @true if the given scroll unit is currently visible (even if
141 only partially visible) or @false otherwise.
143 bool IsVisible(size_t unit
) const;
146 This function must be overridden in the derived class, and should
147 return the size of the given unit in pixels.
149 virtual wxCoord
OnGetUnitSize(size_t unit
) const;
152 This function doesn't have to be overridden but it may be useful to do
153 so if calculating the units' sizes is a relatively expensive operation
154 as it gives your code a chance to calculate several of them at once and
155 cache the result if necessary.
157 OnGetUnitsSizeHint() is normally called just before OnGetUnitSize() but
158 you shouldn't rely on the latter being called for all units in the
159 interval specified here. It is also possible that OnGetUnitSize() will
160 be called for units outside of this interval, so this is really just a
163 Finally, note that @a unitMin is inclusive, while @a unitMax is
166 virtual void OnGetUnitsSizeHint(size_t unitMin
, size_t unitMax
) const;
169 Recalculate all parameters and repaint all units.
171 virtual void RefreshAll();
174 Normally the window will scroll itself, but in some rare occasions you
175 might want it to scroll (part of) another window (e.g. a child of it in
176 order to scroll only a portion the area between the scrollbars like a
177 spreadsheet where only the cell area will move).
179 @see GetTargetWindow()
181 void SetTargetWindow(wxWindow
* target
);
184 Update the thumb size shown by the scrollbar.
186 virtual void UpdateScrollbar();
189 Returns the virtual scroll unit under the device unit given accounting
190 for scroll position or @c wxNOT_FOUND if none (i.e. if it is below the
193 int VirtualHitTest(wxCoord coord
) const;
199 @class wxVarVScrollHelper
202 This class provides functions wrapping the wxVarScrollHelperBase class,
203 targeted for vertical-specific scrolling.
205 Like wxVarScrollHelperBase, this class is mostly only useful to those
206 classes built into wxWidgets deriving from here, and this documentation is
207 mostly only provided for referencing the functions provided by this class.
208 You will likely want to derive your window from wxVScrolledWindow rather
209 than from here directly.
214 @see wxHScrolledWindow, wxHVScrolledWindow, wxVScrolledWindow
216 class wxVarVScrollHelper
: public wxVarScrollHelperBase
220 Constructor taking the target window to be scrolled by this helper
221 class. This will attach scroll event handlers to the target window to
222 catch and handle scroll events appropriately.
224 wxVarVScrollHelper(wxWindow
* winToScroll
);
227 This class forwards calls from EstimateTotalSize() to this function so
228 derived classes can override either just the height or the width
229 estimation, or just estimate both differently if desired in any
230 wxHVScrolledWindow derived class.
232 @note This function will not be called if EstimateTotalSize() is
233 overridden in your derived class.
235 virtual wxCoord
EstimateTotalHeight() const;
238 Returns the number of rows the target window contains.
242 size_t GetRowCount() const;
245 Returns the index of the first visible row based on the scroll
248 size_t GetVisibleRowsBegin() const;
251 Returns the index of the last visible row based on the scroll position.
252 This includes the last row even if it is only partially visible.
254 size_t GetVisibleRowsEnd() const;
257 Returns @true if the given row is currently visible (even if only
258 partially visible) or @false otherwise.
260 bool IsRowVisible(size_t row
) const;
263 This function must be overridden in the derived class, and should
264 return the height of the given row in pixels.
266 virtual wxCoord
OnGetRowHeight(size_t row
) const;
269 This function doesn't have to be overridden but it may be useful to do
270 so if calculating the rows' sizes is a relatively expensive operation
271 as it gives your code a chance to calculate several of them at once and
272 cache the result if necessary.
274 OnGetRowsHeightHint() is normally called just before OnGetRowHeight()
275 but you shouldn't rely on the latter being called for all rows in the
276 interval specified here. It is also possible that OnGetRowHeight() will
277 be called for units outside of this interval, so this is really just a
280 Finally, note that @a rowMin is inclusive, while @a rowMax is
283 virtual void OnGetRowsHeightHint(size_t rowMin
, size_t rowMax
) const;
286 Triggers a refresh for just the given row's area of the window if it's
289 virtual void RefreshRow(size_t row
);
292 Triggers a refresh for the area between the specified range of rows
295 virtual void RefreshRows(size_t from
, size_t to
);
298 Scroll by the specified number of pages which may be positive (to
299 scroll down) or negative (to scroll up).
301 virtual bool ScrollRowPages(int pages
);
304 Scroll by the specified number of rows which may be positive (to scroll
305 down) or negative (to scroll up).
307 @return @true if the window was scrolled, @false otherwise (for
308 example, if we're trying to scroll down but we are already
309 showing the last row).
311 virtual bool ScrollRows(int rows
);
314 Scroll to the specified row. It will become the first visible row in
317 @return @true if we scrolled the window, @false if nothing was done.
319 bool ScrollToRow(size_t row
);
322 Set the number of rows the window contains. The derived class must
323 provide the heights for all rows with indices up to the one given here
324 in it's OnGetRowHeight() implementation.
328 void SetRowCount(size_t rowCount
);
334 @class wxVarHScrollHelper
337 This class provides functions wrapping the wxVarScrollHelperBase class,
338 targeted for horizontal-specific scrolling.
340 Like wxVarScrollHelperBase, this class is mostly only useful to those
341 classes built into wxWidgets deriving from here, and this documentation is
342 mostly only provided for referencing the functions provided by this class.
343 You will likely want to derive your window from wxHScrolledWindow rather
344 than from here directly.
349 @see wxHScrolledWindow, wxHVScrolledWindow, wxVScrolledWindow
351 class wxVarHScrollHelper
: public wxVarScrollHelperBase
355 Constructor taking the target window to be scrolled by this helper
356 class. This will attach scroll event handlers to the target window to
357 catch and handle scroll events appropriately.
359 wxVarHScrollHelper(wxWindow
* winToScroll
);
362 This class forwards calls from EstimateTotalSize() to this function so
363 derived classes can override either just the height or the width
364 estimation, or just estimate both differently if desired in any
365 wxHVScrolledWindow derived class.
367 @note This function will not be called if EstimateTotalSize() is
368 overridden in your derived class.
370 virtual wxCoord
EstimateTotalWidth() const;
373 Returns the number of columns the target window contains.
375 @see SetColumnCount()
377 size_t GetColumnCount() const;
380 Returns the index of the first visible column based on the scroll
383 size_t GetVisibleColumnsBegin() const;
386 Returns the index of the last visible column based on the scroll
387 position. This includes the last column even if it is only partially
390 size_t GetVisibleColumnsEnd() const;
393 Returns @true if the given column is currently visible (even if only
394 partially visible) or @false otherwise.
396 bool IsColumnVisible(size_t column
) const;
399 This function must be overridden in the derived class, and should
400 return the width of the given column in pixels.
402 virtual wxCoord
OnGetColumnWidth(size_t column
) const;
405 This function doesn't have to be overridden but it may be useful to do
406 so if calculating the columns' sizes is a relatively expensive
407 operation as it gives your code a chance to calculate several of them
408 at once and cache the result if necessary.
410 OnGetColumnsWidthHint() is normally called just before
411 OnGetColumnWidth() but you shouldn't rely on the latter being called
412 for all columns in the interval specified here. It is also possible
413 that OnGetColumnWidth() will be called for units outside of this
414 interval, so this is really just a hint, not a promise.
416 Finally, note that @a columnMin is inclusive, while @a columnMax is
419 virtual void OnGetColumnsWidthHint(size_t columnMin
,
420 size_t columnMax
) const;
423 Triggers a refresh for just the given column's area of the window if
426 virtual void RefreshColumn(size_t column
);
429 Triggers a refresh for the area between the specified range of columns
432 virtual void RefreshColumns(size_t from
, size_t to
);
435 Scroll by the specified number of pages which may be positive (to
436 scroll right) or negative (to scroll left).
438 virtual bool ScrollColumnPages(int pages
);
441 Scroll by the specified number of columns which may be positive (to
442 scroll right) or negative (to scroll left).
444 @return @true if the window was scrolled, @false otherwise (for
445 example, if we're trying to scroll right but we are already
446 showing the last column).
448 virtual bool ScrollColumns(int columns
);
451 Scroll to the specified column. It will become the first visible column
454 @return @true if we scrolled the window, @false if nothing was done.
456 bool ScrollToColumn(size_t column
);
459 Set the number of columns the window contains. The derived class must
460 provide the widths for all columns with indices up to the one given
461 here in it's OnGetColumnWidth() implementation.
463 @see GetColumnCount()
465 void SetColumnCount(size_t columnCount
);
471 @class wxVarHVScrollHelper
474 This class provides functions wrapping the wxVarHScrollHelper and
475 wxVarVScrollHelper classes, targeted for scrolling a window in both axis.
476 Since this class is also the join class of the horizontal and vertical
477 scrolling functionality, it also addresses some wrappers that help avoid
478 the need to specify class scope in your wxHVScrolledWindow derived class
479 when using wxVarScrollHelperBase functionality.
481 Like all three of it's scroll helper base classes, this class is mostly
482 only useful to those classes built into wxWidgets deriving from here, and
483 this documentation is mostly only provided for referencing the functions
484 provided by this class. You will likely want to derive your window from
485 wxHVScrolledWindow rather than from here directly.
490 @see wxHScrolledWindow, wxHVScrolledWindow, wxVScrolledWindow
492 class wxVarHVScrollHelper
: public wxVarVScrollHelper
,
493 public wxVarHScrollHelper
497 Constructor taking the target window to be scrolled by this helper
498 class. This will attach scroll event handlers to the target window to
499 catch and handle scroll events appropriately.
501 wxVarHVScrollHelper(wxWindow
* winToScroll
);
504 With physical scrolling on (when this is @true), the device origin is
505 changed properly when a wxPaintDC is prepared, children are actually
506 moved and laid out properly, and the contents of the window (pixels)
507 are actually moved. When this is @false, you are responsible for
508 repainting any invalidated areas of the window yourself to account for
509 the new scroll position.
512 Specifies if physical scrolling should be turned on when scrolling
515 Specifies if physical scrolling should be turned on when scrolling
518 void EnablePhysicalScrolling(bool vscrolling
= true,
519 bool hscrolling
= true);
522 Returns the number of columns and rows the target window contains.
524 @see SetRowColumnCount()
526 wxSize
GetRowColumnCount() const;
529 Returns the index of the first visible column and row based on the
530 current scroll position.
532 wxPosition
GetVisibleBegin() const;
535 Returns the index of the last visible column and row based on the
536 scroll position. This includes any partially visible columns or rows.
538 wxPosition
GetVisibleEnd() const;
542 Returns @true if both the given row and column are currently visible
543 (even if only partially visible) or @false otherwise.
545 bool IsVisible(size_t row
, size_t column
) const;
546 bool IsVisible(const wxPosition
& pos
) const;
551 Triggers a refresh for just the area shared between the given row and
552 column of the window if it is visible.
554 virtual void RefreshRowColumn(size_t row
, size_t column
);
555 virtual void RefreshRowColumn(const wxPosition
& pos
);
560 Triggers a refresh for the visible area shared between all given rows
561 and columns (inclusive) of the window. If the target window for both
562 orientations is the same, the rectangle of cells is refreshed; if the
563 target windows differ, the entire client size opposite the orientation
564 direction is refreshed between the specified limits.
566 virtual void RefreshRowsColumns(size_t fromRow
, size_t toRow
,
567 size_t fromColumn
, size_t toColumn
);
568 virtual void RefreshRowsColumns(const wxPosition
& from
,
569 const wxPosition
& to
);
574 Scroll to the specified row and column. It will become the first
575 visible row and column in the window. Returns @true if we scrolled the
576 window, @false if nothing was done.
578 bool ScrollToRowColumn(size_t row
, size_t column
);
579 bool ScrollToRowColumn(const wxPosition
& pos
);
583 Set the number of rows and columns the target window will contain. The
584 derived class must provide the sizes for all rows and columns with
585 indices up to the ones given here in it's OnGetRowHeight() and
586 OnGetColumnWidth() implementations, respectively.
588 @see GetRowColumnCount()
590 void SetRowColumnCount(size_t rowCount
, size_t columnCount
);
594 Returns the virtual scroll unit under the device unit given accounting
595 for scroll position or @c wxNOT_FOUND (for the row, column, or possibly
596 both values) if none.
598 wxPosition
VirtualHitTest(wxCoord x
, wxCoord y
) const;
599 wxPosition
VirtualHitTest(const wxPoint
& pos
) const;
606 @class wxVScrolledWindow
609 In the name of this class, "V" may stand for "variable" because it can be
610 used for scrolling rows of variable heights; "virtual", because it is not
611 necessary to know the heights of all rows in advance -- only those which
612 are shown on the screen need to be measured; or even "vertical", because
613 this class only supports scrolling vertically.
615 In any case, this is a generalization of wxScrolled which can be only used
616 when all rows have the same heights. It lacks some other wxScrolled
617 features however, notably it can't scroll specific pixel sizes of the
618 window or its exact client area size.
620 To use this class, you need to derive from it and implement the
621 OnGetRowHeight() pure virtual method. You also must call SetRowCount() to
622 let the base class know how many rows it should display, but from that
623 moment on the scrolling is handled entirely by wxVScrolledWindow. You only
624 need to draw the visible part of contents in your @c OnPaint() method as
625 usual. You should use GetVisibleRowsBegin() and GetVisibleRowsEnd() to
626 select the lines to display. Note that the device context origin is not
627 shifted so the first visible row always appears at the point (0, 0) in
628 physical as well as logical coordinates.
630 @section wxWidgets 2.8 Compatibility Functions
632 The following functions provide backwards compatibility for applications
633 originally built using wxVScrolledWindow in 2.6 or 2.8. Originally,
634 wxVScrolledWindow referred to scrolling "lines". We now use "units" in
635 wxVarScrollHelperBase to avoid implying any orientation (since the
636 functions are used for both horizontal and vertical scrolling in derived
637 classes). And in the new wxVScrolledWindow and wxHScrolledWindow classes,
638 we refer to them as "rows" and "columns", respectively. This is to help
639 clear some confusion in not only those classes, but also in
640 wxHVScrolledWindow where functions are inherited from both.
642 You are encouraged to update any existing code using these function to use
643 the new replacements mentioned below, and avoid using these functions for
644 any new code as they are deprecated.
647 @row2col{ <tt>size_t %GetFirstVisibleLine() const</tt>,
648 Deprecated for GetVisibleRowsBegin(). }
649 @row2col{ <tt>size_t %GetLastVisibleLine() const</tt>,
650 Deprecated for GetVisibleRowsEnd(). This function originally had a
651 slight design flaw in that it was possible to return
652 <tt>(size_t)-1</tt> (ie: a large positive number) if the scroll
653 position was 0 and the first line wasn't completely visible. }
654 @row2col{ <tt>size_t %GetLineCount() const</tt>,
655 Deprecated for GetRowCount(). }
656 @row2col{ <tt>int %HitTest(wxCoord x\, wxCoord y) const
657 @n int %HitTest(const wxPoint& pt) const</tt>,
658 Deprecated for VirtualHitTest(). }
659 @row2col{ <tt>virtual wxCoord %OnGetLineHeight(size_t line) const</tt>,
660 Deprecated for OnGetRowHeight(). }
661 @row2col{ <tt>virtual void %OnGetLinesHint(size_t lineMin\, size_t lineMax) const</tt>,
662 Deprecated for OnGetRowsHeightHint(). }
663 @row2col{ <tt>virtual void %RefreshLine(size_t line)</tt>,
664 Deprecated for RefreshRow(). }
665 @row2col{ <tt>virtual void %RefreshLines(size_t from\, size_t to)</tt>,
666 Deprecated for RefreshRows(). }
667 @row2col{ <tt>virtual bool %ScrollLines(int lines)</tt>,
668 Deprecated for ScrollRows(). }
669 @row2col{ <tt>virtual bool %ScrollPages(int pages)</tt>,
670 Deprecated for ScrollRowPages(). }
671 @row2col{ <tt>bool %ScrollToLine(size_t line)</tt>,
672 Deprecated for ScrollToRow(). }
673 @row2col{ <tt>void %SetLineCount(size_t count)</tt>,
674 Deprecated for SetRowCount(). }
680 @see wxHScrolledWindow, wxHVScrolledWindow
682 class wxVScrolledWindow
: public wxPanel
, public wxVarVScrollHelper
686 Default constructor, you must call Create() later.
690 This is the normal constructor, no need to call Create() after using
693 @note @c wxVSCROLL is always automatically added to the style, there is
694 no need to specify it explicitly.
697 The parent window, must not be @NULL.
699 The identifier of this window, wxID_ANY by default.
701 The initial window position.
703 The initial window size.
705 The window style. There are no special style bits defined for this
708 The name for this window; usually not used.
710 wxVScrolledWindow(wxWindow
* parent
, wxWindowID id
= wxID_ANY
,
711 const wxPoint
& pos
= wxDefaultPosition
,
712 const wxSize
& size
= wxDefaultSize
, long style
= 0,
713 const wxString
& name
= wxPanelNameStr
);
716 Same as the non-default constuctor, but returns a status code: @true if
717 ok, @false if the window couldn't be created.
719 Just as with the constructor, the @c wxVSCROLL style is always used,
720 there is no need to specify it explicitly.
722 bool Create(wxWindow
* parent
, wxWindowID id
= wxID_ANY
,
723 const wxPoint
& pos
= wxDefaultPosition
,
724 const wxSize
& size
= wxDefaultSize
, long style
= 0,
725 const wxString
& name
= wxPanelNameStr
);
731 @class wxHScrolledWindow
734 In the name of this class, "H" stands for "horizontal" because it can be
735 used for scrolling columns of variable widths. It is not necessary to know
736 the widths of all columns in advance -- only those which are shown on the
737 screen need to be measured.
739 In any case, this is a generalization of wxScrolled which can be only used
740 when all columns have the same widths. It lacks some other wxScrolled
741 features however, notably it can't scroll specific pixel sizes of the
742 window or its exact client area size.
744 To use this class, you need to derive from it and implement the
745 OnGetColumnWidth() pure virtual method. You also must call SetColumnCount()
746 to let the base class know how many columns it should display, but from
747 that moment on the scrolling is handled entirely by wxHScrolledWindow. You
748 only need to draw the visible part of contents in your @c OnPaint() method
749 as usual. You should use GetVisibleColumnsBegin() and
750 GetVisibleColumnsEnd() to select the lines to display. Note that the device
751 context origin is not shifted so the first visible column always appears at
752 the point (0, 0) in physical as well as logical coordinates.
757 @see wxHVScrolledWindow, wxVScrolledWindow
759 class wxHScrolledWindow
: public wxPanel
, public wxVarHScrollHelper
763 Default constructor, you must call Create() later.
767 This is the normal constructor, no need to call Create() after using
770 @note @c wxHSCROLL is always automatically added to the style, there is
771 no need to specify it explicitly.
774 The parent window, must not be @NULL.
776 The identifier of this window, wxID_ANY by default.
778 The initial window position.
780 The initial window size.
782 The window style. There are no special style bits defined for this
785 The name for this window; usually not used.
787 wxHScrolledWindow(wxWindow
* parent
, wxWindowID id
= wxID_ANY
,
788 const wxPoint
& pos
= wxDefaultPosition
,
789 const wxSize
& size
= wxDefaultSize
, long style
= 0,
790 const wxString
& name
= wxPanelNameStr
);
793 Same as the non-default constuctor, but returns a status code: @true if
794 ok, @false if the window couldn't be created.
796 Just as with the constructor, the @c wxHSCROLL style is always used,
797 there is no need to specify it explicitly.
799 bool Create(wxWindow
* parent
, wxWindowID id
= wxID_ANY
,
800 const wxPoint
& pos
= wxDefaultPosition
,
801 const wxSize
& size
= wxDefaultSize
, long style
= 0,
802 const wxString
& name
= wxPanelNameStr
);
808 @class wxHVScrolledWindow
811 This window inherits all functionality of both vertical and horizontal,
812 variable scrolled windows. It automatically handles everything needed to
813 scroll both axis simultaneously with both variable row heights and variable
816 In any case, this is a generalization of wxScrolled which can be only used
817 when all rows and columns are the same size. It lacks some other wxScrolled
818 features however, notably it can't scroll specific pixel sizes of the
819 window or its exact client area size.
821 To use this class, you must derive from it and implement both the
822 OnGetRowHeight() and OnGetColumnWidth() pure virtual methods to let the
823 base class know how many rows and columns it should display. You also need
824 to set the total rows and columns the window contains, but from that moment
825 on the scrolling is handled entirely by wxHVScrolledWindow. You only need
826 to draw the visible part of contents in your @c OnPaint() method as usual.
827 You should use GetVisibleBegin() and GetVisibleEnd() to select the lines to
828 display. Note that the device context origin is not shifted so the first
829 visible row and column always appear at the point (0, 0) in physical as
830 well as logical coordinates.
835 @see wxHScrolledWindow, wxVScrolledWindow
837 class wxHVScrolledWindow
: public wxPanel
, public wxVarHVScrollHelper
841 Default constructor, you must call Create() later.
843 wxHVScrolledWindow();
845 This is the normal constructor, no need to call Create() after using
848 @note @c wxHSCROLL and @c wxVSCROLL are always automatically added to
849 the style, there is no need to specify it explicitly.
852 The parent window, must not be @NULL.
854 The identifier of this window, wxID_ANY by default.
856 The initial window position.
858 The initial window size.
860 The window style. There are no special style bits defined for this
863 The name for this window; usually not used.
865 wxHVScrolledWindow(wxWindow
* parent
, wxWindowID id
= wxID_ANY
,
866 const wxPoint
& pos
= wxDefaultPosition
,
867 const wxSize
& size
= wxDefaultSize
, long style
= 0,
868 const wxString
& name
= wxPanelNameStr
);
871 Same as the non-default constuctor, but returns a status code: @true if
872 ok, @false if the window couldn't be created.
874 Just as with the constructor, the @c wxHSCROLL and @c wxVSCROLL styles
875 are always used, there is no need to specify them explicitly.
877 bool Create(wxWindow
* parent
, wxWindowID id
= wxID_ANY
,
878 const wxPoint
& pos
= wxDefaultPosition
,
879 const wxSize
& size
= wxDefaultSize
, long style
= 0,
880 const wxString
& name
= wxPanelNameStr
);