void Append(const wxString& item);
void Clear();
+ void Delete(int n);
int FindString(const wxString& string);
int GetColumns();
int GetSelection();
wxString GetString(const int n);
wxString GetStringSelection();
- int Number();
+ int GetCount();
void SetColumns(const int n = 1);
void SetSelection(const int n);
void SetStringSelection(const wxString& string);
+ void SetString(int n, const wxString& s);
+
+ %pragma(python) addtoclass = "
+ Number = GetCount
+ Select = SetSelection
+ "
+
};
//----------------------------------------------------------------------
wxString GetString(int n);
wxString GetStringSelection();
wxString GetValue();
- int Number();
void Paste();
void Replace(long from, long to, const wxString& text);
void Remove(long from, long to);
void SetSelection(int n);
%name(SetMark)void SetSelection(long from, long to);
void SetValue(const wxString& text);
+ void SetEditable(bool editable);
};
//----------------------------------------------------------------------
wxString GetString(int n);
wxString GetStringSelection();
- int Number();
+ int GetCount();
+ %pragma(python) addtoclass = "Number = GetCount"
+ bool IsSelected(const int n);
bool Selected(const int n);
void Set(int LCOUNT, wxString* choices);
// TODO: void SetClientData(const int n, char* data);
//----------------------------------------------------------------------
+
+class wxTextAttr
+{
+public:
+ // ctors
+ wxTextAttr(const wxColour& colText = wxNullColour,
+ const wxColour& colBack = wxNullColour,
+ const wxFont& font = wxNullFont);
+ ~wxTextAttr();
+
+ // setters
+ void SetTextColour(const wxColour& colText);
+ void SetBackgroundColour(const wxColour& colBack);
+ void SetFont(const wxFont& font);
+
+ // accessors
+ bool HasTextColour() const;
+ bool HasBackgroundColour() const;
+ bool HasFont() const;
+
+ const wxColour& GetTextColour() const;
+ const wxColour& GetBackgroundColour() const;
+ const wxFont& GetFont() const;
+};
+
+
+
class wxTextCtrl : public wxControl {
public:
wxTextCtrl(wxWindow* parent, wxWindowID id, char* value = "",
void Undo();
void Redo();
+ bool SetStyle(long start, long end, const wxTextAttr& style);
+ bool SetDefaultStyle(const wxTextAttr& style);
+ const wxTextAttr& GetDefaultStyle() const;
+
%addmethods {
void write(const wxString& text) {
- self->AppendText(text + '\n');
+ self->AppendText(text);
}
}
};
%name(EnableItem)void Enable(int n, bool enable);
int FindString(const wxString& string);
-//*** wxString GetLabel();
-//*** void SetLabel(const wxString& label);
+ wxString GetString(int n);
+
+#ifdef __WXMSW__
+ void SetString(int n, const wxString& label);
+ %pragma(python) addtoclass = "
+ GetItemLabel = GetString
+ SetItemLabel = SetString
+ "
+ int GetColumnCount();
+ int GetRowCount();
+#else
+ %name(GetItemLabel)wxString GetLabel( int item );
+ %name(SetItemLabel)void SetLabel( int item, const wxString& label );
+#endif
- %name(GetItemLabel)wxString GetLabel(int n);
int GetSelection();
- wxString GetString(int n);
wxString GetStringSelection();
- int Number();
- %name(SetItemLabel)void SetLabel(int n, const wxString& label);
+ int GetCount();
+ %pragma(python) addtoclass = "Number = GetCount"
+
void SetSelection(int n);
void SetStringSelection(const wxString& string);
void Show(bool show);