Removed minor differences between wxMSW and wxGTK
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1216 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -82,7 +82,7 @@ class WXDLLEXPORT wxGenericColourDialog: public wxDialog
|
||||
bool Create(wxWindow *parent, wxColourData *data = (wxColourData *) NULL);
|
||||
|
||||
int ShowModal(void);
|
||||
wxColourData GetColourData(void) { return colourData; }
|
||||
wxColourData &GetColourData(void) { return colourData; }
|
||||
|
||||
// Internal functions
|
||||
void OnMouseEvent(wxMouseEvent& event);
|
||||
|
@@ -582,9 +582,10 @@ class wxListCtrl: public wxControl
|
||||
wxImageList *GetImageList(int which) const;
|
||||
void SetImageList(wxImageList *imageList, int which) ;
|
||||
bool Arrange( int flag = wxLIST_ALIGN_DEFAULT ); // always wxLIST_ALIGN_LEFT in wxGLC
|
||||
void ClearAll();
|
||||
bool DeleteItem( long item );
|
||||
bool DeleteAllItems(void) ;
|
||||
void DeleteAllColumns(void) ;
|
||||
bool DeleteAllItems(void);
|
||||
bool DeleteAllColumns(void);
|
||||
bool DeleteColumn( int col );
|
||||
// wxText& Edit(long item) ; // not supported in wxGLC
|
||||
bool EnsureVisible( long item );
|
||||
|
@@ -23,6 +23,21 @@
|
||||
#include "wx/scrolwin.h"
|
||||
#include "wx/textctrl.h"
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
// constants
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
// values for the `flags' parameter of wxTreeCtrl::HitTest() which determine
|
||||
// where exactly the specified point is situated:
|
||||
static const int wxTREE_HITTEST_NOWHERE = 0x0004;
|
||||
// on the bitmap associated with an item.
|
||||
static const int wxTREE_HITTEST_ONITEMICON = 0x0020;
|
||||
// on the label (string) associated with an item.
|
||||
static const int wxTREE_HITTEST_ONITEMLABEL = 0x0080;
|
||||
// anywhere on the item
|
||||
static const int wxTREE_HITTEST_ONITEM = wxTREE_HITTEST_ONITEMICON |
|
||||
wxTREE_HITTEST_ONITEMLABEL;
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
// forward declaration
|
||||
// -----------------------------------------------------------------------------
|
||||
@@ -186,9 +201,10 @@ public:
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = wxTR_HAS_BUTTONS | wxTR_LINES_AT_ROOT,
|
||||
const wxValidator &validator = wxDefaultValidator,
|
||||
const wxString& name = "wxTreeCtrl")
|
||||
{
|
||||
Create(parent, id, pos, size, style, name);
|
||||
Create(parent, id, pos, size, style, validator, name);
|
||||
}
|
||||
|
||||
virtual ~wxTreeCtrl();
|
||||
@@ -197,6 +213,7 @@ public:
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = wxTR_HAS_BUTTONS | wxTR_LINES_AT_ROOT,
|
||||
const wxValidator &validator = wxDefaultValidator,
|
||||
const wxString& name = "wxTreeCtrl");
|
||||
|
||||
// accessors
|
||||
@@ -375,6 +392,12 @@ public:
|
||||
// scroll to this item (but don't expand its parent)
|
||||
void ScrollTo(const wxTreeItemId& item);
|
||||
|
||||
// The first function is more portable (because easier to implement
|
||||
// on other platforms), but the second one returns some extra info.
|
||||
wxTreeItemId HitTest(const wxPoint& point)
|
||||
{ int dummy; return HitTest(point, dummy); }
|
||||
wxTreeItemId HitTest(const wxPoint& point, int& flags);
|
||||
|
||||
// start editing the item label: this (temporarily) replaces the item
|
||||
// with a one line edit control. The item will be selected if it hadn't
|
||||
// been before. textCtrlClass parameter allows you to create an edit
|
||||
|
@@ -51,7 +51,6 @@ class wxBrush: public wxGDIObject
|
||||
wxColour &GetColour() const;
|
||||
wxBitmap *GetStipple() const;
|
||||
|
||||
|
||||
void SetColour( const wxColour& col );
|
||||
void SetColour( unsigned char r, unsigned char g, unsigned char b );
|
||||
void SetStyle( int style );
|
||||
|
@@ -48,6 +48,8 @@ public:
|
||||
|
||||
bool IsChecked( int index ) const;
|
||||
void Check( int index, bool check = TRUE );
|
||||
|
||||
int GetItemHeight();
|
||||
|
||||
};
|
||||
|
||||
|
@@ -189,16 +189,16 @@ public:
|
||||
virtual void Clear() = 0;
|
||||
|
||||
virtual void SetFont( const wxFont &font ) = 0;
|
||||
virtual const wxFont& GetFont() const { return m_font; };
|
||||
virtual wxFont& GetFont() const { return (wxFont&)m_font; };
|
||||
|
||||
virtual void SetPen( const wxPen &pen ) = 0;
|
||||
virtual const wxPen& GetPen() const { return m_pen; };
|
||||
virtual wxPen& GetPen() const { return (wxPen&)m_pen; };
|
||||
|
||||
virtual void SetBrush( const wxBrush &brush ) = 0;
|
||||
virtual const wxBrush& GetBrush() const { return m_brush; };
|
||||
virtual wxBrush& GetBrush() const { return (wxBrush&)m_brush; };
|
||||
|
||||
virtual void SetBackground( const wxBrush &brush ) = 0;
|
||||
virtual const wxBrush& GetBackground() const { return m_backgroundBrush; };
|
||||
virtual wxBrush& GetBackground() const { return (wxBrush&)m_backgroundBrush; };
|
||||
|
||||
virtual void SetLogicalFunction( int function ) = 0;
|
||||
virtual int GetLogicalFunction() { return m_logicalFunction; };
|
||||
|
@@ -49,6 +49,8 @@ public:
|
||||
|
||||
int FindMenuItem( const wxString &menuString, const wxString &itemString ) const;
|
||||
wxMenuItem* FindMenuItemById( int id ) const;
|
||||
inline wxMenuItem* FindMenuItemForId( int id ) const
|
||||
{ return FindMenuItemById( id ); }
|
||||
|
||||
void Check( int id, bool check );
|
||||
bool Checked( int id ) const;
|
||||
|
@@ -134,11 +134,23 @@ public:
|
||||
virtual void SetSize( int x, int y, int width, int height,
|
||||
int sizeFlags = wxSIZE_AUTO );
|
||||
virtual void SetSize( int width, int height );
|
||||
|
||||
virtual void Move( int x, int y );
|
||||
|
||||
virtual void GetSize( int *width, int *height ) const;
|
||||
wxSize GetSize() const { int w, h; GetSize(& w, & h); return wxSize(w, h); }
|
||||
|
||||
virtual void SetClientSize( int const width, int const height );
|
||||
|
||||
virtual void GetClientSize( int *width, int *height ) const;
|
||||
wxSize GetClientSize() const { int w, h; GetClientSize(& w, & h); return wxSize(w, h); }
|
||||
|
||||
virtual void GetPosition( int *x, int *y ) const;
|
||||
wxPoint GetPosition() const { int w, h; GetPosition(& w, & h); return wxPoint(w, h); }
|
||||
|
||||
wxRect GetRect() const
|
||||
{ int x, y, w, h; GetPosition(& x, & y); GetSize(& w, & h); return wxRect(x, y, w, h); }
|
||||
|
||||
virtual void Centre( int direction = wxHORIZONTAL );
|
||||
inline void Center(int direction = wxHORIZONTAL) { Centre(direction); }
|
||||
virtual void Fit();
|
||||
@@ -204,6 +216,8 @@ public:
|
||||
|
||||
void SetCursor( const wxCursor &cursor );
|
||||
|
||||
void WarpPointer(int x, int y);
|
||||
|
||||
virtual void Refresh( bool eraseBackground = TRUE, const wxRect *rect = (const wxRect *) NULL );
|
||||
virtual void Clear();
|
||||
|
||||
@@ -226,13 +240,13 @@ public:
|
||||
const wxFont *theFont = (const wxFont *) NULL, bool use16 = FALSE) const;
|
||||
|
||||
virtual void SetFont( const wxFont &font );
|
||||
virtual const wxFont& GetFont() { return m_font; }
|
||||
virtual wxFont& GetFont() { return m_font; }
|
||||
|
||||
// For backward compatibility
|
||||
inline virtual void SetButtonFont(const wxFont& font) { SetFont(font); }
|
||||
inline virtual void SetLabelFont(const wxFont& font) { SetFont(font); }
|
||||
inline virtual const wxFont& GetLabelFont() { return GetFont(); };
|
||||
inline virtual const wxFont& GetButtonFont() { return GetFont(); };
|
||||
inline virtual wxFont& GetLabelFont() { return GetFont(); };
|
||||
inline virtual wxFont& GetButtonFont() { return GetFont(); };
|
||||
|
||||
virtual void SetWindowStyleFlag( long flag );
|
||||
virtual long GetWindowStyleFlag() const;
|
||||
|
@@ -51,7 +51,6 @@ class wxBrush: public wxGDIObject
|
||||
wxColour &GetColour() const;
|
||||
wxBitmap *GetStipple() const;
|
||||
|
||||
|
||||
void SetColour( const wxColour& col );
|
||||
void SetColour( unsigned char r, unsigned char g, unsigned char b );
|
||||
void SetStyle( int style );
|
||||
|
@@ -48,6 +48,8 @@ public:
|
||||
|
||||
bool IsChecked( int index ) const;
|
||||
void Check( int index, bool check = TRUE );
|
||||
|
||||
int GetItemHeight();
|
||||
|
||||
};
|
||||
|
||||
|
@@ -189,16 +189,16 @@ public:
|
||||
virtual void Clear() = 0;
|
||||
|
||||
virtual void SetFont( const wxFont &font ) = 0;
|
||||
virtual const wxFont& GetFont() const { return m_font; };
|
||||
virtual wxFont& GetFont() const { return (wxFont&)m_font; };
|
||||
|
||||
virtual void SetPen( const wxPen &pen ) = 0;
|
||||
virtual const wxPen& GetPen() const { return m_pen; };
|
||||
virtual wxPen& GetPen() const { return (wxPen&)m_pen; };
|
||||
|
||||
virtual void SetBrush( const wxBrush &brush ) = 0;
|
||||
virtual const wxBrush& GetBrush() const { return m_brush; };
|
||||
virtual wxBrush& GetBrush() const { return (wxBrush&)m_brush; };
|
||||
|
||||
virtual void SetBackground( const wxBrush &brush ) = 0;
|
||||
virtual const wxBrush& GetBackground() const { return m_backgroundBrush; };
|
||||
virtual wxBrush& GetBackground() const { return (wxBrush&)m_backgroundBrush; };
|
||||
|
||||
virtual void SetLogicalFunction( int function ) = 0;
|
||||
virtual int GetLogicalFunction() { return m_logicalFunction; };
|
||||
|
@@ -49,6 +49,8 @@ public:
|
||||
|
||||
int FindMenuItem( const wxString &menuString, const wxString &itemString ) const;
|
||||
wxMenuItem* FindMenuItemById( int id ) const;
|
||||
inline wxMenuItem* FindMenuItemForId( int id ) const
|
||||
{ return FindMenuItemById( id ); }
|
||||
|
||||
void Check( int id, bool check );
|
||||
bool Checked( int id ) const;
|
||||
|
@@ -134,11 +134,23 @@ public:
|
||||
virtual void SetSize( int x, int y, int width, int height,
|
||||
int sizeFlags = wxSIZE_AUTO );
|
||||
virtual void SetSize( int width, int height );
|
||||
|
||||
virtual void Move( int x, int y );
|
||||
|
||||
virtual void GetSize( int *width, int *height ) const;
|
||||
wxSize GetSize() const { int w, h; GetSize(& w, & h); return wxSize(w, h); }
|
||||
|
||||
virtual void SetClientSize( int const width, int const height );
|
||||
|
||||
virtual void GetClientSize( int *width, int *height ) const;
|
||||
wxSize GetClientSize() const { int w, h; GetClientSize(& w, & h); return wxSize(w, h); }
|
||||
|
||||
virtual void GetPosition( int *x, int *y ) const;
|
||||
wxPoint GetPosition() const { int w, h; GetPosition(& w, & h); return wxPoint(w, h); }
|
||||
|
||||
wxRect GetRect() const
|
||||
{ int x, y, w, h; GetPosition(& x, & y); GetSize(& w, & h); return wxRect(x, y, w, h); }
|
||||
|
||||
virtual void Centre( int direction = wxHORIZONTAL );
|
||||
inline void Center(int direction = wxHORIZONTAL) { Centre(direction); }
|
||||
virtual void Fit();
|
||||
@@ -204,6 +216,8 @@ public:
|
||||
|
||||
void SetCursor( const wxCursor &cursor );
|
||||
|
||||
void WarpPointer(int x, int y);
|
||||
|
||||
virtual void Refresh( bool eraseBackground = TRUE, const wxRect *rect = (const wxRect *) NULL );
|
||||
virtual void Clear();
|
||||
|
||||
@@ -226,13 +240,13 @@ public:
|
||||
const wxFont *theFont = (const wxFont *) NULL, bool use16 = FALSE) const;
|
||||
|
||||
virtual void SetFont( const wxFont &font );
|
||||
virtual const wxFont& GetFont() { return m_font; }
|
||||
virtual wxFont& GetFont() { return m_font; }
|
||||
|
||||
// For backward compatibility
|
||||
inline virtual void SetButtonFont(const wxFont& font) { SetFont(font); }
|
||||
inline virtual void SetLabelFont(const wxFont& font) { SetFont(font); }
|
||||
inline virtual const wxFont& GetLabelFont() { return GetFont(); };
|
||||
inline virtual const wxFont& GetButtonFont() { return GetFont(); };
|
||||
inline virtual wxFont& GetLabelFont() { return GetFont(); };
|
||||
inline virtual wxFont& GetButtonFont() { return GetFont(); };
|
||||
|
||||
virtual void SetWindowStyleFlag( long flag );
|
||||
virtual long GetWindowStyleFlag() const;
|
||||
|
Reference in New Issue
Block a user