projects
/
wxWidgets.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
applying patch 1411230
[wxWidgets.git]
/
include
/
wx
/
gtk1
/
textctrl.h
diff --git
a/include/wx/gtk1/textctrl.h
b/include/wx/gtk1/textctrl.h
index cc1f3e68abada9a613087154c99c7e3953d3068b..29158f1e42faeed7118de81ff5c66d6111919411 100644
(file)
--- a/
include/wx/gtk1/textctrl.h
+++ b/
include/wx/gtk1/textctrl.h
@@
-1,25
+1,21
@@
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
-// Name: wx/gtk/textctrl.h
+// Name: wx/gtk
1
/textctrl.h
// Purpose:
// Author: Robert Roebling
// Created: 01/02/97
// Id: $Id$
// Purpose:
// Author: Robert Roebling
// Created: 01/02/97
// Id: $Id$
-// Copyright: (c) 1998 Robert Roebling
, Julian Smart and Markus Holzem
+// Copyright: (c) 1998 Robert Roebling
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
#ifndef __GTKTEXTCTRLH__
#define __GTKTEXTCTRLH__
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
#ifndef __GTKTEXTCTRLH__
#define __GTKTEXTCTRLH__
-#if defined(__GNUG__) && !defined(__APPLE__)
- #pragma interface "textctrl.h"
-#endif
-
//-----------------------------------------------------------------------------
// wxTextCtrl
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// wxTextCtrl
//-----------------------------------------------------------------------------
-class wxTextCtrl: public wxTextCtrlBase
+class
WXDLLIMPEXP_CORE
wxTextCtrl: public wxTextCtrlBase
{
public:
wxTextCtrl() { Init(); }
{
public:
wxTextCtrl() { Init(); }
@@
-32,6
+28,8
@@
public:
const wxValidator& validator = wxDefaultValidator,
const wxString &name = wxTextCtrlNameStr);
const wxValidator& validator = wxDefaultValidator,
const wxString &name = wxTextCtrlNameStr);
+ ~wxTextCtrl();
+
bool Create(wxWindow *parent,
wxWindowID id,
const wxString &value = wxEmptyString,
bool Create(wxWindow *parent,
wxWindowID id,
const wxString &value = wxEmptyString,
@@
-65,7
+63,8
@@
public:
virtual void Replace(long from, long to, const wxString& value);
virtual void Remove(long from, long to);
virtual void Replace(long from, long to, const wxString& value);
virtual void Remove(long from, long to);
- // clears the dirty flag
+ // sets/clears the dirty flag
+ virtual void MarkDirty();
virtual void DiscardEdits();
virtual void SetMaxLength(unsigned long len);
virtual void DiscardEdits();
virtual void SetMaxLength(unsigned long len);
@@
-103,12
+102,12
@@
public:
virtual void SetInsertionPoint(long pos);
virtual void SetInsertionPointEnd();
virtual long GetInsertionPoint() const;
virtual void SetInsertionPoint(long pos);
virtual void SetInsertionPointEnd();
virtual long GetInsertionPoint() const;
- virtual
long
GetLastPosition() const;
+ virtual
wxTextPos
GetLastPosition() const;
virtual void SetSelection(long from, long to);
virtual void SetEditable(bool editable);
virtual void SetSelection(long from, long to);
virtual void SetEditable(bool editable);
- virtual bool Enable( bool enable =
TRUE
);
+ virtual bool Enable( bool enable =
true
);
// Implementation from now on
void OnDropFiles( wxDropFilesEvent &event );
// Implementation from now on
void OnDropFiles( wxDropFilesEvent &event );
@@
-132,12
+131,14
@@
public:
GtkWidget* GetConnectWidget();
bool IsOwnGtkWindow( GdkWindow *window );
GtkWidget* GetConnectWidget();
bool IsOwnGtkWindow( GdkWindow *window );
- void
ApplyWidgetStyle(
);
+ void
DoApplyWidgetStyle(GtkRcStyle *style
);
void CalculateScrollbar();
void OnInternalIdle();
void CalculateScrollbar();
void OnInternalIdle();
+
+ void SetUpdateFont(bool update) { m_updateFont = update; }
void UpdateFontIfNeeded();
void UpdateFontIfNeeded();
- void SetModified() { m_modified =
TRUE
; }
+ void SetModified() { m_modified =
true
; }
// GTK+ textctrl is so dumb that you need to freeze/thaw it manually to
// avoid horrible flicker/scrolling back and forth
// GTK+ textctrl is so dumb that you need to freeze/thaw it manually to
// avoid horrible flicker/scrolling back and forth
@@
-161,6
+162,9
@@
public:
// should we ignore the changed signal? always resets the flag
bool IgnoreTextUpdate();
// should we ignore the changed signal? always resets the flag
bool IgnoreTextUpdate();
+ static wxVisualAttributes
+ GetClassDefaultAttributes(wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL);
+
protected:
virtual wxSize DoGetBestSize() const;
protected:
virtual wxSize DoGetBestSize() const;
@@
-174,6
+178,10
@@
protected:
// scroll position changed
bool DoScroll(GtkAdjustment *adj, int diff);
// scroll position changed
bool DoScroll(GtkAdjustment *adj, int diff);
+ // Widgets that use the style->base colour for the BG colour should
+ // override this and return true.
+ virtual bool UseGTKStyleBase() const { return true; }
+
private:
// change the font for everything in this control
void ChangeFontGlobally();
private:
// change the font for everything in this control
void ChangeFontGlobally();
@@
-187,7
+195,7
@@
private:
bool m_ignoreNextUpdate:1;
DECLARE_EVENT_TABLE()
bool m_ignoreNextUpdate:1;
DECLARE_EVENT_TABLE()
- DECLARE_DYNAMIC_CLASS(wxTextCtrl)
;
+ DECLARE_DYNAMIC_CLASS(wxTextCtrl)
};
#endif // __GTKTEXTCTRLH__
};
#endif // __GTKTEXTCTRLH__