X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/830b7aa7b235888198fcc80c6b1fd0e792b143c6..1b7751aaa9a86d76a850b9267bc0c201e3cea30f:/interface/wx/sashwin.h diff --git a/interface/wx/sashwin.h b/interface/wx/sashwin.h index 78cc5e2022..79a4bd1ebd 100644 --- a/interface/wx/sashwin.h +++ b/interface/wx/sashwin.h @@ -3,9 +3,18 @@ // Purpose: interface of wxSashWindow // Author: wxWidgets team // RCS-ID: $Id$ -// Licence: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// +/** + wxSashWindow flags +*/ +#define wxSW_NOBORDER 0x0000 +#define wxSW_BORDER 0x0020 +#define wxSW_3DSASH 0x0040 +#define wxSW_3DBORDER 0x0080 +#define wxSW_3D (wxSW_3DSASH | wxSW_3DBORDER) + /** See wxSashWindow. @@ -50,12 +59,12 @@ enum wxSashDragStatus Draws a thin black border. @endStyleTable - @beginEventTable{wxSashEvent} + @beginEventEmissionTable{wxSashEvent} @event{EVT_SASH_DRAGGED(id, func)} - Process a wxEVT_SASH_DRAGGED event, when the user has finished + Process a @c wxEVT_SASH_DRAGGED event, when the user has finished dragging a sash. @event{EVT_SASH_DRAGGED_RANGE(id1, id2, func)} - Process a wxEVT_SASH_DRAGGED_RANGE event, when the user has + Process a @c wxEVT_SASH_DRAGGED_RANGE event, when the user has finished dragging a sash. The event handler is called when windows with ids in the given range have their sashes dragged. @endEventTable @@ -134,17 +143,6 @@ public: */ bool GetSashVisible(wxSashEdgePosition edge) const; - /** - Returns @true if the sash has a border, @false otherwise. - This function is obsolete since the sash border property is unused. - - @param edge - Edge. One of wxSASH_TOP, wxSASH_RIGHT, wxSASH_BOTTOM, wxSASH_LEFT. - - @see SetSashBorder() - */ - bool HasBorder(wxSashEdgePosition edge) const; - /** Sets the maximum window size in the x direction. */ @@ -165,17 +163,6 @@ public: */ virtual void SetMinimumSizeY(int min); - /** - Call this function to give the sash a border, or remove the border. - This function is obsolete since the sash border property is unused. - - @param edge - Edge to change. One of wxSASH_TOP, wxSASH_RIGHT, wxSASH_BOTTOM, wxSASH_LEFT. - @param hasBorder - @true to give the sash a border visible, @false to remove it. - */ - void SetSashBorder(wxSashEdgePosition edge, bool hasBorder); - /** Call this function to make a sash visible or invisible on a particular edge. @@ -187,6 +174,42 @@ public: @see GetSashVisible() */ void SetSashVisible(wxSashEdgePosition edge, bool visible); + + + /** + Get border size + */ + int GetEdgeMargin(wxSashEdgePosition edge) const; + + /** + Sets the default sash border size + */ + void SetDefaultBorderSize(int width); + + /** + Gets the default sash border size + */ + int GetDefaultBorderSize() const; + + /** + Sets the additional border size between child and sash window + */ + void SetExtraBorderSize(int width); + + /** + Gets the addition border size between child and sash window + */ + int GetExtraBorderSize() const; + + /** + Tests for x, y over sash + */ + wxSashEdgePosition SashHitTest(int x, int y, int tolerance = 2); + + /** + Resizes subwindows + */ + void SizeWindows(); }; @@ -212,9 +235,9 @@ public: @beginEventTable{wxSashEvent} @event{EVT_SASH_DRAGGED(id, func)} - Process a wxEVT_SASH_DRAGGED event, when the user has finished dragging a sash. + Process a @c wxEVT_SASH_DRAGGED event, when the user has finished dragging a sash. @event{EVT_SASH_DRAGGED_RANGE(id1, id2, func)} - Process a wxEVT_SASH_DRAGGED_RANGE event, when the user has finished + Process a @c wxEVT_SASH_DRAGGED_RANGE event, when the user has finished dragging a sash. The event handler is called when windows with ids in the given range have their sashes dragged. @endEventTable @@ -252,5 +275,11 @@ public: The return value is one of wxSASH_TOP, wxSASH_RIGHT, wxSASH_BOTTOM, wxSASH_LEFT. */ wxSashEdgePosition GetEdge() const; + + + void SetEdge(wxSashEdgePosition edge); + void SetDragRect(const wxRect& rect); + void SetDragStatus(wxSashDragStatus status); }; +wxEventType wxEVT_SASH_DRAGGED;