wxPython Merge #2 of 2.4 branch --> HEAD (branch tag: wxPy_2_4_merge_2)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@21593 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2003-07-02 23:13:10 +00:00
parent e234d4c9b7
commit 1fded56b37
535 changed files with 48899 additions and 20067 deletions

View File

@@ -5,8 +5,10 @@ MANIFEST
_build_dmg
_build_rpm
build
build-dbg
build-gtk
build-gtk2
build-gtk2-dbg.unicode
build-gtk2.unicode
build-pkg
build-pkg-debug

View File

@@ -119,6 +119,7 @@ C. Change to the %WXWIN%\include\wx\msw directory and copy setup0.h to
wxUSE_TREELAYOUT 0
wxUSE_MS_HTML_HELP 0
wxUSE_POSTSCRIPT 1
wxUSE_DYNLIB_CLASS 1
** NEW **

View File

@@ -2,10 +2,85 @@ CHANGES.txt for wxPython
----------------------------------------------------------------------
?????
2.4.1.x
-------
Added wxScrolledPanel from Wil Sadkin
Use wxSTC in the demo for displaying the soucre code of the samples.
2.4.1.2
-------
Added wxScrolledPanel from Will Sadkin
Added SetShape method to top level windows (e.g. wxFrame.)
Changed wxSWIG to not generate Python code using apply, (since it will
be deprecated in the future) wxSWIG will use spam(*args, **kw) syntax
instead. Also changed the generated __repr__ methods to be a bit more
informative.
Made the version number information more robust and uh, informative.
Also added asserts to check that the major.minor versions of wxPython
and wxWindows match.
Added the new wx "renamer" package that will dynamically import from
the wxPython package and rename wxFooBar --> FooBar. That means that
people can do imports without "import *" and can use names like
wx.Frame instead of wx.wxFrame. This is phase 1 of a full transition
to the new namespace.
Updated Scintilla to 1.52. I also changed it to use wxListCtrl
instead of wxListBox for the AutoComplete window, added the ability to
use custom bitmaps in the margin and in the AutoComplete windows, and
worked out how to do proper clipping of child windows on wxGTK.
Patrick O'Brien's PyCrust package has been renamed to Py and now
includes several new tools. As part of the change the location of the
pacakge has changed as well, it is now accessible as "from wxPython
import py" (or "from wx import py" using the new namespace.) There
are still some transition modules in the wxPython.lib.PyCrust package
that will issue a warning and then import what is needed from the new
package. These will be removed in a future release.
Added __nonzero__ method to wxTreeItemId, wxBitmap, wxImage, wxFont,
and most other classes that have an Ok or IsOK method. This allows
code like "if obj: ..." to be the same as "if obj.IsOk(): ..."
Toolbars on wxMac can now have controls on them.
Added wxPython.lib.analogclock module based on samples that were
passed back and forth on wxPython-users a while back.
Added masked edit controls (wxPython.lib.maskededit) by Jeff Childers
and Will Sadkin. Updated wxTimeCtrl to use MaskedEdit.
When the __class__ of a dead object is replaced with _wxPyDeadObject
the __del__ of the original class is now called first.
Added wxTreeListCtrl. (Looks like a wxTreeCtrl embedded in a
wxListCtrl, but actually is just giving multiple columns to a
wxTreeCtrl.)
Added wxFutureCall, a subclass of wxTimer that makes it easy to delay
a call to any Python callable object.
Added wxPy versions of wxPrintPreview, wxPreviewFrame, and
wxPreviewControlBar so they can be derived from in Python and be able
to override the C++ virtual methods.
Simplified how the wxSizer methods are wrapped, changed the name of
the "option" parameter to "proportion" to match the docs ("option" is
still accepted for compatibility, but this will go away in a future
release,) SetItemMinSize can now take a wxSize (or 2-tuple) parameter,
and Spacers can be specified with a wxSize (or 2-tuple) parameter
Added wxCursorFromBits.
@@ -411,6 +486,7 @@ Added wxTimeCtrl from Will Sadkin.
2.3.2.1
-------
Changed (again) how the Python global interpreter lock is handled as

View File

@@ -1,3 +1,5 @@
# This is way out of date. (It's not activly used anymore...)
include *.txt
include my_distutils.py
## include my_install_data.py

View File

@@ -47,19 +47,19 @@ class wxDllWidgetPtr(wxPanelPtr):
self.this = this
self.thisown = 0
def Ok(self, *_args, **_kwargs):
val = apply(dllwidget_c.wxDllWidget_Ok,(self,) + _args, _kwargs)
val = dllwidget_c.wxDllWidget_Ok(self, *_args, **_kwargs)
return val
def SendCommand(self, *_args, **_kwargs):
val = apply(dllwidget_c.wxDllWidget_SendCommand,(self,) + _args, _kwargs)
val = dllwidget_c.wxDllWidget_SendCommand(self, *_args, **_kwargs)
return val
def GetWidgetWindow(self, *_args, **_kwargs):
val = apply(dllwidget_c.wxDllWidget_GetWidgetWindow,(self,) + _args, _kwargs)
val = dllwidget_c.wxDllWidget_GetWidgetWindow(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxDllWidget instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxDllWidget instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxDllWidget(wxDllWidgetPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(dllwidget_c.new_wxDllWidget,_args,_kwargs)
self.this = dllwidget_c.new_wxDllWidget(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)

File diff suppressed because it is too large Load Diff

View File

@@ -19,7 +19,12 @@
#include <wx/gizmos/editlbox.h>
#include <wx/gizmos/splittree.h>
#include <wx/gizmos/ledctrl.h>
#include <wx/listctrl.h>
#include <wx/treectrl.h>
#include <wx/imaglist.h>
#include "treelistctrl.h"
#include "pytree.h"
%}
//---------------------------------------------------------------------------
@@ -32,6 +37,8 @@
%extern _defs.i
%extern events.i
%extern controls.i
%extern controls2.i
%extern gdi.i
//----------------------------------------------------------------------
@@ -40,6 +47,8 @@
// Put some wx default wxChar* values into wxStrings.
static const wxString wxPyDynamicSashNameStr(wxT("dynamicSashWindow"));
static const wxString wxPyEditableListBoxNameStr(wxT("editableListBox"));
static const wxString wxPyTreeListCtrlNameStr(wxT("treelistctrl"));
static const wxString wxPyEmptyString(wxT(""));
%}
///----------------------------------------------------------------------
@@ -390,6 +399,521 @@ public:
};
//----------------------------------------------------------------------------
// wxTreeListCtrl - the multicolumn tree control
//----------------------------------------------------------------------------
enum wxTreeListColumnAlign {
wxTL_ALIGN_LEFT,
wxTL_ALIGN_RIGHT,
wxTL_ALIGN_CENTER
};
enum {
wxTREE_HITTEST_ONITEMCOLUMN
};
class wxTreeListColumnInfo: public wxObject {
public:
wxTreeListColumnInfo(const wxString& text = wxPyEmptyString,
int image = -1,
size_t width = 100,
wxTreeListColumnAlign alignment = wxTL_ALIGN_LEFT);
wxTreeListColumnAlign GetAlignment() const;
wxString GetText() const;
int GetImage() const;
int GetSelectedImage() const;
size_t GetWidth() const;
void SetAlignment(wxTreeListColumnAlign alignment);
void SetText(const wxString& text);
void SetImage(int image);
void SetSelectedImage(int image);
void SetWidth(size_t with);
};
%{ // C++ version of Python aware control
class wxPyTreeListCtrl : public wxTreeListCtrl {
DECLARE_ABSTRACT_CLASS(wxPyTreeListCtrl);
public:
wxPyTreeListCtrl() : wxTreeListCtrl() {}
wxPyTreeListCtrl(wxWindow *parent, wxWindowID id,
const wxPoint& pos,
const wxSize& size,
long style,
const wxValidator &validator,
const wxString& name) :
wxTreeListCtrl(parent, id, pos, size, style, validator, name) {}
int OnCompareItems(const wxTreeItemId& item1,
const wxTreeItemId& item2) {
int rval = 0;
bool found;
wxPyBeginBlockThreads();
if ((found = wxPyCBH_findCallback(m_myInst, "OnCompareItems"))) {
PyObject *o1 = wxPyConstructObject((void*)&item1, wxT("wxTreeItemId"), 0);
PyObject *o2 = wxPyConstructObject((void*)&item2, wxT("wxTreeItemId"), 0);
rval = wxPyCBH_callCallback(m_myInst, Py_BuildValue("(OO)",o1,o2));
Py_DECREF(o1);
Py_DECREF(o2);
}
wxPyEndBlockThreads();
if (! found)
rval = wxTreeListCtrl::OnCompareItems(item1, item2);
return rval;
}
PYPRIVATE;
};
IMPLEMENT_ABSTRACT_CLASS(wxPyTreeListCtrl, wxTreeListCtrl)
%}
// These are for the GetFirstChild/GetNextChild methods below
%{
static const long longzero = 0;
%}
%typemap(python, in) long& INOUT = long* INOUT;
%typemap(python, argout) long& INOUT = long* INOUT;
%name(wxTreeListCtrl) class wxPyTreeListCtrl : public wxControl
{
public:
wxPyTreeListCtrl(wxWindow *parent, wxWindowID id = -1,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxTR_DEFAULT_STYLE,
const wxValidator &validator = wxDefaultValidator,
const wxString& name = wxPyTreeListCtrlNameStr );
%name(wxPreTreeListCtrl)wxPyTreeListCtrl();
bool Create(wxWindow *parent, wxWindowID id = -1,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxTR_DEFAULT_STYLE,
const wxValidator &validator = wxDefaultValidator,
const wxString& name = wxPyTreeListCtrlNameStr );
void _setCallbackInfo(PyObject* self, PyObject* _class);
%pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxTreeListCtrl)"
%pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
%pragma(python) addtomethod = "wxPreTreeListCtrl:val._setOORInfo(val)"
// get the total number of items in the control
size_t GetCount() const;
// indent is the number of pixels the children are indented relative to
// the parents position. SetIndent() also redraws the control
// immediately.
unsigned int GetIndent() const;
void SetIndent(unsigned int indent);
// spacing is the number of pixels between the start and the Text
unsigned int GetSpacing() const;
void SetSpacing(unsigned int spacing);
// line spacing is the space above and below the text on each line
unsigned int GetLineSpacing() const;
void SetLineSpacing(unsigned int spacing);
// image list: these functions allow to associate an image list with
// the control and retrieve it. Note that when assigned with
// SetImageList, the control does _not_ delete
// the associated image list when it's deleted in order to allow image
// lists to be shared between different controls. If you use
// AssignImageList, the control _does_ delete the image list.
//
// The normal image list is for the icons which correspond to the
// normal tree item state (whether it is selected or not).
// Additionally, the application might choose to show a state icon
// which corresponds to an app-defined item state (for example,
// checked/unchecked) which are taken from the state image list.
wxImageList *GetImageList() const;
wxImageList *GetStateImageList() const;
wxImageList *GetButtonsImageList() const;
void SetImageList(wxImageList *imageList);
void SetStateImageList(wxImageList *imageList);
void SetButtonsImageList(wxImageList *imageList);
void AssignImageList(wxImageList *imageList);
void AssignStateImageList(wxImageList *imageList);
void AssignButtonsImageList(wxImageList *imageList);
// adds a column
void AddColumn(const wxString& text);
%name(AddColumnInfo) void AddColumn(const wxTreeListColumnInfo& col);
// inserts a column before the given one
void InsertColumn(size_t before, const wxString& text);
%name(InsertColumnInfo) void InsertColumn(size_t before, const wxTreeListColumnInfo& col);
// deletes the given column - does not delete the corresponding column
// of each item
void RemoveColumn(size_t column);
// returns the number of columns in the ctrl
size_t GetColumnCount() const;
void SetColumnWidth(size_t column, size_t width);
int GetColumnWidth(size_t column) const;
// tells which column is the "main" one, i.e. the "threaded" one
void SetMainColumn(size_t column);
size_t GetMainColumn() const;
void SetColumnText(size_t column, const wxString& text);
wxString GetColumnText(size_t column) const;
void SetColumn(size_t column, const wxTreeListColumnInfo& info);
wxTreeListColumnInfo& GetColumn(size_t column);
// other column-related methods
void SetColumnAlignment(size_t column, wxTreeListColumnAlign align);
wxTreeListColumnAlign GetColumnAlignment(size_t column) const;
void SetColumnImage(size_t column, int image);
int GetColumnImage(size_t column) const;
%addmethods {
// retrieves item's label of the given column (main column by default)
wxString GetItemText(const wxTreeItemId& item, int column = -1) {
if (column < 0) column = self->GetMainColumn();
return self->GetItemText(item, column);
}
// get one of the images associated with the item (normal by default)
int GetItemImage(const wxTreeItemId& item, int column = -1,
wxTreeItemIcon which = wxTreeItemIcon_Normal) {
if (column < 0) column = self->GetMainColumn();
return self->GetItemImage(item, column, which);
}
// set item's label (main column by default)
void SetItemText(const wxTreeItemId& item, const wxString& text, int column = -1) {
if (column < 0) column = self->GetMainColumn();
self->SetItemText(item, column, text);
}
// set one of the images associated with the item (normal by default)
// the which parameter is ignored for all columns but the main one
void SetItemImage(const wxTreeItemId& item, int image, int column = -1,
wxTreeItemIcon which = wxTreeItemIcon_Normal) {
if (column < 0) column = self->GetMainColumn();
self->SetItemImage(item, column, image, which);
}
// [Get|Set]ItemData substitutes. Automatically create wxPyTreeItemData
// if needed.
wxPyTreeItemData* GetItemData(const wxTreeItemId& item) {
wxPyTreeItemData* data = (wxPyTreeItemData*)self->GetItemData(item);
if (data == NULL) {
data = new wxPyTreeItemData();
data->SetId(item); // set the id
self->SetItemData(item, data);
}
return data;
}
void SetItemData(const wxTreeItemId& item, wxPyTreeItemData* data) {
data->SetId(item); // set the id
self->SetItemData(item, data);
}
// [Get|Set]PyData are short-cuts. Also made somewhat crash-proof by
// automatically creating data classes.
PyObject* GetPyData(const wxTreeItemId& item) {
wxPyTreeItemData* data = (wxPyTreeItemData*)self->GetItemData(item);
if (data == NULL) {
data = new wxPyTreeItemData();
data->SetId(item); // set the id
self->SetItemData(item, data);
}
return data->GetData();
}
void SetPyData(const wxTreeItemId& item, PyObject* obj) {
wxPyTreeItemData* data = (wxPyTreeItemData*)self->GetItemData(item);
if (data == NULL) {
data = new wxPyTreeItemData(obj);
data->SetId(item); // set the id
self->SetItemData(item, data);
} else
data->SetData(obj);
}
}
// force appearance of [+] button near the item. This is useful to
// allow the user to expand the items which don't have any children now
// - but instead add them only when needed, thus minimizing memory
// usage and loading time.
void SetItemHasChildren(const wxTreeItemId& item, bool has = TRUE);
// the item will be shown in bold
void SetItemBold(const wxTreeItemId& item, bool bold = TRUE);
// set the item's text colour
void SetItemTextColour(const wxTreeItemId& item, const wxColour& col);
// set the item's background colour
void SetItemBackgroundColour(const wxTreeItemId& item,
const wxColour& col);
// set the item's font (should be of the same height for all items)
void SetItemFont(const wxTreeItemId& item, const wxFont& font);
bool GetItemBold(const wxTreeItemId& item) const;
wxColour GetItemTextColour(const wxTreeItemId& item) const;
wxColour GetItemBackgroundColour(const wxTreeItemId& item) const;
wxFont GetItemFont(const wxTreeItemId& item) const;
// is the item visible (it might be outside the view or not expanded)?
bool IsVisible(const wxTreeItemId& item) const;
// does the item has any children?
bool ItemHasChildren(const wxTreeItemId& item) const;
// is the item expanded (only makes sense if HasChildren())?
bool IsExpanded(const wxTreeItemId& item) const;
// is this item currently selected (the same as has focus)?
bool IsSelected(const wxTreeItemId& item) const;
// is item text in bold font?
bool IsBold(const wxTreeItemId& item) const;
// if 'recursively' is FALSE, only immediate children count, otherwise
// the returned number is the number of all items in this branch
size_t GetChildrenCount(const wxTreeItemId& item, bool recursively = TRUE);
// wxTreeItemId.IsOk() will return FALSE if there is no such item
// get the root tree item
wxTreeItemId GetRootItem() const;
// get the item currently selected (may return NULL if no selection)
wxTreeItemId GetSelection() const;
// get the items currently selected, return the number of such item
//size_t GetSelections(wxArrayTreeItemIds&) const;
%addmethods {
PyObject* GetSelections() {
wxPyBeginBlockThreads();
PyObject* rval = PyList_New(0);
wxArrayTreeItemIds array;
size_t num, x;
num = self->GetSelections(array);
for (x=0; x < num; x++) {
wxTreeItemId *tii = new wxTreeItemId(array.Item(x));
PyObject* item = wxPyConstructObject((void*)tii, wxT("wxTreeItemId"), TRUE);
PyList_Append(rval, item);
}
wxPyEndBlockThreads();
return rval;
}
}
// get the parent of this item (may return NULL if root)
%name(GetItemParent)wxTreeItemId GetParent(const wxTreeItemId& item) const;
// for this enumeration function you must pass in a "cookie" parameter
// which is opaque for the application but is necessary for the library
// to make these functions reentrant (i.e. allow more than one
// enumeration on one and the same object simultaneously). Of course,
// the "cookie" passed to GetFirstChild() and GetNextChild() should be
// the same!
// get the first child of this item
wxTreeItemId GetFirstChild(const wxTreeItemId& item, long& INOUT = longzero) const;
// get the next child
wxTreeItemId GetNextChild(const wxTreeItemId& item, long& INOUT) const;
// get the last child of this item - this method doesn't use cookies
wxTreeItemId GetLastChild(const wxTreeItemId& item) const;
// get the next sibling of this item
wxTreeItemId GetNextSibling(const wxTreeItemId& item) const;
// get the previous sibling
wxTreeItemId GetPrevSibling(const wxTreeItemId& item) const;
// get first visible item
wxTreeItemId GetFirstVisibleItem() const;
// get the next visible item: item must be visible itself!
// see IsVisible() and wxTreeCtrl::GetFirstVisibleItem()
wxTreeItemId GetNextVisible(const wxTreeItemId& item) const;
// get the previous visible item: item must be visible itself!
wxTreeItemId GetPrevVisible(const wxTreeItemId& item) const;
// Only for internal use right now, but should probably be public
wxTreeItemId GetNext(const wxTreeItemId& item) const;
// add the root node to the tree
wxTreeItemId AddRoot(const wxString& text,
int image = -1, int selectedImage = -1,
wxPyTreeItemData *data = NULL);
// insert a new item in as the first child of the parent
wxTreeItemId PrependItem(const wxTreeItemId& parent,
const wxString& text,
int image = -1, int selectedImage = -1,
wxPyTreeItemData *data = NULL);
// insert a new item after a given one
wxTreeItemId InsertItem(const wxTreeItemId& parent,
const wxTreeItemId& idPrevious,
const wxString& text,
int image = -1, int selectedImage = -1,
wxPyTreeItemData *data = NULL);
// insert a new item before the one with the given index
%name(InsertItemBefore)
wxTreeItemId InsertItem(const wxTreeItemId& parent,
size_t index,
const wxString& text,
int image = -1, int selectedImage = -1,
wxPyTreeItemData *data = NULL);
// insert a new item in as the last child of the parent
wxTreeItemId AppendItem(const wxTreeItemId& parent,
const wxString& text,
int image = -1, int selectedImage = -1,
wxPyTreeItemData *data = NULL);
// delete this item and associated data if any
void Delete(const wxTreeItemId& item);
// delete all children (but don't delete the item itself)
// NB: this won't send wxEVT_COMMAND_TREE_ITEM_DELETED events
void DeleteChildren(const wxTreeItemId& item);
// delete all items from the tree
// NB: this won't send wxEVT_COMMAND_TREE_ITEM_DELETED events
void DeleteAllItems();
// expand this item
void Expand(const wxTreeItemId& item);
// expand this item and all subitems recursively
void ExpandAll(const wxTreeItemId& item);
// collapse the item without removing its children
void Collapse(const wxTreeItemId& item);
// collapse the item and remove all children
void CollapseAndReset(const wxTreeItemId& item);
// toggles the current state
void Toggle(const wxTreeItemId& item);
// remove the selection from currently selected item (if any)
void Unselect();
void UnselectAll();
// select this item
void SelectItem(const wxTreeItemId& item, bool unselect_others=TRUE,
bool extended_select=FALSE);
// make sure this item is visible (expanding the parent item and/or
// scrolling to this item if necessary)
void EnsureVisible(const wxTreeItemId& item);
// scroll to this item (but don't expand its parent)
void ScrollTo(const wxTreeItemId& item);
// Returns wxTreeItemId, flags, and column
wxTreeItemId HitTest(const wxPoint& point, int& OUTPUT, int& OUTPUT);
%addmethods {
// get the bounding rectangle of the item (or of its label only)
PyObject* GetBoundingRect(const wxTreeItemId& item, bool textOnly = FALSE) {
wxRect rect;
if (self->GetBoundingRect(item, rect, textOnly)) {
wxPyBeginBlockThreads();
wxRect* r = new wxRect(rect);
PyObject* val = wxPyConstructObject((void*)r, wxT("wxRect"), 1);
wxPyEndBlockThreads();
return val;
}
else {
Py_INCREF(Py_None);
return Py_None;
}
}
}
// 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.
void EditLabel( const wxTreeItemId& item );
void Edit( const wxTreeItemId& item );
// sort the children of this item using OnCompareItems
void SortChildren(const wxTreeItemId& item);
// get the selected item image
int GetItemSelectedImage(const wxTreeItemId& item) const;
// set the selected item image
void SetItemSelectedImage(const wxTreeItemId& item, int image);
wxWindow* GetHeaderWindow() const;
wxWindow* GetMainWindow() const;
%pragma(python) addtoclass = "
# Redefine some methods that SWIG gets a bit confused on...
def GetFirstChild(self, *_args, **_kwargs):
val1,val2 = gizmosc.wxTreeListCtrl_GetFirstChild(self, *_args, **_kwargs)
val1 = wxTreeItemIdPtr(val1)
val1.thisown = 1
return (val1,val2)
def GetNextChild(self, *_args, **_kwargs):
val1,val2 = gizmosc.wxTreeListCtrl_GetNextChild(self, *_args, **_kwargs)
val1 = wxTreeItemIdPtr(val1)
val1.thisown = 1
return (val1,val2)
def HitTest(self, *_args, **_kwargs):
val1, val2, val3 = gizmosc.wxTreeListCtrl_HitTest(self, *_args, **_kwargs)
val1 = wxTreeItemIdPtr(val1)
val1.thisown = 1
return (val1, val2, val3)
"
};
//----------------------------------------------------------------------
//----------------------------------------------------------------------
@@ -399,6 +923,7 @@ public:
wxClassInfo::InitializeClasses();
wxPyPtrTypeMap_Add("wxTreeCompanionWindow", "wxPyTreeCompanionWindow");
wxPyPtrTypeMap_Add("wxTreeListCtrl", "wxPyTreeListCtrl");
%}

View File

@@ -54,10 +54,10 @@ class wxDynamicSashSplitEventPtr(wxCommandEventPtr):
self.this = this
self.thisown = 0
def __repr__(self):
return "<C wxDynamicSashSplitEvent instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxDynamicSashSplitEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxDynamicSashSplitEvent(wxDynamicSashSplitEventPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxDynamicSashSplitEvent,_args,_kwargs)
self.this = gizmosc.new_wxDynamicSashSplitEvent(*_args,**_kwargs)
self.thisown = 1
@@ -68,10 +68,10 @@ class wxDynamicSashUnifyEventPtr(wxCommandEventPtr):
self.this = this
self.thisown = 0
def __repr__(self):
return "<C wxDynamicSashUnifyEvent instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxDynamicSashUnifyEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxDynamicSashUnifyEvent(wxDynamicSashUnifyEventPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxDynamicSashUnifyEvent,_args,_kwargs)
self.this = gizmosc.new_wxDynamicSashUnifyEvent(*_args,**_kwargs)
self.thisown = 1
@@ -82,28 +82,28 @@ class wxDynamicSashWindowPtr(wxWindowPtr):
self.this = this
self.thisown = 0
def Create(self, *_args, **_kwargs):
val = apply(gizmosc.wxDynamicSashWindow_Create,(self,) + _args, _kwargs)
val = gizmosc.wxDynamicSashWindow_Create(self, *_args, **_kwargs)
return val
def GetHScrollBar(self, *_args, **_kwargs):
val = apply(gizmosc.wxDynamicSashWindow_GetHScrollBar,(self,) + _args, _kwargs)
val = gizmosc.wxDynamicSashWindow_GetHScrollBar(self, *_args, **_kwargs)
if val: val = wxScrollBarPtr(val)
return val
def GetVScrollBar(self, *_args, **_kwargs):
val = apply(gizmosc.wxDynamicSashWindow_GetVScrollBar,(self,) + _args, _kwargs)
val = gizmosc.wxDynamicSashWindow_GetVScrollBar(self, *_args, **_kwargs)
if val: val = wxScrollBarPtr(val)
return val
def __repr__(self):
return "<C wxDynamicSashWindow instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxDynamicSashWindow instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxDynamicSashWindow(wxDynamicSashWindowPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxDynamicSashWindow,_args,_kwargs)
self.this = gizmosc.new_wxDynamicSashWindow(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
def wxPreDynamicSashWindow(*_args,**_kwargs):
val = wxDynamicSashWindowPtr(apply(gizmosc.new_wxPreDynamicSashWindow,_args,_kwargs))
val = wxDynamicSashWindowPtr(gizmosc.new_wxPreDynamicSashWindow(*_args,**_kwargs))
val.thisown = 1
val._setOORInfo(val)
return val
@@ -114,34 +114,34 @@ class wxEditableListBoxPtr(wxPanelPtr):
self.this = this
self.thisown = 0
def SetStrings(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_SetStrings,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_SetStrings(self, *_args, **_kwargs)
return val
def GetStrings(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetStrings,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetStrings(self, *_args, **_kwargs)
return val
def GetListCtrl(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetListCtrl,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetListCtrl(self, *_args, **_kwargs)
return val
def GetDelButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetDelButton,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetDelButton(self, *_args, **_kwargs)
return val
def GetNewButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetNewButton,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetNewButton(self, *_args, **_kwargs)
return val
def GetUpButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetUpButton,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetUpButton(self, *_args, **_kwargs)
return val
def GetDownButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetDownButton,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetDownButton(self, *_args, **_kwargs)
return val
def GetEditButton(self, *_args, **_kwargs):
val = apply(gizmosc.wxEditableListBox_GetEditButton,(self,) + _args, _kwargs)
val = gizmosc.wxEditableListBox_GetEditButton(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxEditableListBox instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxEditableListBox instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxEditableListBox(wxEditableListBoxPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxEditableListBox,_args,_kwargs)
self.this = gizmosc.new_wxEditableListBox(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
@@ -153,29 +153,29 @@ class wxRemotelyScrolledTreeCtrlPtr(wxTreeCtrlPtr):
self.this = this
self.thisown = 0
def HideVScrollbar(self, *_args, **_kwargs):
val = apply(gizmosc.wxRemotelyScrolledTreeCtrl_HideVScrollbar,(self,) + _args, _kwargs)
val = gizmosc.wxRemotelyScrolledTreeCtrl_HideVScrollbar(self, *_args, **_kwargs)
return val
def AdjustRemoteScrollbars(self, *_args, **_kwargs):
val = apply(gizmosc.wxRemotelyScrolledTreeCtrl_AdjustRemoteScrollbars,(self,) + _args, _kwargs)
val = gizmosc.wxRemotelyScrolledTreeCtrl_AdjustRemoteScrollbars(self, *_args, **_kwargs)
return val
def GetScrolledWindow(self, *_args, **_kwargs):
val = apply(gizmosc.wxRemotelyScrolledTreeCtrl_GetScrolledWindow,(self,) + _args, _kwargs)
val = gizmosc.wxRemotelyScrolledTreeCtrl_GetScrolledWindow(self, *_args, **_kwargs)
if val: val = wxScrolledWindowPtr(val)
return val
def ScrollToLine(self, *_args, **_kwargs):
val = apply(gizmosc.wxRemotelyScrolledTreeCtrl_ScrollToLine,(self,) + _args, _kwargs)
val = gizmosc.wxRemotelyScrolledTreeCtrl_ScrollToLine(self, *_args, **_kwargs)
return val
def SetCompanionWindow(self, *_args, **_kwargs):
val = apply(gizmosc.wxRemotelyScrolledTreeCtrl_SetCompanionWindow,(self,) + _args, _kwargs)
val = gizmosc.wxRemotelyScrolledTreeCtrl_SetCompanionWindow(self, *_args, **_kwargs)
return val
def GetCompanionWindow(self, *_args, **_kwargs):
val = apply(gizmosc.wxRemotelyScrolledTreeCtrl_GetCompanionWindow,(self,) + _args, _kwargs)
val = gizmosc.wxRemotelyScrolledTreeCtrl_GetCompanionWindow(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxRemotelyScrolledTreeCtrl instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxRemotelyScrolledTreeCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxRemotelyScrolledTreeCtrl(wxRemotelyScrolledTreeCtrlPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxRemotelyScrolledTreeCtrl,_args,_kwargs)
self.this = gizmosc.new_wxRemotelyScrolledTreeCtrl(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
@@ -187,20 +187,20 @@ class wxTreeCompanionWindowPtr(wxWindowPtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(gizmosc.wxTreeCompanionWindow__setCallbackInfo,(self,) + _args, _kwargs)
val = gizmosc.wxTreeCompanionWindow__setCallbackInfo(self, *_args, **_kwargs)
return val
def GetTreeCtrl(self, *_args, **_kwargs):
val = apply(gizmosc.wxTreeCompanionWindow_GetTreeCtrl,(self,) + _args, _kwargs)
val = gizmosc.wxTreeCompanionWindow_GetTreeCtrl(self, *_args, **_kwargs)
if val: val = wxRemotelyScrolledTreeCtrlPtr(val)
return val
def SetTreeCtrl(self, *_args, **_kwargs):
val = apply(gizmosc.wxTreeCompanionWindow_SetTreeCtrl,(self,) + _args, _kwargs)
val = gizmosc.wxTreeCompanionWindow_SetTreeCtrl(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxTreeCompanionWindow instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxTreeCompanionWindow instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxTreeCompanionWindow(wxTreeCompanionWindowPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxTreeCompanionWindow,_args,_kwargs)
self.this = gizmosc.new_wxTreeCompanionWindow(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxTreeCompanionWindow)
self._setOORInfo(self)
@@ -213,10 +213,10 @@ class wxThinSplitterWindowPtr(wxSplitterWindowPtr):
self.this = this
self.thisown = 0
def __repr__(self):
return "<C wxThinSplitterWindow instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxThinSplitterWindow instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxThinSplitterWindow(wxThinSplitterWindowPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxThinSplitterWindow,_args,_kwargs)
self.this = gizmosc.new_wxThinSplitterWindow(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
@@ -228,10 +228,10 @@ class wxSplitterScrolledWindowPtr(wxScrolledWindowPtr):
self.this = this
self.thisown = 0
def __repr__(self):
return "<C wxSplitterScrolledWindow instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxSplitterScrolledWindow instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxSplitterScrolledWindow(wxSplitterScrolledWindowPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxSplitterScrolledWindow,_args,_kwargs)
self.this = gizmosc.new_wxSplitterScrolledWindow(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
@@ -243,38 +243,439 @@ class wxLEDNumberCtrlPtr(wxControlPtr):
self.this = this
self.thisown = 0
def Create(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_Create,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_Create(self, *_args, **_kwargs)
return val
def GetAlignment(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_GetAlignment,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_GetAlignment(self, *_args, **_kwargs)
return val
def GetDrawFaded(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_GetDrawFaded,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_GetDrawFaded(self, *_args, **_kwargs)
return val
def GetValue(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_GetValue,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_GetValue(self, *_args, **_kwargs)
return val
def SetAlignment(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_SetAlignment,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_SetAlignment(self, *_args, **_kwargs)
return val
def SetDrawFaded(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_SetDrawFaded,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_SetDrawFaded(self, *_args, **_kwargs)
return val
def SetValue(self, *_args, **_kwargs):
val = apply(gizmosc.wxLEDNumberCtrl_SetValue,(self,) + _args, _kwargs)
val = gizmosc.wxLEDNumberCtrl_SetValue(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxLEDNumberCtrl instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxLEDNumberCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxLEDNumberCtrl(wxLEDNumberCtrlPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(gizmosc.new_wxLEDNumberCtrl,_args,_kwargs)
self.this = gizmosc.new_wxLEDNumberCtrl(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
def wxPreLEDNumberCtrl(*_args,**_kwargs):
val = wxLEDNumberCtrlPtr(apply(gizmosc.new_wxPreLEDNumberCtrl,_args,_kwargs))
val = wxLEDNumberCtrlPtr(gizmosc.new_wxPreLEDNumberCtrl(*_args,**_kwargs))
val.thisown = 1
val._setOORInfo(val)
return val
class wxTreeListColumnInfoPtr(wxObjectPtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def GetAlignment(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_GetAlignment(self, *_args, **_kwargs)
return val
def GetText(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_GetText(self, *_args, **_kwargs)
return val
def GetImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_GetImage(self, *_args, **_kwargs)
return val
def GetSelectedImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_GetSelectedImage(self, *_args, **_kwargs)
return val
def GetWidth(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_GetWidth(self, *_args, **_kwargs)
return val
def SetAlignment(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_SetAlignment(self, *_args, **_kwargs)
return val
def SetText(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_SetText(self, *_args, **_kwargs)
return val
def SetImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_SetImage(self, *_args, **_kwargs)
return val
def SetSelectedImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_SetSelectedImage(self, *_args, **_kwargs)
return val
def SetWidth(self, *_args, **_kwargs):
val = gizmosc.wxTreeListColumnInfo_SetWidth(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<%s.%s instance; proxy of C++ wxTreeListColumnInfo instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxTreeListColumnInfo(wxTreeListColumnInfoPtr):
def __init__(self,*_args,**_kwargs):
self.this = gizmosc.new_wxTreeListColumnInfo(*_args,**_kwargs)
self.thisown = 1
class wxTreeListCtrlPtr(wxControlPtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def Create(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Create(self, *_args, **_kwargs)
return val
def _setCallbackInfo(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl__setCallbackInfo(self, *_args, **_kwargs)
return val
def GetCount(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetCount(self, *_args, **_kwargs)
return val
def GetIndent(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetIndent(self, *_args, **_kwargs)
return val
def SetIndent(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetIndent(self, *_args, **_kwargs)
return val
def GetSpacing(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetSpacing(self, *_args, **_kwargs)
return val
def SetSpacing(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetSpacing(self, *_args, **_kwargs)
return val
def GetLineSpacing(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetLineSpacing(self, *_args, **_kwargs)
return val
def SetLineSpacing(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetLineSpacing(self, *_args, **_kwargs)
return val
def GetImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetImageList(self, *_args, **_kwargs)
return val
def GetStateImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetStateImageList(self, *_args, **_kwargs)
return val
def GetButtonsImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetButtonsImageList(self, *_args, **_kwargs)
return val
def SetImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetImageList(self, *_args, **_kwargs)
return val
def SetStateImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetStateImageList(self, *_args, **_kwargs)
return val
def SetButtonsImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetButtonsImageList(self, *_args, **_kwargs)
return val
def AssignImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AssignImageList(self, *_args, **_kwargs)
return val
def AssignStateImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AssignStateImageList(self, *_args, **_kwargs)
return val
def AssignButtonsImageList(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AssignButtonsImageList(self, *_args, **_kwargs)
return val
def AddColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AddColumn(self, *_args, **_kwargs)
return val
def AddColumnInfo(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AddColumnInfo(self, *_args, **_kwargs)
return val
def InsertColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_InsertColumn(self, *_args, **_kwargs)
return val
def InsertColumnInfo(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_InsertColumnInfo(self, *_args, **_kwargs)
return val
def RemoveColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_RemoveColumn(self, *_args, **_kwargs)
return val
def GetColumnCount(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetColumnCount(self, *_args, **_kwargs)
return val
def SetColumnWidth(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetColumnWidth(self, *_args, **_kwargs)
return val
def GetColumnWidth(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetColumnWidth(self, *_args, **_kwargs)
return val
def SetMainColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetMainColumn(self, *_args, **_kwargs)
return val
def GetMainColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetMainColumn(self, *_args, **_kwargs)
return val
def SetColumnText(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetColumnText(self, *_args, **_kwargs)
return val
def GetColumnText(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetColumnText(self, *_args, **_kwargs)
return val
def SetColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetColumn(self, *_args, **_kwargs)
return val
def GetColumn(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetColumn(self, *_args, **_kwargs)
if val: val = wxTreeListColumnInfoPtr(val)
return val
def SetColumnAlignment(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetColumnAlignment(self, *_args, **_kwargs)
return val
def GetColumnAlignment(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetColumnAlignment(self, *_args, **_kwargs)
return val
def SetColumnImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetColumnImage(self, *_args, **_kwargs)
return val
def GetColumnImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetColumnImage(self, *_args, **_kwargs)
return val
def GetItemText(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemText(self, *_args, **_kwargs)
return val
def GetItemImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemImage(self, *_args, **_kwargs)
return val
def SetItemText(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemText(self, *_args, **_kwargs)
return val
def SetItemImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemImage(self, *_args, **_kwargs)
return val
def GetItemData(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemData(self, *_args, **_kwargs)
if val: val = wxTreeItemDataPtr(val)
return val
def SetItemData(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemData(self, *_args, **_kwargs)
return val
def GetPyData(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetPyData(self, *_args, **_kwargs)
return val
def SetPyData(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetPyData(self, *_args, **_kwargs)
return val
def SetItemHasChildren(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemHasChildren(self, *_args, **_kwargs)
return val
def SetItemBold(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemBold(self, *_args, **_kwargs)
return val
def SetItemTextColour(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemTextColour(self, *_args, **_kwargs)
return val
def SetItemBackgroundColour(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemBackgroundColour(self, *_args, **_kwargs)
return val
def SetItemFont(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemFont(self, *_args, **_kwargs)
return val
def GetItemBold(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemBold(self, *_args, **_kwargs)
return val
def GetItemTextColour(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemTextColour(self, *_args, **_kwargs)
if val: val = wxColourPtr(val) ; val.thisown = 1
return val
def GetItemBackgroundColour(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemBackgroundColour(self, *_args, **_kwargs)
if val: val = wxColourPtr(val) ; val.thisown = 1
return val
def GetItemFont(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemFont(self, *_args, **_kwargs)
if val: val = wxFontPtr(val) ; val.thisown = 1
return val
def IsVisible(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_IsVisible(self, *_args, **_kwargs)
return val
def ItemHasChildren(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_ItemHasChildren(self, *_args, **_kwargs)
return val
def IsExpanded(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_IsExpanded(self, *_args, **_kwargs)
return val
def IsSelected(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_IsSelected(self, *_args, **_kwargs)
return val
def IsBold(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_IsBold(self, *_args, **_kwargs)
return val
def GetChildrenCount(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetChildrenCount(self, *_args, **_kwargs)
return val
def GetRootItem(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetRootItem(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetSelection(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetSelection(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetSelections(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetSelections(self, *_args, **_kwargs)
return val
def GetItemParent(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemParent(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetFirstChild(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetFirstChild(self, *_args, **_kwargs)
return val
def GetNextChild(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetNextChild(self, *_args, **_kwargs)
return val
def GetLastChild(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetLastChild(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetNextSibling(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetNextSibling(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetPrevSibling(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetPrevSibling(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetFirstVisibleItem(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetFirstVisibleItem(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetNextVisible(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetNextVisible(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetPrevVisible(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetPrevVisible(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def GetNext(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetNext(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def AddRoot(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AddRoot(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def PrependItem(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_PrependItem(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def InsertItem(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_InsertItem(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def InsertItemBefore(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_InsertItemBefore(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def AppendItem(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_AppendItem(self, *_args, **_kwargs)
if val: val = wxTreeItemIdPtr(val) ; val.thisown = 1
return val
def Delete(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Delete(self, *_args, **_kwargs)
return val
def DeleteChildren(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_DeleteChildren(self, *_args, **_kwargs)
return val
def DeleteAllItems(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_DeleteAllItems(self, *_args, **_kwargs)
return val
def Expand(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Expand(self, *_args, **_kwargs)
return val
def ExpandAll(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_ExpandAll(self, *_args, **_kwargs)
return val
def Collapse(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Collapse(self, *_args, **_kwargs)
return val
def CollapseAndReset(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_CollapseAndReset(self, *_args, **_kwargs)
return val
def Toggle(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Toggle(self, *_args, **_kwargs)
return val
def Unselect(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Unselect(self, *_args, **_kwargs)
return val
def UnselectAll(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_UnselectAll(self, *_args, **_kwargs)
return val
def SelectItem(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SelectItem(self, *_args, **_kwargs)
return val
def EnsureVisible(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_EnsureVisible(self, *_args, **_kwargs)
return val
def ScrollTo(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_ScrollTo(self, *_args, **_kwargs)
return val
def HitTest(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_HitTest(self, *_args, **_kwargs)
return val
def GetBoundingRect(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetBoundingRect(self, *_args, **_kwargs)
return val
def EditLabel(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_EditLabel(self, *_args, **_kwargs)
return val
def Edit(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_Edit(self, *_args, **_kwargs)
return val
def SortChildren(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SortChildren(self, *_args, **_kwargs)
return val
def GetItemSelectedImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetItemSelectedImage(self, *_args, **_kwargs)
return val
def SetItemSelectedImage(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_SetItemSelectedImage(self, *_args, **_kwargs)
return val
def GetHeaderWindow(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetHeaderWindow(self, *_args, **_kwargs)
return val
def GetMainWindow(self, *_args, **_kwargs):
val = gizmosc.wxTreeListCtrl_GetMainWindow(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<%s.%s instance; proxy of C++ wxTreeListCtrl instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
# Redefine some methods that SWIG gets a bit confused on...
def GetFirstChild(self, *_args, **_kwargs):
val1,val2 = gizmosc.wxTreeListCtrl_GetFirstChild(self, *_args, **_kwargs)
val1 = wxTreeItemIdPtr(val1)
val1.thisown = 1
return (val1,val2)
def GetNextChild(self, *_args, **_kwargs):
val1,val2 = gizmosc.wxTreeListCtrl_GetNextChild(self, *_args, **_kwargs)
val1 = wxTreeItemIdPtr(val1)
val1.thisown = 1
return (val1,val2)
def HitTest(self, *_args, **_kwargs):
val1, val2, val3 = gizmosc.wxTreeListCtrl_HitTest(self, *_args, **_kwargs)
val1 = wxTreeItemIdPtr(val1)
val1.thisown = 1
return (val1, val2, val3)
class wxTreeListCtrl(wxTreeListCtrlPtr):
def __init__(self,*_args,**_kwargs):
self.this = gizmosc.new_wxTreeListCtrl(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxTreeListCtrl)
self._setOORInfo(self)
def wxPreTreeListCtrl(*_args,**_kwargs):
val = wxTreeListCtrlPtr(gizmosc.new_wxPreTreeListCtrl(*_args,**_kwargs))
val.thisown = 1
val._setOORInfo(val)
return val
@@ -300,6 +701,10 @@ wxLED_ALIGN_RIGHT = gizmosc.wxLED_ALIGN_RIGHT
wxLED_ALIGN_CENTER = gizmosc.wxLED_ALIGN_CENTER
wxLED_ALIGN_MASK = gizmosc.wxLED_ALIGN_MASK
wxLED_DRAW_FADED = gizmosc.wxLED_DRAW_FADED
wxTL_ALIGN_LEFT = gizmosc.wxTL_ALIGN_LEFT
wxTL_ALIGN_RIGHT = gizmosc.wxTL_ALIGN_RIGHT
wxTL_ALIGN_CENTER = gizmosc.wxTL_ALIGN_CENTER
wxTREE_HITTEST_ONITEMCOLUMN = gizmosc.wxTREE_HITTEST_ONITEMCOLUMN
#-------------- USER INCLUDE -----------------------

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,509 @@
// -*- C++ -*- //////////////////////////////////////////////////////////////
// Name: treelistctrl.h (derived by wx/treectrlg.h)
// Purpose: wxTreeListCtrl class
// Author: Robert Roebling
// Modified by: Alberto Griggio, 2002
// Created: 01/02/97
// RCS-ID: $Id$
// Copyright: (c) 1997,1998 Robert Roebling
// Licence: wxWindows license
/////////////////////////////////////////////////////////////////////////////
#ifndef TREELISTCTRL_H
#define TREELISTCTRL_H
#if defined(__GNUG__) && !defined(__APPLE__)
#pragma interface "treelistctrl.h"
#endif
#include <wx/treectrl.h>
#include <wx/control.h>
#include <wx/pen.h>
#include <wx/listctrl.h> // for wxListEvent
#ifdef GIZMOISDLL
#define GIZMODLLEXPORT WXDLLEXPORT
#else
#define GIZMODLLEXPORT
#endif
class GIZMODLLEXPORT wxTreeListItem;
class GIZMODLLEXPORT wxTreeListHeaderWindow;
class GIZMODLLEXPORT wxTreeListMainWindow;
//-----------------------------------------------------------------------------
// wxTreeListColumnAttrs
//-----------------------------------------------------------------------------
enum wxTreeListColumnAlign {
wxTL_ALIGN_LEFT,
wxTL_ALIGN_RIGHT,
wxTL_ALIGN_CENTER
};
class GIZMODLLEXPORT wxTreeListColumnInfo: public wxObject {
public:
enum { DEFAULT_COL_WIDTH = 100 };
wxTreeListColumnInfo(const wxChar* text = wxT(""),
int image = -1,
size_t width = DEFAULT_COL_WIDTH,
wxTreeListColumnAlign alignment = wxTL_ALIGN_LEFT)
{
m_image = image;
m_selected_image = -1;
m_text = text;
m_width = width;
m_alignment = alignment;
}
wxTreeListColumnInfo(const wxTreeListColumnInfo& other)
{
m_image = other.m_image;
m_selected_image = other.m_selected_image;
m_text = other.m_text;
m_width = other.m_width;
m_alignment = other.m_alignment;
}
~wxTreeListColumnInfo() {}
// getters
wxTreeListColumnAlign GetAlignment() const { return m_alignment; }
wxString GetText() const { return m_text; }
int GetImage() const { return m_image; }
int GetSelectedImage() const { return m_selected_image; }
size_t GetWidth() const { return m_width; }
// setters
wxTreeListColumnInfo& SetAlignment(wxTreeListColumnAlign alignment)
{ m_alignment = alignment; return *this; }
wxTreeListColumnInfo& SetText(const wxString& text)
{ m_text = text; return *this; }
wxTreeListColumnInfo& SetImage(int image)
{ m_image = image; return *this; }
wxTreeListColumnInfo& SetSelectedImage(int image)
{ m_selected_image = image; return *this; }
wxTreeListColumnInfo& SetWidth(size_t with)
{ m_width = with; return *this; }
private:
wxTreeListColumnAlign m_alignment;
wxString m_text;
int m_image;
int m_selected_image;
size_t m_width;
};
//----------------------------------------------------------------------------
// wxTreeListCtrl - the multicolumn tree control
//----------------------------------------------------------------------------
// additional flag for HitTest
const int wxTREE_HITTEST_ONITEMCOLUMN = 0x2000;
extern GIZMODLLEXPORT const wxChar* wxTreeListCtrlNameStr;
class GIZMODLLEXPORT wxTreeListCtrl : public wxControl
{
public:
// creation
// --------
wxTreeListCtrl() {}
wxTreeListCtrl(wxWindow *parent, wxWindowID id = -1,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxTR_DEFAULT_STYLE,
const wxValidator &validator = wxDefaultValidator,
const wxString& name = wxTreeListCtrlNameStr )
: m_header_win(0), m_main_win(0)
{
Create(parent, id, pos, size, style, validator, name);
}
virtual ~wxTreeListCtrl() {}
bool Create(wxWindow *parent, wxWindowID id = -1,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize,
long style = wxTR_DEFAULT_STYLE,
const wxValidator &validator = wxDefaultValidator,
const wxString& name = wxTreeListCtrlNameStr );
void Refresh(bool erase=TRUE, const wxRect* rect=NULL);
void SetFocus();
// accessors
// ---------
// get the total number of items in the control
size_t GetCount() const;
// indent is the number of pixels the children are indented relative to
// the parents position. SetIndent() also redraws the control
// immediately.
unsigned int GetIndent() const;
void SetIndent(unsigned int indent);
// spacing is the number of pixels between the start and the Text
unsigned int GetSpacing() const;
void SetSpacing(unsigned int spacing);
// line spacing is the space above and below the text on each line
unsigned int GetLineSpacing() const;
void SetLineSpacing(unsigned int spacing);
// image list: these functions allow to associate an image list with
// the control and retrieve it. Note that when assigned with
// SetImageList, the control does _not_ delete
// the associated image list when it's deleted in order to allow image
// lists to be shared between different controls. If you use
// AssignImageList, the control _does_ delete the image list.
//
// The normal image list is for the icons which correspond to the
// normal tree item state (whether it is selected or not).
// Additionally, the application might choose to show a state icon
// which corresponds to an app-defined item state (for example,
// checked/unchecked) which are taken from the state image list.
wxImageList *GetImageList() const;
wxImageList *GetStateImageList() const;
wxImageList *GetButtonsImageList() const;
void SetImageList(wxImageList *imageList);
void SetStateImageList(wxImageList *imageList);
void SetButtonsImageList(wxImageList *imageList);
void AssignImageList(wxImageList *imageList);
void AssignStateImageList(wxImageList *imageList);
void AssignButtonsImageList(wxImageList *imageList);
// Functions to work with tree list ctrl columns
// adds a column
void AddColumn(const wxString& text)
{ AddColumn(wxTreeListColumnInfo().SetText(text)); }
void AddColumn(const wxTreeListColumnInfo& col);
// inserts a column before the given one
void InsertColumn(size_t before, const wxString& text)
{ InsertColumn(before, wxTreeListColumnInfo().SetText(text)); }
void InsertColumn(size_t before, const wxTreeListColumnInfo& col);
// deletes the given column - does not delete the corresponding column
// of each item
void RemoveColumn(size_t column);
// returns the number of columns in the ctrl
size_t GetColumnCount() const;
void SetColumnWidth(size_t column, size_t width);
int GetColumnWidth(size_t column) const;
// tells which column is the "main" one, i.e. the "threaded" one
void SetMainColumn(size_t column);
size_t GetMainColumn() const;
void SetColumnText(size_t column, const wxString& text);
wxString GetColumnText(size_t column) const;
void SetColumn(size_t column, const wxTreeListColumnInfo& info);
wxTreeListColumnInfo& GetColumn(size_t column);
const wxTreeListColumnInfo& GetColumn(size_t column) const;
// other column-related methods
void SetColumnAlignment(size_t column, wxTreeListColumnAlign align);
wxTreeListColumnAlign GetColumnAlignment(size_t column) const;
void SetColumnImage(size_t column, int image);
int GetColumnImage(size_t column) const;
// Functions to work with tree list ctrl items.
// accessors
// ---------
// retrieve item's label (of the main column)
wxString GetItemText(const wxTreeItemId& item) const
{ return GetItemText(item, GetMainColumn()); }
// retrieves item's label of the given column
wxString GetItemText(const wxTreeItemId& item, size_t column) const;
// get one of the images associated with the item (normal by default)
int GetItemImage(const wxTreeItemId& item,
wxTreeItemIcon which = wxTreeItemIcon_Normal) const
{ return GetItemImage(item, GetMainColumn(), which); }
int GetItemImage(const wxTreeItemId& item, size_t column,
wxTreeItemIcon which = wxTreeItemIcon_Normal) const;
// get the data associated with the item
wxTreeItemData *GetItemData(const wxTreeItemId& item) const;
bool GetItemBold(const wxTreeItemId& item) const;
wxColour GetItemTextColour(const wxTreeItemId& item) const;
wxColour GetItemBackgroundColour(const wxTreeItemId& item) const;
wxFont GetItemFont(const wxTreeItemId& item) const;
// modifiers
// ---------
// set item's label
void SetItemText(const wxTreeItemId& item, const wxString& text)
{ SetItemText(item, GetMainColumn(), text); }
void SetItemText(const wxTreeItemId& item, size_t column,
const wxString& text);
// get one of the images associated with the item (normal by default)
void SetItemImage(const wxTreeItemId& item, int image,
wxTreeItemIcon which = wxTreeItemIcon_Normal)
{ SetItemImage(item, GetMainColumn(), image, which); }
// the which parameter is ignored for all columns but the main one
void SetItemImage(const wxTreeItemId& item, size_t column, int image,
wxTreeItemIcon which = wxTreeItemIcon_Normal);
// associate some data with the item
void SetItemData(const wxTreeItemId& item, wxTreeItemData *data);
// force appearance of [+] button near the item. This is useful to
// allow the user to expand the items which don't have any children now
// - but instead add them only when needed, thus minimizing memory
// usage and loading time.
void SetItemHasChildren(const wxTreeItemId& item, bool has = TRUE);
// the item will be shown in bold
void SetItemBold(const wxTreeItemId& item, bool bold = TRUE);
// set the item's text colour
void SetItemTextColour(const wxTreeItemId& item, const wxColour& col);
// set the item's background colour
void SetItemBackgroundColour(const wxTreeItemId& item,
const wxColour& col);
// set the item's font (should be of the same height for all items)
void SetItemFont(const wxTreeItemId& item, const wxFont& font);
// set the window font
virtual bool SetFont( const wxFont &font );
// set the styles.
void SetWindowStyle(const long styles);
long GetWindowStyle() const;
long GetWindowStyleFlag() const { return GetWindowStyle(); }
// item status inquiries
// ---------------------
// is the item visible (it might be outside the view or not expanded)?
bool IsVisible(const wxTreeItemId& item) const;
// does the item has any children?
bool HasChildren(const wxTreeItemId& item) const
{ return ItemHasChildren(item); }
bool ItemHasChildren(const wxTreeItemId& item) const;
// is the item expanded (only makes sense if HasChildren())?
bool IsExpanded(const wxTreeItemId& item) const;
// is this item currently selected (the same as has focus)?
bool IsSelected(const wxTreeItemId& item) const;
// is item text in bold font?
bool IsBold(const wxTreeItemId& item) const;
// does the layout include space for a button?
// number of children
// ------------------
// if 'recursively' is FALSE, only immediate children count, otherwise
// the returned number is the number of all items in this branch
size_t GetChildrenCount(const wxTreeItemId& item, bool recursively = TRUE);
// navigation
// ----------
// wxTreeItemId.IsOk() will return FALSE if there is no such item
// get the root tree item
wxTreeItemId GetRootItem() const;
// get the item currently selected (may return NULL if no selection)
wxTreeItemId GetSelection() const;
// get the items currently selected, return the number of such item
size_t GetSelections(wxArrayTreeItemIds&) const;
// get the parent of this item (may return NULL if root)
wxTreeItemId GetParent(const wxTreeItemId& item) const;
// for this enumeration function you must pass in a "cookie" parameter
// which is opaque for the application but is necessary for the library
// to make these functions reentrant (i.e. allow more than one
// enumeration on one and the same object simultaneously). Of course,
// the "cookie" passed to GetFirstChild() and GetNextChild() should be
// the same!
// get the first child of this item
wxTreeItemId GetFirstChild(const wxTreeItemId& item, long& cookie) const;
// get the next child
wxTreeItemId GetNextChild(const wxTreeItemId& item, long& cookie) const;
// get the last child of this item - this method doesn't use cookies
wxTreeItemId GetLastChild(const wxTreeItemId& item) const;
// get the next sibling of this item
wxTreeItemId GetNextSibling(const wxTreeItemId& item) const;
// get the previous sibling
wxTreeItemId GetPrevSibling(const wxTreeItemId& item) const;
// get first visible item
wxTreeItemId GetFirstVisibleItem() const;
// get the next visible item: item must be visible itself!
// see IsVisible() and wxTreeCtrl::GetFirstVisibleItem()
wxTreeItemId GetNextVisible(const wxTreeItemId& item) const;
// get the previous visible item: item must be visible itself!
wxTreeItemId GetPrevVisible(const wxTreeItemId& item) const;
// Only for internal use right now, but should probably be public
wxTreeItemId GetNext(const wxTreeItemId& item) const;
// operations
// ----------
// add the root node to the tree
wxTreeItemId AddRoot(const wxString& text,
int image = -1, int selectedImage = -1,
wxTreeItemData *data = NULL);
// insert a new item in as the first child of the parent
wxTreeItemId PrependItem(const wxTreeItemId& parent,
const wxString& text,
int image = -1, int selectedImage = -1,
wxTreeItemData *data = NULL);
// insert a new item after a given one
wxTreeItemId InsertItem(const wxTreeItemId& parent,
const wxTreeItemId& idPrevious,
const wxString& text,
int image = -1, int selectedImage = -1,
wxTreeItemData *data = NULL);
// insert a new item before the one with the given index
wxTreeItemId InsertItem(const wxTreeItemId& parent,
size_t index,
const wxString& text,
int image = -1, int selectedImage = -1,
wxTreeItemData *data = NULL);
// insert a new item in as the last child of the parent
wxTreeItemId AppendItem(const wxTreeItemId& parent,
const wxString& text,
int image = -1, int selectedImage = -1,
wxTreeItemData *data = NULL);
// delete this item and associated data if any
void Delete(const wxTreeItemId& item);
// delete all children (but don't delete the item itself)
// NB: this won't send wxEVT_COMMAND_TREE_ITEM_DELETED events
void DeleteChildren(const wxTreeItemId& item);
// delete all items from the tree
// NB: this won't send wxEVT_COMMAND_TREE_ITEM_DELETED events
void DeleteAllItems();
// expand this item
void Expand(const wxTreeItemId& item);
// expand this item and all subitems recursively
void ExpandAll(const wxTreeItemId& item);
// collapse the item without removing its children
void Collapse(const wxTreeItemId& item);
// collapse the item and remove all children
void CollapseAndReset(const wxTreeItemId& item);
// toggles the current state
void Toggle(const wxTreeItemId& item);
// remove the selection from currently selected item (if any)
void Unselect();
void UnselectAll();
// select this item
void SelectItem(const wxTreeItemId& item, bool unselect_others=TRUE,
bool extended_select=FALSE);
// make sure this item is visible (expanding the parent item and/or
// scrolling to this item if necessary)
void EnsureVisible(const wxTreeItemId& item);
// scroll to this item (but don't expand its parent)
void ScrollTo(const wxTreeItemId& item);
//void AdjustMyScrollbars();
// 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)
{ int col; return HitTest(point, flags, col); }
wxTreeItemId HitTest(const wxPoint& point, int& flags, int& column);
// get the bounding rectangle of the item (or of its label only)
bool GetBoundingRect(const wxTreeItemId& item,
wxRect& rect,
bool textOnly = FALSE) const;
// 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.
void EditLabel( const wxTreeItemId& item ) { Edit( item ); }
void Edit( const wxTreeItemId& item );
// sorting
// this function is called to compare 2 items and should return -1, 0
// or +1 if the first item is less than, equal to or greater than the
// second one. The base class version performs alphabetic comparaison
// of item labels (GetText)
virtual int OnCompareItems(const wxTreeItemId& item1,
const wxTreeItemId& item2);
// sort the children of this item using OnCompareItems
//
// NB: this function is not reentrant and not MT-safe (FIXME)!
void SortChildren(const wxTreeItemId& item);
// deprecated functions: use Set/GetItemImage directly
// get the selected item image
int GetItemSelectedImage(const wxTreeItemId& item) const
{ return GetItemImage(item, wxTreeItemIcon_Selected); }
// set the selected item image
void SetItemSelectedImage(const wxTreeItemId& item, int image)
{ SetItemImage(item, image, wxTreeItemIcon_Selected); }
// implementation only from now on
// overridden base class virtuals
virtual bool SetBackgroundColour(const wxColour& colour);
virtual bool SetForegroundColour(const wxColour& colour);
wxTreeListHeaderWindow* GetHeaderWindow() const
{ return m_header_win; }
wxTreeListMainWindow* GetMainWindow() const
{ return m_main_win; }
protected:
// header window, responsible for column visualization and manipulation
wxTreeListHeaderWindow* m_header_win;
// main window, the "true" tree ctrl
wxTreeListMainWindow* m_main_win;
// the common part of all ctors
void Init();
void OnSize(wxSizeEvent& event);
private:
DECLARE_EVENT_TABLE()
DECLARE_DYNAMIC_CLASS(wxTreeListCtrl)
};
#endif // TREELISTCTRL_H

View File

@@ -54,36 +54,36 @@ class wxGLContextPtr(wxObjectPtr):
except:
pass
def SetCurrent(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetCurrent,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetCurrent(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetColour,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetColour(self, *_args, **_kwargs)
return val
def SwapBuffers(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SwapBuffers,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SwapBuffers(self, *_args, **_kwargs)
return val
def SetupPixelFormat(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetupPixelFormat,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetupPixelFormat(self, *_args, **_kwargs)
return val
def SetupPalette(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetupPalette,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetupPalette(self, *_args, **_kwargs)
return val
def CreateDefaultPalette(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_CreateDefaultPalette,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_CreateDefaultPalette(self, *_args, **_kwargs)
if val: val = wxPalettePtr(val) ; val.thisown = 1
return val
def GetPalette(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_GetPalette,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_GetPalette(self, *_args, **_kwargs)
if val: val = wxPalettePtr(val)
return val
def GetWindow(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_GetWindow,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_GetWindow(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxGLContext instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxGLContext instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxGLContext(wxGLContextPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(glcanvasc.new_wxGLContext,_args,_kwargs)
self.this = glcanvasc.new_wxGLContext(*_args,**_kwargs)
self.thisown = 1
@@ -94,30 +94,30 @@ class wxGLCanvasPtr(wxWindowPtr):
self.this = this
self.thisown = 0
def SetCurrent(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetCurrent,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetCurrent(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetColour,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetColour(self, *_args, **_kwargs)
return val
def SwapBuffers(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SwapBuffers,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SwapBuffers(self, *_args, **_kwargs)
return val
def GetContext(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_GetContext,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_GetContext(self, *_args, **_kwargs)
if val: val = wxGLContextPtr(val)
return val
def __repr__(self):
return "<C wxGLCanvas instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxGLCanvas instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxGLCanvas(wxGLCanvasPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(glcanvasc.new_wxGLCanvas,_args,_kwargs)
self.this = glcanvasc.new_wxGLCanvas(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
def wxGLCanvasWithContext(*_args,**_kwargs):
val = wxGLCanvasPtr(apply(glcanvasc.new_wxGLCanvasWithContext,_args,_kwargs))
val = wxGLCanvasPtr(glcanvasc.new_wxGLCanvasWithContext(*_args,**_kwargs))
val.thisown = 1
val._setOORInfo(self)
return val

View File

@@ -54,19 +54,19 @@ class wxGLContextPtr(wxObjectPtr):
except:
pass
def SetCurrent(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetCurrent,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetCurrent(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetColour,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetColour(self, *_args, **_kwargs)
return val
def SwapBuffers(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SwapBuffers,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SwapBuffers(self, *_args, **_kwargs)
return val
def GetWindow(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_GetWindow,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_GetWindow(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxGLContext instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxGLContext instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxGLContext(wxGLContextPtr):
def __init__(self,this):
self.this = this
@@ -79,30 +79,30 @@ class wxGLCanvasPtr(wxWindowPtr):
self.this = this
self.thisown = 0
def SetCurrent(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetCurrent,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetCurrent(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetColour,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetColour(self, *_args, **_kwargs)
return val
def SwapBuffers(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SwapBuffers,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SwapBuffers(self, *_args, **_kwargs)
return val
def GetContext(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_GetContext,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_GetContext(self, *_args, **_kwargs)
if val: val = wxGLContextPtr(val)
return val
def __repr__(self):
return "<C wxGLCanvas instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxGLCanvas instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxGLCanvas(wxGLCanvasPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(glcanvasc.new_wxGLCanvas,_args,_kwargs)
self.this = glcanvasc.new_wxGLCanvas(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
def wxGLCanvasWithContext(*_args,**_kwargs):
val = wxGLCanvasPtr(apply(glcanvasc.new_wxGLCanvasWithContext,_args,_kwargs))
val = wxGLCanvasPtr(glcanvasc.new_wxGLCanvasWithContext(*_args,**_kwargs))
val.thisown = 1
val._setOORInfo(self)
return val

View File

@@ -54,22 +54,22 @@ class wxGLContextPtr(wxObjectPtr):
except:
pass
def SetCurrent(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetCurrent,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetCurrent(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SetColour,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SetColour(self, *_args, **_kwargs)
return val
def SwapBuffers(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_SwapBuffers,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_SwapBuffers(self, *_args, **_kwargs)
return val
def GetWindow(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLContext_GetWindow,(self,) + _args, _kwargs)
val = glcanvasc.wxGLContext_GetWindow(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxGLContext instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxGLContext instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxGLContext(wxGLContextPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(glcanvasc.new_wxGLContext,_args,_kwargs)
self.this = glcanvasc.new_wxGLContext(*_args,**_kwargs)
self.thisown = 1
@@ -80,44 +80,44 @@ class wxGLCanvasPtr(wxWindowPtr):
self.this = this
self.thisown = 0
def SetCurrent(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetCurrent,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetCurrent(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetColour,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetColour(self, *_args, **_kwargs)
return val
def SwapBuffers(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SwapBuffers,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SwapBuffers(self, *_args, **_kwargs)
return val
def GetContext(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_GetContext,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_GetContext(self, *_args, **_kwargs)
if val: val = wxGLContextPtr(val)
return val
def SetupPixelFormat(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetupPixelFormat,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetupPixelFormat(self, *_args, **_kwargs)
return val
def SetupPalette(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_SetupPalette,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_SetupPalette(self, *_args, **_kwargs)
return val
def CreateDefaultPalette(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_CreateDefaultPalette,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_CreateDefaultPalette(self, *_args, **_kwargs)
if val: val = wxPalettePtr(val) ; val.thisown = 1
return val
def GetPalette(self, *_args, **_kwargs):
val = apply(glcanvasc.wxGLCanvas_GetPalette,(self,) + _args, _kwargs)
val = glcanvasc.wxGLCanvas_GetPalette(self, *_args, **_kwargs)
if val: val = wxPalettePtr(val)
return val
def __repr__(self):
return "<C wxGLCanvas instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxGLCanvas instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxGLCanvas(wxGLCanvasPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(glcanvasc.new_wxGLCanvas,_args,_kwargs)
self.this = glcanvasc.new_wxGLCanvas(*_args,**_kwargs)
self.thisown = 1
self._setOORInfo(self)
def wxGLCanvasWithContext(*_args,**_kwargs):
val = wxGLCanvasPtr(apply(glcanvasc.new_wxGLCanvasWithContext,_args,_kwargs))
val = wxGLCanvasPtr(glcanvasc.new_wxGLCanvasWithContext(*_args,**_kwargs))
val.thisown = 1
val._setOORInfo(self)
return val

View File

@@ -67,19 +67,19 @@ class wxMSHTMLEventPtr(wxNotifyEventPtr):
self.this = this
self.thisown = 0
def GetText1(self, *_args, **_kwargs):
val = apply(iewinc.wxMSHTMLEvent_GetText1,(self,) + _args, _kwargs)
val = iewinc.wxMSHTMLEvent_GetText1(self, *_args, **_kwargs)
return val
def GetLong1(self, *_args, **_kwargs):
val = apply(iewinc.wxMSHTMLEvent_GetLong1,(self,) + _args, _kwargs)
val = iewinc.wxMSHTMLEvent_GetLong1(self, *_args, **_kwargs)
return val
def GetLong2(self, *_args, **_kwargs):
val = apply(iewinc.wxMSHTMLEvent_GetLong2,(self,) + _args, _kwargs)
val = iewinc.wxMSHTMLEvent_GetLong2(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxMSHTMLEvent instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxMSHTMLEvent instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxMSHTMLEvent(wxMSHTMLEventPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(iewinc.new_wxMSHTMLEvent,_args,_kwargs)
self.this = iewinc.new_wxMSHTMLEvent(*_args,**_kwargs)
self.thisown = 1
@@ -90,53 +90,53 @@ class wxIEHtmlWinPtr(wxWindowPtr):
self.this = this
self.thisown = 0
def LoadUrl(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_LoadUrl,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_LoadUrl(self, *_args, **_kwargs)
return val
def LoadString(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_LoadString,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_LoadString(self, *_args, **_kwargs)
return val
def LoadStream(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_LoadStream,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_LoadStream(self, *_args, **_kwargs)
return val
def SetCharset(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_SetCharset,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_SetCharset(self, *_args, **_kwargs)
return val
def SetEditMode(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_SetEditMode,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_SetEditMode(self, *_args, **_kwargs)
return val
def GetEditMode(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GetEditMode,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GetEditMode(self, *_args, **_kwargs)
return val
def GetStringSelection(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GetStringSelection,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GetStringSelection(self, *_args, **_kwargs)
return val
def GetText(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GetText,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GetText(self, *_args, **_kwargs)
return val
def GoBack(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GoBack,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GoBack(self, *_args, **_kwargs)
return val
def GoForward(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GoForward,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GoForward(self, *_args, **_kwargs)
return val
def GoHome(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GoHome,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GoHome(self, *_args, **_kwargs)
return val
def GoSearch(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_GoSearch,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_GoSearch(self, *_args, **_kwargs)
return val
def RefreshPage(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_RefreshPage,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_RefreshPage(self, *_args, **_kwargs)
return val
def Stop(self, *_args, **_kwargs):
val = apply(iewinc.wxIEHtmlWin_Stop,(self,) + _args, _kwargs)
val = iewinc.wxIEHtmlWin_Stop(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxIEHtmlWin instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxIEHtmlWin instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
Navigate = LoadUrl
class wxIEHtmlWin(wxIEHtmlWinPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(iewinc.new_wxIEHtmlWin,_args,_kwargs)
self.this = iewinc.new_wxIEHtmlWin(*_args,**_kwargs)
self.thisown = 1

View File

@@ -49,97 +49,97 @@ class wxShapeRegionPtr(wxObjectPtr):
self.this = this
self.thisown = 0
def SetText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetText,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetText(self, *_args, **_kwargs)
return val
def SetFont(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetFont,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetFont(self, *_args, **_kwargs)
return val
def SetMinSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetMinSize,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetMinSize(self, *_args, **_kwargs)
return val
def SetSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetSize,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetSize(self, *_args, **_kwargs)
return val
def SetPosition(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetPosition,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetPosition(self, *_args, **_kwargs)
return val
def SetProportions(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetProportions,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetProportions(self, *_args, **_kwargs)
return val
def SetFormatMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetFormatMode,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetFormatMode(self, *_args, **_kwargs)
return val
def SetName(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetName,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetName(self, *_args, **_kwargs)
return val
def SetColour(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetColour,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetColour(self, *_args, **_kwargs)
return val
def GetText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetText,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetText(self, *_args, **_kwargs)
return val
def GetFont(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetFont,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetFont(self, *_args, **_kwargs)
if val: val = wxFontPtr(val)
return val
def GetMinSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetMinSize,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetMinSize(self, *_args, **_kwargs)
return val
def GetProportion(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetProportion,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetProportion(self, *_args, **_kwargs)
return val
def GetSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetSize,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetSize(self, *_args, **_kwargs)
return val
def GetPosition(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetPosition,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetPosition(self, *_args, **_kwargs)
return val
def GetFormatMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetFormatMode,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetFormatMode(self, *_args, **_kwargs)
return val
def GetName(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetName,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetName(self, *_args, **_kwargs)
return val
def GetColour(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetColour,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetColour(self, *_args, **_kwargs)
return val
def GetActualColourObject(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetActualColourObject,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetActualColourObject(self, *_args, **_kwargs)
if val: val = wxColourPtr(val)
return val
def GetFormattedText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetFormattedText,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetFormattedText(self, *_args, **_kwargs)
return val
def GetPenColour(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetPenColour,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetPenColour(self, *_args, **_kwargs)
return val
def GetPenStyle(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetPenStyle,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetPenStyle(self, *_args, **_kwargs)
return val
def SetPenStyle(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetPenStyle,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetPenStyle(self, *_args, **_kwargs)
return val
def SetPenColour(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_SetPenColour,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_SetPenColour(self, *_args, **_kwargs)
return val
def GetActualPen(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetActualPen,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetActualPen(self, *_args, **_kwargs)
if val: val = wxPenPtr(val)
return val
def GetWidth(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetWidth,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetWidth(self, *_args, **_kwargs)
return val
def GetHeight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_GetHeight,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_GetHeight(self, *_args, **_kwargs)
return val
def ClearText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxShapeRegion_ClearText,(self,) + _args, _kwargs)
val = oglbasicc.wxShapeRegion_ClearText(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxShapeRegion instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxShapeRegion instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxShapeRegion(wxShapeRegionPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglbasicc.new_wxShapeRegion,_args,_kwargs)
self.this = oglbasicc.new_wxShapeRegion(*_args,**_kwargs)
self.thisown = 1
@@ -150,121 +150,121 @@ class wxPyShapeEvtHandlerPtr(wxObjectPtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler__setCallbackInfo,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler__setCallbackInfo(self, *_args, **_kwargs)
return val
def Destroy(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_Destroy,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_Destroy(self, *_args, **_kwargs)
return val
def _setOORInfo(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler__setOORInfo,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler__setOORInfo(self, *_args, **_kwargs)
return val
def SetShape(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_SetShape,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_SetShape(self, *_args, **_kwargs)
return val
def GetShape(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_GetShape,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_GetShape(self, *_args, **_kwargs)
return val
def SetPreviousHandler(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_SetPreviousHandler,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_SetPreviousHandler(self, *_args, **_kwargs)
return val
def GetPreviousHandler(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_GetPreviousHandler,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_GetPreviousHandler(self, *_args, **_kwargs)
return val
def CreateNewCopy(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_CreateNewCopy,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_CreateNewCopy(self, *_args, **_kwargs)
return val
def base_OnDelete(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDelete,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDelete(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDraw,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnErase,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnHighlight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnRightClick,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnMovePre,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnMovePost,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDragRight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShapeEvtHandler_base_OnEndSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShapeEvtHandler_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyShapeEvtHandler instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyShapeEvtHandler instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxPyShapeEvtHandler(wxPyShapeEvtHandlerPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglbasicc.new_wxPyShapeEvtHandler,_args,_kwargs)
self.this = oglbasicc.new_wxPyShapeEvtHandler(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyShapeEvtHandler)
self._setOORInfo(self)
@@ -277,506 +277,506 @@ class wxPyShapePtr(wxPyShapeEvtHandlerPtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape__setCallbackInfo,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape__setCallbackInfo(self, *_args, **_kwargs)
return val
def GetBoundingBoxMax(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBoundingBoxMax,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBoundingBoxMax(self, *_args, **_kwargs)
return val
def GetBoundingBoxMin(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBoundingBoxMin,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBoundingBoxMin(self, *_args, **_kwargs)
return val
def GetPerimeterPoint(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetPerimeterPoint,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetPerimeterPoint(self, *_args, **_kwargs)
return val
def GetCanvas(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetCanvas,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetCanvas(self, *_args, **_kwargs)
return val
def SetCanvas(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetCanvas,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetCanvas(self, *_args, **_kwargs)
return val
def AddToCanvas(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AddToCanvas,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AddToCanvas(self, *_args, **_kwargs)
return val
def InsertInCanvas(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_InsertInCanvas,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_InsertInCanvas(self, *_args, **_kwargs)
return val
def RemoveFromCanvas(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_RemoveFromCanvas,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_RemoveFromCanvas(self, *_args, **_kwargs)
return val
def GetX(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetX,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetX(self, *_args, **_kwargs)
return val
def GetY(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetY,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetY(self, *_args, **_kwargs)
return val
def SetX(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetX,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetX(self, *_args, **_kwargs)
return val
def SetY(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetY,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetY(self, *_args, **_kwargs)
return val
def GetParent(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetParent,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetParent(self, *_args, **_kwargs)
return val
def SetParent(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetParent,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetParent(self, *_args, **_kwargs)
return val
def GetTopAncestor(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetTopAncestor,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetTopAncestor(self, *_args, **_kwargs)
return val
def GetChildren(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetChildren,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetChildren(self, *_args, **_kwargs)
return val
def Unlink(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Unlink,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Unlink(self, *_args, **_kwargs)
return val
def SetDrawHandles(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetDrawHandles,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetDrawHandles(self, *_args, **_kwargs)
return val
def GetDrawHandles(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetDrawHandles,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetDrawHandles(self, *_args, **_kwargs)
return val
def MakeControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_MakeControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_MakeControlPoints(self, *_args, **_kwargs)
return val
def DeleteControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_DeleteControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_DeleteControlPoints(self, *_args, **_kwargs)
return val
def ResetControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ResetControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ResetControlPoints(self, *_args, **_kwargs)
return val
def GetEventHandler(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetEventHandler,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetEventHandler(self, *_args, **_kwargs)
return val
def SetEventHandler(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetEventHandler,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetEventHandler(self, *_args, **_kwargs)
return val
def MakeMandatoryControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_MakeMandatoryControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_MakeMandatoryControlPoints(self, *_args, **_kwargs)
return val
def ResetMandatoryControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ResetMandatoryControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ResetMandatoryControlPoints(self, *_args, **_kwargs)
return val
def Recompute(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Recompute,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Recompute(self, *_args, **_kwargs)
return val
def CalculateSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_CalculateSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_CalculateSize(self, *_args, **_kwargs)
return val
def Select(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Select,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Select(self, *_args, **_kwargs)
return val
def SetHighlight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetHighlight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetHighlight(self, *_args, **_kwargs)
return val
def IsHighlighted(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_IsHighlighted,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_IsHighlighted(self, *_args, **_kwargs)
return val
def Selected(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Selected,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Selected(self, *_args, **_kwargs)
return val
def AncestorSelected(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AncestorSelected,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AncestorSelected(self, *_args, **_kwargs)
return val
def SetSensitivityFilter(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetSensitivityFilter,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetSensitivityFilter(self, *_args, **_kwargs)
return val
def GetSensitivityFilter(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetSensitivityFilter,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetSensitivityFilter(self, *_args, **_kwargs)
return val
def SetDraggable(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetDraggable,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetDraggable(self, *_args, **_kwargs)
return val
def SetFixedSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetFixedSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetFixedSize(self, *_args, **_kwargs)
return val
def GetFixedSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetFixedSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetFixedSize(self, *_args, **_kwargs)
return val
def GetFixedWidth(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetFixedWidth,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetFixedWidth(self, *_args, **_kwargs)
return val
def GetFixedHeight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetFixedHeight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetFixedHeight(self, *_args, **_kwargs)
return val
def SetSpaceAttachments(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetSpaceAttachments,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetSpaceAttachments(self, *_args, **_kwargs)
return val
def GetSpaceAttachments(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetSpaceAttachments,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetSpaceAttachments(self, *_args, **_kwargs)
return val
def SetShadowMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetShadowMode,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetShadowMode(self, *_args, **_kwargs)
return val
def GetShadowMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetShadowMode,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetShadowMode(self, *_args, **_kwargs)
return val
def HitTest(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_HitTest,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_HitTest(self, *_args, **_kwargs)
return val
def SetCentreResize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetCentreResize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetCentreResize(self, *_args, **_kwargs)
return val
def GetCentreResize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetCentreResize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetCentreResize(self, *_args, **_kwargs)
return val
def SetMaintainAspectRatio(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetMaintainAspectRatio,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetMaintainAspectRatio(self, *_args, **_kwargs)
return val
def GetMaintainAspectRatio(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetMaintainAspectRatio,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetMaintainAspectRatio(self, *_args, **_kwargs)
return val
def GetLines(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetLines,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetLines(self, *_args, **_kwargs)
return val
def SetDisableLabel(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetDisableLabel,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetDisableLabel(self, *_args, **_kwargs)
return val
def GetDisableLabel(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetDisableLabel,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetDisableLabel(self, *_args, **_kwargs)
return val
def SetAttachmentMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetAttachmentMode,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetAttachmentMode(self, *_args, **_kwargs)
return val
def GetAttachmentMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetAttachmentMode,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetAttachmentMode(self, *_args, **_kwargs)
return val
def SetId(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetId,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetId(self, *_args, **_kwargs)
return val
def GetId(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetId,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetId(self, *_args, **_kwargs)
return val
def SetPen(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetPen,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetPen(self, *_args, **_kwargs)
return val
def SetBrush(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetBrush,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetBrush(self, *_args, **_kwargs)
return val
def Show(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Show,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Show(self, *_args, **_kwargs)
return val
def IsShown(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_IsShown,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_IsShown(self, *_args, **_kwargs)
return val
def Move(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Move,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Move(self, *_args, **_kwargs)
return val
def Erase(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Erase,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Erase(self, *_args, **_kwargs)
return val
def EraseContents(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_EraseContents,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_EraseContents(self, *_args, **_kwargs)
return val
def Draw(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Draw,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Draw(self, *_args, **_kwargs)
return val
def Flash(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Flash,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Flash(self, *_args, **_kwargs)
return val
def MoveLinks(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_MoveLinks,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_MoveLinks(self, *_args, **_kwargs)
return val
def DrawContents(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_DrawContents,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_DrawContents(self, *_args, **_kwargs)
return val
def SetSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetSize(self, *_args, **_kwargs)
return val
def SetAttachmentSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetAttachmentSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetAttachmentSize(self, *_args, **_kwargs)
return val
def Attach(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Attach,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Attach(self, *_args, **_kwargs)
return val
def Detach(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Detach,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Detach(self, *_args, **_kwargs)
return val
def Constrain(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Constrain,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Constrain(self, *_args, **_kwargs)
return val
def AddLine(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AddLine,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AddLine(self, *_args, **_kwargs)
return val
def GetLinePosition(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetLinePosition,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetLinePosition(self, *_args, **_kwargs)
return val
def AddText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AddText,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AddText(self, *_args, **_kwargs)
return val
def GetPen(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetPen,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetPen(self, *_args, **_kwargs)
if val: val = wxPenPtr(val)
return val
def GetBrush(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBrush,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBrush(self, *_args, **_kwargs)
if val: val = wxBrushPtr(val)
return val
def SetDefaultRegionSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetDefaultRegionSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetDefaultRegionSize(self, *_args, **_kwargs)
return val
def FormatText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_FormatText,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_FormatText(self, *_args, **_kwargs)
return val
def SetFormatMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetFormatMode,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetFormatMode(self, *_args, **_kwargs)
return val
def GetFormatMode(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetFormatMode,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetFormatMode(self, *_args, **_kwargs)
return val
def SetFont(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetFont,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetFont(self, *_args, **_kwargs)
return val
def GetFont(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetFont,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetFont(self, *_args, **_kwargs)
if val: val = wxFontPtr(val)
return val
def SetTextColour(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetTextColour,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetTextColour(self, *_args, **_kwargs)
return val
def GetTextColour(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetTextColour,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetTextColour(self, *_args, **_kwargs)
return val
def GetNumberOfTextRegions(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetNumberOfTextRegions,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetNumberOfTextRegions(self, *_args, **_kwargs)
return val
def SetRegionName(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetRegionName,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetRegionName(self, *_args, **_kwargs)
return val
def GetRegionName(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetRegionName,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetRegionName(self, *_args, **_kwargs)
return val
def GetRegionId(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetRegionId,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetRegionId(self, *_args, **_kwargs)
return val
def NameRegions(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_NameRegions,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_NameRegions(self, *_args, **_kwargs)
return val
def GetRegions(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetRegions,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetRegions(self, *_args, **_kwargs)
return val
def AddRegion(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AddRegion,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AddRegion(self, *_args, **_kwargs)
return val
def ClearRegions(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ClearRegions,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ClearRegions(self, *_args, **_kwargs)
return val
def AssignNewIds(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AssignNewIds,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AssignNewIds(self, *_args, **_kwargs)
return val
def FindRegion(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_FindRegion,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_FindRegion(self, *_args, **_kwargs)
return val
def FindRegionNames(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_FindRegionNames,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_FindRegionNames(self, *_args, **_kwargs)
return val
def ClearText(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ClearText,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ClearText(self, *_args, **_kwargs)
return val
def RemoveLine(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_RemoveLine,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_RemoveLine(self, *_args, **_kwargs)
return val
def GetAttachmentPosition(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetAttachmentPosition,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetAttachmentPosition(self, *_args, **_kwargs)
return val
def GetNumberOfAttachments(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetNumberOfAttachments,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetNumberOfAttachments(self, *_args, **_kwargs)
return val
def AttachmentIsValid(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AttachmentIsValid,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AttachmentIsValid(self, *_args, **_kwargs)
return val
def GetAttachmentPositionEdge(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetAttachmentPositionEdge,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetAttachmentPositionEdge(self, *_args, **_kwargs)
return val
def CalcSimpleAttachment(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_CalcSimpleAttachment,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_CalcSimpleAttachment(self, *_args, **_kwargs)
if val: val = wxRealPointPtr(val) ; val.thisown = 1
return val
def AttachmentSortTest(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_AttachmentSortTest,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_AttachmentSortTest(self, *_args, **_kwargs)
return val
def EraseLinks(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_EraseLinks,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_EraseLinks(self, *_args, **_kwargs)
return val
def DrawLinks(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_DrawLinks,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_DrawLinks(self, *_args, **_kwargs)
return val
def MoveLineToNewAttachment(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_MoveLineToNewAttachment,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_MoveLineToNewAttachment(self, *_args, **_kwargs)
return val
def ApplyAttachmentOrdering(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ApplyAttachmentOrdering,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ApplyAttachmentOrdering(self, *_args, **_kwargs)
return val
def GetBranchingAttachmentRoot(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchingAttachmentRoot,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchingAttachmentRoot(self, *_args, **_kwargs)
if val: val = wxRealPointPtr(val) ; val.thisown = 1
return val
def GetBranchingAttachmentInfo(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchingAttachmentInfo,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchingAttachmentInfo(self, *_args, **_kwargs)
return val
def GetBranchingAttachmentPoint(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchingAttachmentPoint,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchingAttachmentPoint(self, *_args, **_kwargs)
return val
def GetAttachmentLineCount(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetAttachmentLineCount,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetAttachmentLineCount(self, *_args, **_kwargs)
return val
def SetBranchNeckLength(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetBranchNeckLength,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetBranchNeckLength(self, *_args, **_kwargs)
return val
def GetBranchNeckLength(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchNeckLength,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchNeckLength(self, *_args, **_kwargs)
return val
def SetBranchStemLength(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetBranchStemLength,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetBranchStemLength(self, *_args, **_kwargs)
return val
def GetBranchStemLength(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchStemLength,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchStemLength(self, *_args, **_kwargs)
return val
def SetBranchSpacing(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetBranchSpacing,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetBranchSpacing(self, *_args, **_kwargs)
return val
def GetBranchSpacing(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchSpacing,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchSpacing(self, *_args, **_kwargs)
return val
def SetBranchStyle(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_SetBranchStyle,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_SetBranchStyle(self, *_args, **_kwargs)
return val
def GetBranchStyle(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBranchStyle,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBranchStyle(self, *_args, **_kwargs)
return val
def PhysicalToLogicalAttachment(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_PhysicalToLogicalAttachment,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_PhysicalToLogicalAttachment(self, *_args, **_kwargs)
return val
def LogicalToPhysicalAttachment(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_LogicalToPhysicalAttachment,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_LogicalToPhysicalAttachment(self, *_args, **_kwargs)
return val
def Draggable(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Draggable,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Draggable(self, *_args, **_kwargs)
return val
def HasDescendant(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_HasDescendant,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_HasDescendant(self, *_args, **_kwargs)
return val
def CreateNewCopy(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_CreateNewCopy,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_CreateNewCopy(self, *_args, **_kwargs)
return val
def Copy(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Copy,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Copy(self, *_args, **_kwargs)
return val
def CopyWithHandler(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_CopyWithHandler,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_CopyWithHandler(self, *_args, **_kwargs)
return val
def Rotate(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Rotate,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Rotate(self, *_args, **_kwargs)
return val
def GetRotation(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetRotation,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetRotation(self, *_args, **_kwargs)
return val
def ClearAttachments(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ClearAttachments,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ClearAttachments(self, *_args, **_kwargs)
return val
def Recentre(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_Recentre,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_Recentre(self, *_args, **_kwargs)
return val
def ClearPointList(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_ClearPointList,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_ClearPointList(self, *_args, **_kwargs)
return val
def GetBackgroundPen(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBackgroundPen,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBackgroundPen(self, *_args, **_kwargs)
if val: val = wxPenPtr(val) ; val.thisown = 1
return val
def GetBackgroundBrush(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_GetBackgroundBrush,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_GetBackgroundBrush(self, *_args, **_kwargs)
if val: val = wxBrushPtr(val) ; val.thisown = 1
return val
def base_OnDelete(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDelete,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDelete(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDraw,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnErase,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnHighlight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnRightClick,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnMovePre,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnMovePost,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDragRight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglbasicc.wxPyShape_base_OnEndSize,(self,) + _args, _kwargs)
val = oglbasicc.wxPyShape_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyShape instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyShape instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
def SetClientData(self, data):
self.clientData = data

View File

@@ -50,82 +50,82 @@ class wxDiagramPtr(wxObjectPtr):
self.this = this
self.thisown = 0
def AddShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_AddShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_AddShape(self, *_args, **_kwargs)
return val
def Clear(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_Clear,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_Clear(self, *_args, **_kwargs)
return val
def DeleteAllShapes(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_DeleteAllShapes,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_DeleteAllShapes(self, *_args, **_kwargs)
return val
def DrawOutline(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_DrawOutline,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_DrawOutline(self, *_args, **_kwargs)
return val
def FindShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_FindShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_FindShape(self, *_args, **_kwargs)
return val
def GetCanvas(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetCanvas,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetCanvas(self, *_args, **_kwargs)
return val
def GetCount(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetCount,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetCount(self, *_args, **_kwargs)
return val
def GetGridSpacing(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetGridSpacing,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetGridSpacing(self, *_args, **_kwargs)
return val
def GetMouseTolerance(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetMouseTolerance,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetMouseTolerance(self, *_args, **_kwargs)
return val
def GetShapeList(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetShapeList,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetShapeList(self, *_args, **_kwargs)
return val
def GetQuickEditMode(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetQuickEditMode,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetQuickEditMode(self, *_args, **_kwargs)
return val
def GetSnapToGrid(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_GetSnapToGrid,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_GetSnapToGrid(self, *_args, **_kwargs)
return val
def InsertShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_InsertShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_InsertShape(self, *_args, **_kwargs)
return val
def RecentreAll(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_RecentreAll,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_RecentreAll(self, *_args, **_kwargs)
return val
def Redraw(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_Redraw,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_Redraw(self, *_args, **_kwargs)
return val
def RemoveAllShapes(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_RemoveAllShapes,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_RemoveAllShapes(self, *_args, **_kwargs)
return val
def RemoveShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_RemoveShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_RemoveShape(self, *_args, **_kwargs)
return val
def SetCanvas(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_SetCanvas,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_SetCanvas(self, *_args, **_kwargs)
return val
def SetGridSpacing(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_SetGridSpacing,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_SetGridSpacing(self, *_args, **_kwargs)
return val
def SetMouseTolerance(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_SetMouseTolerance,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_SetMouseTolerance(self, *_args, **_kwargs)
return val
def SetQuickEditMode(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_SetQuickEditMode,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_SetQuickEditMode(self, *_args, **_kwargs)
return val
def SetSnapToGrid(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_SetSnapToGrid,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_SetSnapToGrid(self, *_args, **_kwargs)
return val
def ShowAll(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_ShowAll,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_ShowAll(self, *_args, **_kwargs)
return val
def Snap(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxDiagram_Snap,(self,) + _args, _kwargs)
val = oglcanvasc.wxDiagram_Snap(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxDiagram instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxDiagram instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxDiagram(wxDiagramPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglcanvasc.new_wxDiagram,_args,_kwargs)
self.this = oglcanvasc.new_wxDiagram(*_args,**_kwargs)
self.thisown = 1
@@ -136,71 +136,71 @@ class wxPyShapeCanvasPtr(wxScrolledWindowPtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas__setCallbackInfo,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas__setCallbackInfo(self, *_args, **_kwargs)
return val
def AddShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_AddShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_AddShape(self, *_args, **_kwargs)
return val
def FindShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_FindShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_FindShape(self, *_args, **_kwargs)
return val
def FindFirstSensitiveShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_FindFirstSensitiveShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_FindFirstSensitiveShape(self, *_args, **_kwargs)
return val
def GetDiagram(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_GetDiagram,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_GetDiagram(self, *_args, **_kwargs)
return val
def GetQuickEditMode(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_GetQuickEditMode,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_GetQuickEditMode(self, *_args, **_kwargs)
return val
def InsertShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_InsertShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_InsertShape(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnDragRight,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_base_OnRightClick,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_base_OnRightClick(self, *_args, **_kwargs)
return val
def Redraw(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_Redraw,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_Redraw(self, *_args, **_kwargs)
return val
def RemoveShape(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_RemoveShape,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_RemoveShape(self, *_args, **_kwargs)
return val
def SetDiagram(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_SetDiagram,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_SetDiagram(self, *_args, **_kwargs)
return val
def Snap(self, *_args, **_kwargs):
val = apply(oglcanvasc.wxPyShapeCanvas_Snap,(self,) + _args, _kwargs)
val = oglcanvasc.wxPyShapeCanvas_Snap(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyShapeCanvas instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyShapeCanvas instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
def GetShapeList(self):
return self.GetDiagram().GetShapeList()
class wxPyShapeCanvas(wxPyShapeCanvasPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglcanvasc.new_wxPyShapeCanvas,_args,_kwargs)
self.this = oglcanvasc.new_wxPyShapeCanvas(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyShapeCanvas)
self._setOORInfo(self)

View File

@@ -54,8 +54,7 @@
DEC_PYCALLBACK__WXCP2DBL2INT (OnSizingEndDragLeft); \
DEC_PYCALLBACK__2DBL (OnBeginSize); \
DEC_PYCALLBACK__2DBL (OnEndSize); \
\
PYPRIVATE;
PYPRIVATE
#define WXSHAPE_IMP_CALLBACKS(CLASS, PARENT) \
@@ -87,7 +86,7 @@
IMP_PYCALLBACK__WXCP2DBL2INT (CLASS, PARENT, OnSizingBeginDragLeft);\
IMP_PYCALLBACK__WXCP2DBL2INT (CLASS, PARENT, OnSizingEndDragLeft); \
IMP_PYCALLBACK__2DBL (CLASS, PARENT, OnBeginSize); \
IMP_PYCALLBACK__2DBL (CLASS, PARENT, OnEndSize); \
IMP_PYCALLBACK__2DBL (CLASS, PARENT, OnEndSize)
// This one may be difficult...

File diff suppressed because it is too large Load Diff

View File

@@ -52,97 +52,97 @@ class wxPyEllipseShapePtr(wxPyShapePtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape__setCallbackInfo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape__setCallbackInfo(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDraw,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnErase,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnHighlight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnRightClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnMovePre,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnMovePost,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyEllipseShape_base_OnEndSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyEllipseShape_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyEllipseShape instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyEllipseShape instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxPyEllipseShape(wxPyEllipseShapePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglshapes2c.new_wxPyEllipseShape,_args,_kwargs)
self.this = oglshapes2c.new_wxPyEllipseShape(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyEllipseShape)
self._setOORInfo(self)
@@ -155,97 +155,97 @@ class wxPyCircleShapePtr(wxPyEllipseShapePtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape__setCallbackInfo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape__setCallbackInfo(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDraw,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnErase,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnHighlight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnRightClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnMovePre,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnMovePost,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyCircleShape_base_OnEndSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyCircleShape_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyCircleShape instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyCircleShape instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxPyCircleShape(wxPyCircleShapePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglshapes2c.new_wxPyCircleShape,_args,_kwargs)
self.this = oglshapes2c.new_wxPyCircleShape(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyCircleShape)
self._setOORInfo(self)
@@ -264,58 +264,58 @@ class wxArrowHeadPtr(wxObjectPtr):
except:
pass
def _GetType(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead__GetType,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead__GetType(self, *_args, **_kwargs)
return val
def GetPosition(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetPosition,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetPosition(self, *_args, **_kwargs)
return val
def SetPosition(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_SetPosition,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_SetPosition(self, *_args, **_kwargs)
return val
def GetXOffset(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetXOffset,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetXOffset(self, *_args, **_kwargs)
return val
def GetYOffset(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetYOffset,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetYOffset(self, *_args, **_kwargs)
return val
def GetSpacing(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetSpacing,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetSpacing(self, *_args, **_kwargs)
return val
def GetSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetSize(self, *_args, **_kwargs)
return val
def GetName(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetName,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetName(self, *_args, **_kwargs)
return val
def SetXOffset(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_SetXOffset,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_SetXOffset(self, *_args, **_kwargs)
return val
def SetYOffset(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_SetYOffset,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_SetYOffset(self, *_args, **_kwargs)
return val
def GetMetaFile(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetMetaFile,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetMetaFile(self, *_args, **_kwargs)
return val
def GetId(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetId,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetId(self, *_args, **_kwargs)
return val
def GetArrowEnd(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetArrowEnd,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetArrowEnd(self, *_args, **_kwargs)
return val
def GetArrowSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_GetArrowSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_GetArrowSize(self, *_args, **_kwargs)
return val
def SetSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_SetSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_SetSize(self, *_args, **_kwargs)
return val
def SetSpacing(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxArrowHead_SetSpacing,(self,) + _args, _kwargs)
val = oglshapes2c.wxArrowHead_SetSpacing(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxArrowHead instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxArrowHead instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxArrowHead(wxArrowHeadPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglshapes2c.new_wxArrowHead,_args,_kwargs)
self.this = oglshapes2c.new_wxArrowHead(*_args,**_kwargs)
self.thisown = 1
@@ -326,218 +326,218 @@ class wxPyLineShapePtr(wxPyShapePtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape__setCallbackInfo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape__setCallbackInfo(self, *_args, **_kwargs)
return val
def AddArrow(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_AddArrow,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_AddArrow(self, *_args, **_kwargs)
return val
def AddArrowOrdered(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_AddArrowOrdered,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_AddArrowOrdered(self, *_args, **_kwargs)
return val
def ClearArrow(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_ClearArrow,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_ClearArrow(self, *_args, **_kwargs)
return val
def ClearArrowsAtPosition(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_ClearArrowsAtPosition,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_ClearArrowsAtPosition(self, *_args, **_kwargs)
return val
def DrawArrow(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_DrawArrow,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_DrawArrow(self, *_args, **_kwargs)
return val
def DeleteArrowHeadId(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_DeleteArrowHeadId,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_DeleteArrowHeadId(self, *_args, **_kwargs)
return val
def DeleteArrowHead(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_DeleteArrowHead,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_DeleteArrowHead(self, *_args, **_kwargs)
return val
def DeleteLineControlPoint(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_DeleteLineControlPoint,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_DeleteLineControlPoint(self, *_args, **_kwargs)
return val
def DrawArrows(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_DrawArrows,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_DrawArrows(self, *_args, **_kwargs)
return val
def DrawRegion(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_DrawRegion,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_DrawRegion(self, *_args, **_kwargs)
return val
def EraseRegion(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_EraseRegion,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_EraseRegion(self, *_args, **_kwargs)
return val
def FindArrowHeadId(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_FindArrowHeadId,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_FindArrowHeadId(self, *_args, **_kwargs)
return val
def FindArrowHead(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_FindArrowHead,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_FindArrowHead(self, *_args, **_kwargs)
return val
def FindLineEndPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_FindLineEndPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_FindLineEndPoints(self, *_args, **_kwargs)
return val
def FindLinePosition(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_FindLinePosition,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_FindLinePosition(self, *_args, **_kwargs)
return val
def FindMinimumWidth(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_FindMinimumWidth,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_FindMinimumWidth(self, *_args, **_kwargs)
return val
def FindNth(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_FindNth,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_FindNth(self, *_args, **_kwargs)
return val
def GetAttachmentFrom(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetAttachmentFrom,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetAttachmentFrom(self, *_args, **_kwargs)
return val
def GetAttachmentTo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetAttachmentTo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetAttachmentTo(self, *_args, **_kwargs)
return val
def GetEnds(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetEnds,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetEnds(self, *_args, **_kwargs)
return val
def GetFrom(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetFrom,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetFrom(self, *_args, **_kwargs)
return val
def GetLabelPosition(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetLabelPosition,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetLabelPosition(self, *_args, **_kwargs)
return val
def GetNextControlPoint(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetNextControlPoint,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetNextControlPoint(self, *_args, **_kwargs)
if val: val = wxRealPointPtr(val)
return val
def GetTo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetTo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetTo(self, *_args, **_kwargs)
return val
def Initialise(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_Initialise,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_Initialise(self, *_args, **_kwargs)
return val
def InsertLineControlPoint(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_InsertLineControlPoint,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_InsertLineControlPoint(self, *_args, **_kwargs)
return val
def IsEnd(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_IsEnd,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_IsEnd(self, *_args, **_kwargs)
return val
def IsSpline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_IsSpline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_IsSpline(self, *_args, **_kwargs)
return val
def MakeLineControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_MakeLineControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_MakeLineControlPoints(self, *_args, **_kwargs)
return val
def GetLineControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_GetLineControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_GetLineControlPoints(self, *_args, **_kwargs)
return val
def SetAttachmentFrom(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetAttachmentFrom,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetAttachmentFrom(self, *_args, **_kwargs)
return val
def SetAttachments(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetAttachments,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetAttachments(self, *_args, **_kwargs)
return val
def SetAttachmentTo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetAttachmentTo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetAttachmentTo(self, *_args, **_kwargs)
return val
def SetEnds(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetEnds,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetEnds(self, *_args, **_kwargs)
return val
def SetFrom(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetFrom,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetFrom(self, *_args, **_kwargs)
return val
def SetIgnoreOffsets(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetIgnoreOffsets,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetIgnoreOffsets(self, *_args, **_kwargs)
return val
def SetSpline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetSpline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetSpline(self, *_args, **_kwargs)
return val
def SetTo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_SetTo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_SetTo(self, *_args, **_kwargs)
return val
def Straighten(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_Straighten,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_Straighten(self, *_args, **_kwargs)
return val
def Unlink(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_Unlink,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_Unlink(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDraw,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnErase,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnHighlight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnRightClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnMovePre,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnMovePost,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyLineShape_base_OnEndSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyLineShape_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyLineShape instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyLineShape instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxPyLineShape(wxPyLineShapePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglshapes2c.new_wxPyLineShape,_args,_kwargs)
self.this = oglshapes2c.new_wxPyLineShape(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyLineShape)
self._setOORInfo(self)
@@ -550,115 +550,115 @@ class wxPyPolygonShapePtr(wxPyShapePtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape__setCallbackInfo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape__setCallbackInfo(self, *_args, **_kwargs)
return val
def Create(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_Create,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_Create(self, *_args, **_kwargs)
return val
def AddPolygonPoint(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_AddPolygonPoint,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_AddPolygonPoint(self, *_args, **_kwargs)
return val
def CalculatePolygonCentre(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_CalculatePolygonCentre,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_CalculatePolygonCentre(self, *_args, **_kwargs)
return val
def DeletePolygonPoint(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_DeletePolygonPoint,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_DeletePolygonPoint(self, *_args, **_kwargs)
return val
def GetPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_GetPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_GetPoints(self, *_args, **_kwargs)
return val
def UpdateOriginalPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_UpdateOriginalPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_UpdateOriginalPoints(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDraw,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnErase,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnHighlight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnRightClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnMovePre,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnMovePost,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyPolygonShape_base_OnEndSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyPolygonShape_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyPolygonShape instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyPolygonShape instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxPyPolygonShape(wxPyPolygonShapePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglshapes2c.new_wxPyPolygonShape,_args,_kwargs)
self.this = oglshapes2c.new_wxPyPolygonShape(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyPolygonShape)
self._setOORInfo(self)
@@ -671,100 +671,100 @@ class wxPyTextShapePtr(wxPyRectangleShapePtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape__setCallbackInfo,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape__setCallbackInfo(self, *_args, **_kwargs)
return val
def base_OnDelete(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDelete,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDelete(self, *_args, **_kwargs)
return val
def base_OnDraw(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDraw,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDraw(self, *_args, **_kwargs)
return val
def base_OnDrawContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDrawContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDrawContents(self, *_args, **_kwargs)
return val
def base_OnDrawBranches(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDrawBranches,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDrawBranches(self, *_args, **_kwargs)
return val
def base_OnMoveLinks(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnMoveLinks,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnMoveLinks(self, *_args, **_kwargs)
return val
def base_OnErase(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnErase,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnErase(self, *_args, **_kwargs)
return val
def base_OnEraseContents(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnEraseContents,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnEraseContents(self, *_args, **_kwargs)
return val
def base_OnHighlight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnHighlight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnHighlight(self, *_args, **_kwargs)
return val
def base_OnLeftClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnLeftClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnLeftClick(self, *_args, **_kwargs)
return val
def base_OnLeftDoubleClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnLeftDoubleClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnLeftDoubleClick(self, *_args, **_kwargs)
return val
def base_OnRightClick(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnRightClick,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnRightClick(self, *_args, **_kwargs)
return val
def base_OnSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnSize(self, *_args, **_kwargs)
return val
def base_OnMovePre(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnMovePre,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnMovePre(self, *_args, **_kwargs)
return val
def base_OnMovePost(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnMovePost,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnMovePost(self, *_args, **_kwargs)
return val
def base_OnDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDragRight(self, *_args, **_kwargs)
return val
def base_OnBeginDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnBeginDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnBeginDragRight(self, *_args, **_kwargs)
return val
def base_OnEndDragRight(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnEndDragRight,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnEndDragRight(self, *_args, **_kwargs)
return val
def base_OnDrawOutline(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDrawOutline,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDrawOutline(self, *_args, **_kwargs)
return val
def base_OnDrawControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnDrawControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnDrawControlPoints(self, *_args, **_kwargs)
return val
def base_OnEraseControlPoints(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnEraseControlPoints,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnEraseControlPoints(self, *_args, **_kwargs)
return val
def base_OnMoveLink(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnMoveLink,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnMoveLink(self, *_args, **_kwargs)
return val
def base_OnSizingDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnSizingDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnSizingDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingBeginDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnSizingBeginDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnSizingBeginDragLeft(self, *_args, **_kwargs)
return val
def base_OnSizingEndDragLeft(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnSizingEndDragLeft,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnSizingEndDragLeft(self, *_args, **_kwargs)
return val
def base_OnBeginSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnBeginSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnBeginSize(self, *_args, **_kwargs)
return val
def base_OnEndSize(self, *_args, **_kwargs):
val = apply(oglshapes2c.wxPyTextShape_base_OnEndSize,(self,) + _args, _kwargs)
val = oglshapes2c.wxPyTextShape_base_OnEndSize(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxPyTextShape instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxPyTextShape instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxPyTextShape(wxPyTextShapePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(oglshapes2c.new_wxPyTextShape,_args,_kwargs)
self.this = oglshapes2c.new_wxPyTextShape(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxPyTextShape)
self._setOORInfo(self)

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -114,6 +114,14 @@ def EVT_STC_DO_DROP(win, id, func):
def EVT_STC_ZOOM(win, id, func):
win.Connect(id, -1, wxEVT_STC_ZOOM, func)
def EVT_STC_HOTSPOT_CLICK(win, id, func):
win.Connect(id, -1, wxEVT_STC_HOTSPOT_CLICK, func)
def EVT_STC_HOTSPOT_DCLICK(win, id, func):
win.Connect(id, -1, wxEVT_STC_HOTSPOT_DCLICK, func)
def EVT_STC_CALLTIP_CLICK(win, id, func):
win.Connect(id, -1, wxEVT_STC_CALLTIP_CLICK, func)
"
//----------------------------------------------------------------------

View File

@@ -63,96 +63,96 @@ class wxXmlResourcePtr(wxObjectPtr):
except:
pass
def Load(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_Load,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_Load(self, *_args, **_kwargs)
return val
def LoadFromString(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadFromString,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadFromString(self, *_args, **_kwargs)
return val
def InitAllHandlers(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_InitAllHandlers,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_InitAllHandlers(self, *_args, **_kwargs)
return val
def AddHandler(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_AddHandler,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_AddHandler(self, *_args, **_kwargs)
return val
def InsertHandler(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_InsertHandler,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_InsertHandler(self, *_args, **_kwargs)
return val
def ClearHandlers(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_ClearHandlers,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_ClearHandlers(self, *_args, **_kwargs)
return val
def LoadMenu(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadMenu,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadMenu(self, *_args, **_kwargs)
return val
def LoadMenuBar(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadMenuBar,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadMenuBar(self, *_args, **_kwargs)
return val
def LoadMenuBarOnFrame(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadMenuBarOnFrame,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadMenuBarOnFrame(self, *_args, **_kwargs)
return val
def LoadToolBar(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadToolBar,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadToolBar(self, *_args, **_kwargs)
return val
def LoadDialog(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadDialog,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadDialog(self, *_args, **_kwargs)
if val: val = wxDialogPtr(val)
return val
def LoadOnDialog(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadOnDialog,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadOnDialog(self, *_args, **_kwargs)
return val
def LoadPanel(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadPanel,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadPanel(self, *_args, **_kwargs)
if val: val = wxPanelPtr(val)
return val
def LoadOnPanel(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadOnPanel,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadOnPanel(self, *_args, **_kwargs)
return val
def LoadFrame(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadFrame,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadFrame(self, *_args, **_kwargs)
return val
def LoadOnFrame(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadOnFrame,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadOnFrame(self, *_args, **_kwargs)
return val
def LoadObject(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadObject,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadObject(self, *_args, **_kwargs)
return val
def LoadOnObject(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadOnObject,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadOnObject(self, *_args, **_kwargs)
return val
def LoadBitmap(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadBitmap,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadBitmap(self, *_args, **_kwargs)
if val: val = wxBitmapPtr(val) ; val.thisown = 1
return val
def LoadIcon(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_LoadIcon,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_LoadIcon(self, *_args, **_kwargs)
if val: val = wxIconPtr(val) ; val.thisown = 1
return val
def AttachUnknownControl(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_AttachUnknownControl,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_AttachUnknownControl(self, *_args, **_kwargs)
return val
def GetVersion(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_GetVersion,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_GetVersion(self, *_args, **_kwargs)
return val
def CompareVersion(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_CompareVersion,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_CompareVersion(self, *_args, **_kwargs)
return val
def GetFlags(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_GetFlags,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_GetFlags(self, *_args, **_kwargs)
return val
def SetFlags(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResource_SetFlags,(self,) + _args, _kwargs)
val = xrcc.wxXmlResource_SetFlags(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxXmlResource instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxXmlResource instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxXmlResource(wxXmlResourcePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(xrcc.new_wxXmlResource,_args,_kwargs)
self.this = xrcc.new_wxXmlResource(*_args,**_kwargs)
self.thisown = 1
self.InitAllHandlers()
def wxEmptyXmlResource(*_args,**_kwargs):
val = wxXmlResourcePtr(apply(xrcc.new_wxEmptyXmlResource,_args,_kwargs))
val = wxXmlResourcePtr(xrcc.new_wxEmptyXmlResource(*_args,**_kwargs))
val.thisown = 1
val.InitAllHandlers()
return val
@@ -163,13 +163,13 @@ class wxXmlSubclassFactoryPtr :
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlSubclassFactory__setCallbackInfo,(self,) + _args, _kwargs)
val = xrcc.wxXmlSubclassFactory__setCallbackInfo(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxXmlSubclassFactory instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxXmlSubclassFactory instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxXmlSubclassFactory(wxXmlSubclassFactoryPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(xrcc.new_wxXmlSubclassFactory,_args,_kwargs)
self.this = xrcc.new_wxXmlSubclassFactory(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxXmlSubclassFactory)
@@ -181,29 +181,29 @@ class wxXmlPropertyPtr :
self.this = this
self.thisown = 0
def GetName(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlProperty_GetName,(self,) + _args, _kwargs)
val = xrcc.wxXmlProperty_GetName(self, *_args, **_kwargs)
return val
def GetValue(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlProperty_GetValue,(self,) + _args, _kwargs)
val = xrcc.wxXmlProperty_GetValue(self, *_args, **_kwargs)
return val
def GetNext(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlProperty_GetNext,(self,) + _args, _kwargs)
val = xrcc.wxXmlProperty_GetNext(self, *_args, **_kwargs)
if val: val = wxXmlPropertyPtr(val)
return val
def SetName(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlProperty_SetName,(self,) + _args, _kwargs)
val = xrcc.wxXmlProperty_SetName(self, *_args, **_kwargs)
return val
def SetValue(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlProperty_SetValue,(self,) + _args, _kwargs)
val = xrcc.wxXmlProperty_SetValue(self, *_args, **_kwargs)
return val
def SetNext(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlProperty_SetNext,(self,) + _args, _kwargs)
val = xrcc.wxXmlProperty_SetNext(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxXmlProperty instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxXmlProperty instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxXmlProperty(wxXmlPropertyPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(xrcc.new_wxXmlProperty,_args,_kwargs)
self.this = xrcc.new_wxXmlProperty(*_args,**_kwargs)
self.thisown = 1
@@ -220,86 +220,86 @@ class wxXmlNodePtr :
except:
pass
def AddChild(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_AddChild,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_AddChild(self, *_args, **_kwargs)
return val
def InsertChild(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_InsertChild,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_InsertChild(self, *_args, **_kwargs)
return val
def RemoveChild(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_RemoveChild,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_RemoveChild(self, *_args, **_kwargs)
return val
def AddProperty(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_AddProperty,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_AddProperty(self, *_args, **_kwargs)
return val
def AddPropertyName(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_AddPropertyName,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_AddPropertyName(self, *_args, **_kwargs)
return val
def DeleteProperty(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_DeleteProperty,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_DeleteProperty(self, *_args, **_kwargs)
return val
def GetType(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetType,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetType(self, *_args, **_kwargs)
return val
def GetName(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetName,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetName(self, *_args, **_kwargs)
return val
def GetContent(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetContent,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetContent(self, *_args, **_kwargs)
return val
def GetParent(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetParent,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetParent(self, *_args, **_kwargs)
if val: val = wxXmlNodePtr(val)
return val
def GetNext(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetNext,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetNext(self, *_args, **_kwargs)
if val: val = wxXmlNodePtr(val)
return val
def GetChildren(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetChildren,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetChildren(self, *_args, **_kwargs)
if val: val = wxXmlNodePtr(val)
return val
def GetProperties(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetProperties,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetProperties(self, *_args, **_kwargs)
if val: val = wxXmlPropertyPtr(val)
return val
def GetPropVal(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_GetPropVal,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_GetPropVal(self, *_args, **_kwargs)
return val
def HasProp(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_HasProp,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_HasProp(self, *_args, **_kwargs)
return val
def SetType(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetType,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetType(self, *_args, **_kwargs)
return val
def SetName(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetName,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetName(self, *_args, **_kwargs)
return val
def SetContent(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetContent,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetContent(self, *_args, **_kwargs)
return val
def SetParent(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetParent,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetParent(self, *_args, **_kwargs)
return val
def SetNext(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetNext,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetNext(self, *_args, **_kwargs)
return val
def SetChildren(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetChildren,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetChildren(self, *_args, **_kwargs)
return val
def SetProperties(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlNode_SetProperties,(self,) + _args, _kwargs)
val = xrcc.wxXmlNode_SetProperties(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxXmlNode instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxXmlNode instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxXmlNode(wxXmlNodePtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(xrcc.new_wxXmlNode,_args,_kwargs)
self.this = xrcc.new_wxXmlNode(*_args,**_kwargs)
self.thisown = 1
def wxXmlNodeEasy(*_args,**_kwargs):
val = wxXmlNodePtr(apply(xrcc.new_wxXmlNodeEasy,_args,_kwargs))
val = wxXmlNodePtr(xrcc.new_wxXmlNodeEasy(*_args,**_kwargs))
val.thisown = 1
return val
@@ -315,61 +315,61 @@ class wxXmlDocumentPtr(wxObjectPtr):
except:
pass
def Load(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_Load,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_Load(self, *_args, **_kwargs)
return val
def LoadFromStream(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_LoadFromStream,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_LoadFromStream(self, *_args, **_kwargs)
return val
def Save(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_Save,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_Save(self, *_args, **_kwargs)
return val
def SaveToStream(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_SaveToStream,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_SaveToStream(self, *_args, **_kwargs)
return val
def IsOk(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_IsOk,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_IsOk(self, *_args, **_kwargs)
return val
def GetRoot(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_GetRoot,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_GetRoot(self, *_args, **_kwargs)
if val: val = wxXmlNodePtr(val)
return val
def GetVersion(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_GetVersion,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_GetVersion(self, *_args, **_kwargs)
return val
def GetFileEncoding(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_GetFileEncoding,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_GetFileEncoding(self, *_args, **_kwargs)
return val
def SetRoot(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_SetRoot,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_SetRoot(self, *_args, **_kwargs)
return val
def SetVersion(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_SetVersion,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_SetVersion(self, *_args, **_kwargs)
return val
def SetFileEncoding(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_SetFileEncoding,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_SetFileEncoding(self, *_args, **_kwargs)
return val
def GetEncoding(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_GetEncoding,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_GetEncoding(self, *_args, **_kwargs)
return val
def SetEncoding(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlDocument_SetEncoding,(self,) + _args, _kwargs)
val = xrcc.wxXmlDocument_SetEncoding(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxXmlDocument instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxXmlDocument instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxXmlDocument(wxXmlDocumentPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(xrcc.new_wxXmlDocument,_args,_kwargs)
self.this = xrcc.new_wxXmlDocument(*_args,**_kwargs)
self.thisown = 1
def wxXmlDocumentFromStream(*_args,**_kwargs):
val = wxXmlDocumentPtr(apply(xrcc.new_wxXmlDocumentFromStream,_args,_kwargs))
val = wxXmlDocumentPtr(xrcc.new_wxXmlDocumentFromStream(*_args,**_kwargs))
val.thisown = 1
return val
def wxEmptyXmlDocument(*_args,**_kwargs):
val = wxXmlDocumentPtr(apply(xrcc.new_wxEmptyXmlDocument,_args,_kwargs))
val = wxXmlDocumentPtr(xrcc.new_wxEmptyXmlDocument(*_args,**_kwargs))
val.thisown = 1
return val
@@ -379,124 +379,124 @@ class wxXmlResourceHandlerPtr(wxObjectPtr):
self.this = this
self.thisown = 0
def _setCallbackInfo(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler__setCallbackInfo,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler__setCallbackInfo(self, *_args, **_kwargs)
return val
def CreateResource(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_CreateResource,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_CreateResource(self, *_args, **_kwargs)
return val
def SetParentResource(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_SetParentResource,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_SetParentResource(self, *_args, **_kwargs)
return val
def GetResource(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetResource,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetResource(self, *_args, **_kwargs)
if val: val = wxXmlResourcePtr(val)
return val
def GetNode(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetNode,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetNode(self, *_args, **_kwargs)
if val: val = wxXmlNodePtr(val)
return val
def GetClass(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetClass,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetClass(self, *_args, **_kwargs)
return val
def GetParent(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetParent,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetParent(self, *_args, **_kwargs)
return val
def GetInstance(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetInstance,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetInstance(self, *_args, **_kwargs)
return val
def GetParentAsWindow(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetParentAsWindow,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetParentAsWindow(self, *_args, **_kwargs)
return val
def GetInstanceAsWindow(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetInstanceAsWindow,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetInstanceAsWindow(self, *_args, **_kwargs)
return val
def IsOfClass(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_IsOfClass,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_IsOfClass(self, *_args, **_kwargs)
return val
def GetNodeContent(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetNodeContent,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetNodeContent(self, *_args, **_kwargs)
return val
def HasParam(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_HasParam,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_HasParam(self, *_args, **_kwargs)
return val
def GetParamNode(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetParamNode,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetParamNode(self, *_args, **_kwargs)
if val: val = wxXmlNodePtr(val)
return val
def GetParamValue(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetParamValue,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetParamValue(self, *_args, **_kwargs)
return val
def AddStyle(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_AddStyle,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_AddStyle(self, *_args, **_kwargs)
return val
def AddWindowStyles(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_AddWindowStyles,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_AddWindowStyles(self, *_args, **_kwargs)
return val
def GetStyle(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetStyle,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetStyle(self, *_args, **_kwargs)
return val
def GetText(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetText,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetText(self, *_args, **_kwargs)
return val
def GetID(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetID,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetID(self, *_args, **_kwargs)
return val
def GetName(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetName,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetName(self, *_args, **_kwargs)
return val
def GetBool(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetBool,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetBool(self, *_args, **_kwargs)
return val
def GetLong(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetLong,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetLong(self, *_args, **_kwargs)
return val
def GetColour(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetColour,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetColour(self, *_args, **_kwargs)
if val: val = wxColourPtr(val) ; val.thisown = 1
return val
def GetSize(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetSize,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetSize(self, *_args, **_kwargs)
if val: val = wxSizePtr(val) ; val.thisown = 1
return val
def GetPosition(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetPosition,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetPosition(self, *_args, **_kwargs)
if val: val = wxPointPtr(val) ; val.thisown = 1
return val
def GetDimension(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetDimension,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetDimension(self, *_args, **_kwargs)
return val
def GetBitmap(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetBitmap,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetBitmap(self, *_args, **_kwargs)
if val: val = wxBitmapPtr(val) ; val.thisown = 1
return val
def GetIcon(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetIcon,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetIcon(self, *_args, **_kwargs)
if val: val = wxIconPtr(val) ; val.thisown = 1
return val
def GetFont(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetFont,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetFont(self, *_args, **_kwargs)
if val: val = wxFontPtr(val) ; val.thisown = 1
return val
def SetupWindow(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_SetupWindow,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_SetupWindow(self, *_args, **_kwargs)
return val
def CreateChildren(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_CreateChildren,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_CreateChildren(self, *_args, **_kwargs)
return val
def CreateChildrenPrivately(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_CreateChildrenPrivately,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_CreateChildrenPrivately(self, *_args, **_kwargs)
return val
def CreateResFromNode(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_CreateResFromNode,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_CreateResFromNode(self, *_args, **_kwargs)
return val
def GetCurFileSystem(self, *_args, **_kwargs):
val = apply(xrcc.wxXmlResourceHandler_GetCurFileSystem,(self,) + _args, _kwargs)
val = xrcc.wxXmlResourceHandler_GetCurFileSystem(self, *_args, **_kwargs)
return val
def __repr__(self):
return "<C wxXmlResourceHandler instance at %s>" % (self.this,)
return "<%s.%s instance; proxy of C++ wxXmlResourceHandler instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
class wxXmlResourceHandler(wxXmlResourceHandlerPtr):
def __init__(self,*_args,**_kwargs):
self.this = apply(xrcc.new_wxXmlResourceHandler,_args,_kwargs)
self.this = xrcc.new_wxXmlResourceHandler(*_args,**_kwargs)
self.thisown = 1
self._setCallbackInfo(self, wxXmlResourceHandler)
@@ -512,12 +512,12 @@ wxXmlResource_AddSubclassFactory = xrcc.wxXmlResource_AddSubclassFactory
wxXmlResource_GetXRCID = xrcc.wxXmlResource_GetXRCID
def wxXmlResource_Get(*_args, **_kwargs):
val = apply(xrcc.wxXmlResource_Get,_args,_kwargs)
val = xrcc.wxXmlResource_Get(*_args,**_kwargs)
if val: val = wxXmlResourcePtr(val)
return val
def wxXmlResource_Set(*_args, **_kwargs):
val = apply(xrcc.wxXmlResource_Set,_args,_kwargs)
val = xrcc.wxXmlResource_Set(*_args,**_kwargs)
if val: val = wxXmlResourcePtr(val)
return val

View File

@@ -1,12 +1,12 @@
import sys
from wxPython.wx import *
from wxPython.html import *
import wxPython.lib.wxpTag
import wx # This module uses the new wx namespace
import wx.html
import wx.lib.wxpTag
#---------------------------------------------------------------------------
class MyAboutBox(wxDialog):
class MyAboutBox(wx.Dialog):
text = '''
<html>
<body bgcolor="#AC76DE">
@@ -29,36 +29,40 @@ sit back and enjoy. Be sure to take a peek at the source code for each
demo item so you can learn how to use the classes yourself.</p>
<p><b>wxPython</b> is brought to you by <b>Robin Dunn</b> and<br>
<b>Total Control Software,</b> Copyright (c) 1997-2002.</p>
<b>Total Control Software,</b> Copyright (c) 1997-2003.</p>
<p>
<font size="-1">Please see <i>license.txt</i> for licensing information.</font>
</p>
<p><wxp class="wxButton">
<p><wxp module="wx" class="Button">
<param name="label" value="Okay">
<param name="id" value="wxID_OK">
<param name="id" value="ID_OK">
</wxp></p>
</center>
</body>
</html>
'''
def __init__(self, parent):
wxDialog.__init__(self, parent, -1, 'About the wxPython demo',)
html = wxHtmlWindow(self, -1, size=(420, -1))
wx.Dialog.__init__(self, parent, -1, 'About the wxPython demo',)
html = wx.html.HtmlWindow(self, -1, size=(420, -1))
py_version = sys.version.split()[0]
html.SetPage(self.text % (wx.__version__, py_version))
btn = html.FindWindowById(wxID_OK)
html.SetPage(self.text % (wx.VERSION_STRING, py_version))
btn = html.FindWindowById(wx.ID_OK)
btn.SetDefault()
ir = html.GetInternalRepresentation()
html.SetSize( (ir.GetWidth()+25, ir.GetHeight()+25) )
self.SetClientSize(html.GetSize())
self.CentreOnParent(wxBOTH)
self.CentreOnParent(wx.BOTH)
#---------------------------------------------------------------------------
if __name__ == '__main__':
app = wx.PySimpleApp()
dlg = MyAboutBox(None)
dlg.ShowModal()
dlg.Destroy()
app.MainLoop()

View File

@@ -0,0 +1,79 @@
from wxPython.wx import *
from wxPython.lib.analogclock import AnalogClockWindow
#----------------------------------------------------------------------
class TestPanel(wxPanel):
def __init__(self, parent, log):
self.log = log
wxPanel.__init__(self, parent, -1)
c1 = AnalogClockWindow(self)
c1.SetBackgroundColour("RED")
c1.SetHandsColour("BLUE")
c1.SetTickMarkColours("WHITE")
c2 = AnalogClockWindow(self)
c2.SetBackgroundColour("WHITE")
c2.SetHandsColour("RED")
c2.SetTickMarkColours("BLUE")
c3 = AnalogClockWindow(self)
c3.SetBackgroundColour("BLUE")
c3.SetHandsColour("WHITE")
c3.SetTickMarkColours("RED")
c4 = AnalogClockWindow(self, style=wxRAISED_BORDER)
c4.SetTickMarkStyle(AnalogClockWindow.TICKS_CIRCLE)
c5 = AnalogClockWindow(self)
c5.SetTickMarkStyle(AnalogClockWindow.TICKS_NONE)
c6 = AnalogClockWindow(self, style=wxSUNKEN_BORDER)
# layout the clocks in a grid
gs = wxGridSizer(2, 3, 4, 4)
gs.Add(c1, 0, wxEXPAND)
gs.Add(c2, 0, wxEXPAND)
gs.Add(c3, 0, wxEXPAND)
gs.Add(c4, 0, wxEXPAND)
gs.Add(c5, 0, wxEXPAND)
gs.Add(c6, 0, wxEXPAND)
# put it in another sizer for a border
sizer = wxBoxSizer(wxVERTICAL)
sizer.Add(gs, 1, wxEXPAND|wxALL, 10)
self.SetSizer(sizer)
#----------------------------------------------------------------------
def runTest(frame, nb, log):
win = TestPanel(nb, log)
return win
#----------------------------------------------------------------------
overview = """<html><body>
<h2><center>AnalogClockWindow</center></h2>
This is a nice little clock class that was contributed to by several
members of the wxPython-users group.
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -127,3 +127,10 @@ def runTest(frame, nb, log):
overview = """
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -90,3 +90,10 @@ help into your applicaiton using the wxSimpleHelpProvider class.
#----------------------------------------------------------------------
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -206,11 +206,38 @@ def runTest(frame, nb, log):
overview = """\
This demo shows some examples of data transfer through clipboard or drag and drop. In wxWindows, these two ways to transfer data (either between different applications or inside one and the same) are very similar which allows to implement both of them using almost the same code - or, in other words, if you implement drag and drop support for your application, you get clipboard support for free and vice versa.
At the heart of both clipboard and drag and drop operations lies the wxDataObject class. The objects of this class (or, to be precise, classes derived from it) represent the data which is being carried by the mouse during drag and drop operation or copied to or pasted from the clipboard. wxDataObject is a "smart" piece of data because it knows which formats it supports (see GetFormatCount and GetAllFormats) and knows how to render itself in any of them (see GetDataHere). It can also receive its value from the outside in a format it supports if it implements the SetData method. Please see the documentation of this class for more details.
Both clipboard and drag and drop operations have two sides: the source and target, the data provider and the data receiver. These which may be in the same application and even the same window when, for example, you drag some text from one position to another in a word processor. Let us describe what each of them should do.
overview = """<html><body>\
This demo shows some examples of data transfer through clipboard or
drag and drop. In wxWindows, these two ways to transfer data (either
between different applications or inside one and the same) are very
similar which allows to implement both of them using almost the same
code - or, in other words, if you implement drag and drop support for
your application, you get clipboard support for free and vice versa.
<p>
At the heart of both clipboard and drag and drop operations lies the
wxDataObject class. The objects of this class (or, to be precise,
classes derived from it) represent the data which is being carried by
the mouse during drag and drop operation or copied to or pasted from
the clipboard. wxDataObject is a "smart" piece of data because it
knows which formats it supports (see GetFormatCount and GetAllFormats)
and knows how to render itself in any of them (see GetDataHere). It
can also receive its value from the outside in a format it supports if
it implements the SetData method. Please see the documentation of this
class for more details.
<p>
Both clipboard and drag and drop operations have two sides: the source
and target, the data provider and the data receiver. These which may
be in the same application and even the same window when, for example,
you drag some text from one position to another in a word
processor. Let us describe what each of them should do.
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -38,3 +38,11 @@ def runTest(frame, nb, log):
overview = fancytext.__doc__.replace("<", "&lt;")
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -74,3 +74,12 @@ overview = """<html><body>
""" % ( FileBrowseButton.__doc__,
FileBrowseButtonWithHistory.__doc__ ,
str(DirBrowseButton.__doc__) )
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -24,7 +24,7 @@ class TestPanel(wxPanel):
row = wxBoxSizer(wxHORIZONTAL)
row.Add(s1, 0, wxALL, 5)
row.Add(self.lb1, 0, wxALL, 5)
row.Add(self.txt, 0, wxALL, 5)
row.Add(self.txt, 0, wxALL|wxADJUST_MINSIZE, 5)
sizer = wxBoxSizer(wxVERTICAL)
sizer.Add(row, 0, wxALL, 30)
@@ -32,13 +32,27 @@ class TestPanel(wxPanel):
self.Layout()
self.lb1.SetSelection(0)
self.OnSelect(None)
wxFutureCall(300, self.SetTextSize)
def SetTextSize(self):
self.txt.SetSize(self.txt.GetBestSize())
def OnSelect(self, evt):
#print "OnSelect: "
face = self.lb1.GetStringSelection()
#print '\t '+face
font = wxFont(28, wxDEFAULT, wxNORMAL, wxNORMAL, False, face)
#print "\t got font"
self.txt.SetLabel(face)
#print "\t set label"
self.txt.SetFont(font)
self.txt.SetSize(self.txt.GetBestSize())
#print "\t set font"
#self.txt.SetSize(self.txt.GetBestSize())
#print "\t set size"
## st = font.GetNativeFontInfo().ToString()
## ni2 = wxNativeFontInfo()

View File

@@ -0,0 +1,104 @@
"""
Example showing how to make a grid a drop target for files.
"""
from wxPython.wx import *
from wxPython.grid import *
#---------------------------------------------------------------------------
# Set VIRTUAL to 1 to use a virtual grid
VIRTUAL = 1
class GridFileDropTarget(wxFileDropTarget):
def __init__(self, grid):
wxFileDropTarget.__init__(self)
self.grid = grid
def OnDropFiles(self, x, y, filenames):
# the x,y coordinates here are Unscrolled coordinates. They must be changed
# to scrolled coordinates.
x, y = self.grid.CalcUnscrolledPosition(x, y)
# now we need to get the row and column from the grid
# but we need to first remove the RowLabel and ColumnLabel
# bounding boxes
# Why this isn't done for us, I'll never know...
x = x - self.grid.GetGridRowLabelWindow().GetRect().width
y = y - self.grid.GetGridColLabelWindow().GetRect().height
col = self.grid.XToCol(x)
row = self.grid.YToRow(y)
if row > -1 and col > -1:
self.grid.SetCellValue(row, col, filenames[0])
self.grid.AutoSizeColumn(col)
self.grid.Refresh()
class FooTable(wxPyGridTableBase):
def __init__(self):
wxPyGridTableBase.__init__(self)
self.dropTargets = {(0,0):"Drag",
(1,0):"A",
(2,0):"File",
(3,0):"To",
(4,0):"A",
(5,0):"Cell"}
def GetNumberCols(self):
return 100
def GetNumberRows(self):
return 100
def GetValue(self, row, col):
return self.dropTargets.get((row, col), "")
class SimpleGrid(wxGrid):
def __init__(self, parent, log):
wxGrid.__init__(self, parent, -1)
self.log = log
self.moveTo = None
if VIRTUAL:
self.table = FooTable()
self.SetTable(self.table)
else:
self.CreateGrid(25, 25)
# set the drag and drop target
dropTarget = GridFileDropTarget(self)
self.SetDropTarget(dropTarget)
self.EnableDragRowSize()
self.EnableDragColSize()
def SetCellValue(self, row, col, value):
if VIRTUAL:
self.table.dropTargets[row, col] = value
else:
wxGrid.SetCellValue(self, row, col, value)
class TestFrame(wxFrame):
def __init__(self, parent, log):
wxFrame.__init__(self, parent, -1, "DragAndDrop Grid", size=(640,480))
grid = SimpleGrid(self, log)
#---------------------------------------------------------------------------
if __name__ == '__main__':
import sys
app = wxPySimpleApp()
frame = TestFrame(None, sys.stdout)
frame.Show(True)
app.MainLoop()
#---------------------------------------------------------------------------

View File

@@ -64,6 +64,11 @@ class SimpleGrid(wxGrid): ##, wxGridAutoEditMixin):
self.SetCellValue(11, 1, "This cell is set to span 3 rows and 3 columns");
editor = wxGridCellTextEditor()
editor.SetParameters('10')
self.SetCellEditor(0, 4, editor)
self.SetCellValue(0, 4, "Limited text")
# test all the events
EVT_GRID_CELL_LEFT_CLICK(self, self.OnCellLeftClick)

View File

@@ -38,3 +38,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -136,5 +136,8 @@ overview = """<html><body>
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -60,3 +60,12 @@ def runTest(frame, nb, log):
overview = Layoutf.__doc__
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -12,10 +12,9 @@
#----------------------------------------------------------------------------
import sys, os, time
from wxPython.wx import *
from wxPython.html import wxHtmlWindow
##from wxPython.stc import *
import wx # This module uses the new wx namespace
import wx.html
import images
@@ -26,9 +25,14 @@ import images
_treeList = [
# new stuff
('Recent Additions', [
'wxIntCtrl',
'wxPyColourChooser',
'wxScrolledPanel',
'ShapedWindow',
'NewNamespace',
'PopupMenu',
'AnalogClockWindow',
'MaskedEditControls',
'wxTreeListCtrl',
'wxGrid_MegaExample',
]),
# managed windows == things with a (optional) caption you can close
@@ -45,6 +49,7 @@ _treeList = [
'wxColourDialog',
'wxDirDialog',
'wxFileDialog',
'wxFileDialog_Save',
'wxFindReplaceDialog',
'wxFontDialog',
'wxMessageDialog',
@@ -65,6 +70,7 @@ _treeList = [
# core controls
('Core Windows/Controls', [
'PopupMenu',
'wxButton',
'wxCheckBox',
'wxCheckListBox',
@@ -73,6 +79,7 @@ _treeList = [
'wxGauge',
'wxGenericDirCtrl',
'wxGrid',
'wxGrid_MegaExample',
'wxListBox',
'wxListCtrl',
'wxListCtrl_virtual',
@@ -102,13 +109,15 @@ _treeList = [
#'wxFloatBar', deprecated
#'wxMVCTree', deprecated
#'wxRightTextCtrl', deprecated as we have wxTE_RIGHT now.
'AnalogClockWindow',
'ColourSelect',
'ContextHelp',
'FancyText',
'FileBrowseButton',
'GenericButtons',
'MaskedEditControls',
'PyShell',
'PyCrust',
'PyCrustWithFilling',
'SplitTree',
'TablePrint',
'Throbber',
@@ -128,6 +137,7 @@ _treeList = [
'wxStyledTextCtrl_1',
'wxStyledTextCtrl_2',
'wxTimeCtrl',
'wxTreeListCtrl',
]),
# How to lay out the controls in a frame/dialog
@@ -204,9 +214,9 @@ _treeList = [
#---------------------------------------------------------------------------
class MyLog(wxPyLog):
class MyLog(wx.PyLog):
def __init__(self, textCtrl, logTime=0):
wxPyLog.__init__(self)
wx.PyLog.__init__(self)
self.tc = textCtrl
self.logTime = logTime
@@ -218,10 +228,63 @@ class MyLog(wxPyLog):
self.tc.AppendText(message + '\n')
class MyTP(wxPyTipProvider):
class MyTP(wx.PyTipProvider):
def GetTip(self):
return "This is my tip"
#---------------------------------------------------------------------------
# A class to be used to display source code in the demo. Try using the
# wxSTC in the wxStyledTextCtrl_2 sample first, fall back to wxTextCtrl
# if there is an error, such as the stc module not being present.
try:
##raise ImportError
from wx import stc
from wxStyledTextCtrl_2 import PythonSTC
class DemoCodeViewer(PythonSTC):
def __init__(self, parent, ID):
PythonSTC.__init__(self, parent, ID)
self.SetEdgeMode(stc.STC_EDGE_NONE)
self.SetSelBackground(True, wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHT))
self.SetSelForeground(True, wx.SystemSettings_GetColour(wx.SYS_COLOUR_HIGHLIGHTTEXT))
# Some methods to make it compatible with how the wxTextCtrl is used
def SetValue(self, value):
self.SetReadOnly(False)
self.SetText(value)
self.SetReadOnly(True)
def Clear(self):
self.ClearAll()
def SetInsertionPoint(self, pos):
self.SetCurrentPos(pos)
def ShowPosition(self, pos):
self.GotoPos(pos)
def GetLastPosition(self):
return self.GetLength()
def GetRange(self, start, end):
return self.GetTextRange(start, end)
def GetSelection(self):
return self.GetAnchor(), self.GetCurrentPos()
def SetSelection(self, start, end):
self.SetSelectionStart(start)
self.SetSelectionEnd(end)
except ImportError:
class DemoCodeViewer(wx.TextCtrl):
def __init__(self, parent, ID):
wx.TextCtrl.__init__(self, parent, ID, style =
wx.TE_MULTILINE | wx.TE_READONLY |
wx.HSCROLL | wx.TE_RICH2 | wx.TE_NOHIDESEL)
#---------------------------------------------------------------------------
def opj(path):
@@ -231,12 +294,12 @@ def opj(path):
#---------------------------------------------------------------------------
class wxPythonDemo(wxFrame):
class wxPythonDemo(wx.Frame):
overviewText = "wxPython Overview"
def __init__(self, parent, id, title):
wxFrame.__init__(self, parent, -1, title, size = (800, 600),
style=wxDEFAULT_FRAME_STYLE|wxNO_FULL_REPAINT_ON_RESIZE)
wx.Frame.__init__(self, parent, -1, title, size = (800, 600),
style=wx.DEFAULT_FRAME_STYLE|wx.NO_FULL_REPAINT_ON_RESIZE)
self.cwd = os.getcwd()
self.curOverview = ""
@@ -245,97 +308,97 @@ class wxPythonDemo(wxFrame):
icon = images.getMondrianIcon()
self.SetIcon(icon)
if wxPlatform == '__WXMSW__':
if wx.Platform == '__WXMSW__':
# setup a taskbar icon, and catch some events from it
self.tbicon = wxTaskBarIcon()
self.tbicon = wx.TaskBarIcon()
self.tbicon.SetIcon(icon, "wxPython Demo")
EVT_TASKBAR_LEFT_DCLICK(self.tbicon, self.OnTaskBarActivate)
EVT_TASKBAR_RIGHT_UP(self.tbicon, self.OnTaskBarMenu)
EVT_MENU(self.tbicon, self.TBMENU_RESTORE, self.OnTaskBarActivate)
EVT_MENU(self.tbicon, self.TBMENU_CLOSE, self.OnTaskBarClose)
wx.EVT_TASKBAR_LEFT_DCLICK(self.tbicon, self.OnTaskBarActivate)
wx.EVT_TASKBAR_RIGHT_UP(self.tbicon, self.OnTaskBarMenu)
wx.EVT_MENU(self.tbicon, self.TBMENU_RESTORE, self.OnTaskBarActivate)
wx.EVT_MENU(self.tbicon, self.TBMENU_CLOSE, self.OnTaskBarClose)
wxCallAfter(self.ShowTip)
wx.CallAfter(self.ShowTip)
self.otherWin = None
EVT_IDLE(self, self.OnIdle)
EVT_CLOSE(self, self.OnCloseWindow)
EVT_ICONIZE(self, self.OnIconfiy)
EVT_MAXIMIZE(self, self.OnMaximize)
wx.EVT_IDLE(self, self.OnIdle)
wx.EVT_CLOSE(self, self.OnCloseWindow)
wx.EVT_ICONIZE(self, self.OnIconfiy)
wx.EVT_MAXIMIZE(self, self.OnMaximize)
self.Centre(wxBOTH)
self.CreateStatusBar(1, wxST_SIZEGRIP)
self.Centre(wx.BOTH)
self.CreateStatusBar(1, wx.ST_SIZEGRIP)
splitter = wxSplitterWindow(self, -1, style=wxNO_3D|wxSP_3D)
splitter2 = wxSplitterWindow(splitter, -1, style=wxNO_3D|wxSP_3D)
splitter = wx.SplitterWindow(self, -1, style=wx.NO_3D|wx.SP_3D)
splitter2 = wx.SplitterWindow(splitter, -1, style=wx.NO_3D|wx.SP_3D)
def EmptyHandler(evt): pass
EVT_ERASE_BACKGROUND(splitter, EmptyHandler)
EVT_ERASE_BACKGROUND(splitter2, EmptyHandler)
wx.EVT_ERASE_BACKGROUND(splitter, EmptyHandler)
wx.EVT_ERASE_BACKGROUND(splitter2, EmptyHandler)
# Prevent TreeCtrl from displaying all items after destruction when True
self.dying = False
# Make a File menu
self.mainmenu = wxMenuBar()
menu = wxMenu()
exitID = wxNewId()
self.mainmenu = wx.MenuBar()
menu = wx.Menu()
exitID = wx.NewId()
menu.Append(exitID, 'E&xit\tAlt-X', 'Get the heck outta here!')
EVT_MENU(self, exitID, self.OnFileExit)
wxApp_SetMacExitMenuItemId(exitID)
wx.EVT_MENU(self, exitID, self.OnFileExit)
wx.App_SetMacExitMenuItemId(exitID)
self.mainmenu.Append(menu, '&File')
# Make a Demo menu
menu = wxMenu()
menu = wx.Menu()
for item in _treeList:
submenu = wxMenu()
submenu = wx.Menu()
for childItem in item[1]:
mID = wxNewId()
mID = wx.NewId()
submenu.Append(mID, childItem)
EVT_MENU(self, mID, self.OnDemoMenu)
menu.AppendMenu(wxNewId(), item[0], submenu)
wx.EVT_MENU(self, mID, self.OnDemoMenu)
menu.AppendMenu(wx.NewId(), item[0], submenu)
self.mainmenu.Append(menu, '&Demo')
# Make a Help menu
helpID = wxNewId()
findID = wxNewId()
findnextID = wxNewId()
menu = wxMenu()
helpID = wx.NewId()
findID = wx.NewId()
findnextID = wx.NewId()
menu = wx.Menu()
menu.Append(findID, '&Find\tCtrl-F', 'Find in the Demo Code')
menu.Append(findnextID, 'Find &Next\tF3', 'Find Next')
menu.AppendSeparator()
menu.Append(helpID, '&About\tCtrl-H', 'wxPython RULES!!!')
wxApp_SetMacAboutMenuItemId(helpID)
EVT_MENU(self, helpID, self.OnHelpAbout)
EVT_MENU(self, findID, self.OnHelpFind)
EVT_MENU(self, findnextID, self.OnFindNext)
EVT_COMMAND_FIND(self, -1, self.OnFind)
EVT_COMMAND_FIND_NEXT(self, -1, self.OnFind)
EVT_COMMAND_FIND_CLOSE(self, -1 , self.OnFindClose)
wx.App_SetMacAboutMenuItemId(helpID)
wx.EVT_MENU(self, helpID, self.OnHelpAbout)
wx.EVT_MENU(self, findID, self.OnHelpFind)
wx.EVT_MENU(self, findnextID, self.OnFindNext)
wx.EVT_COMMAND_FIND(self, -1, self.OnFind)
wx.EVT_COMMAND_FIND_NEXT(self, -1, self.OnFind)
wx.EVT_COMMAND_FIND_CLOSE(self, -1 , self.OnFindClose)
self.mainmenu.Append(menu, '&Help')
self.SetMenuBar(self.mainmenu)
self.finddata = wxFindReplaceData()
self.finddata = wx.FindReplaceData()
if 0:
# This is another way to set Accelerators, in addition to
# using the '\t<key>' syntax in the menu items.
aTable = wxAcceleratorTable([(wxACCEL_ALT, ord('X'), exitID),
(wxACCEL_CTRL, ord('H'), helpID),
(wxACCEL_CTRL, ord('F'), findID),
(wxACCEL_NORMAL, WXK_F3, findnextID)])
aTable = wx.AcceleratorTable([(wx.ACCEL_ALT, ord('X'), exitID),
(wx.ACCEL_CTRL, ord('H'), helpID),
(wx.ACCEL_CTRL, ord('F'), findID),
(wx.ACCEL_NORMAL, WXK_F3, findnextID)
])
self.SetAcceleratorTable(aTable)
# Create a TreeCtrl
tID = wxNewId()
tID = wx.NewId()
self.treeMap = {}
self.tree = wxTreeCtrl(splitter, tID,
style=wxTR_HAS_BUTTONS |
wxTR_HAS_VARIABLE_ROW_HEIGHT
self.tree = wx.TreeCtrl(splitter, tID,
style=wx.TR_HAS_BUTTONS |
wx.TR_HAS_VARIABLE_ROW_HEIGHT
)
#self.tree.SetBackgroundColour(wxNamedColour("Pink"))
root = self.tree.AddRoot("wxPython Overview")
firstChild = None
for item in _treeList:
@@ -347,57 +410,56 @@ class wxPythonDemo(wxFrame):
self.tree.Expand(root)
self.tree.Expand(firstChild)
EVT_TREE_ITEM_EXPANDED (self.tree, tID, self.OnItemExpanded)
EVT_TREE_ITEM_COLLAPSED (self.tree, tID, self.OnItemCollapsed)
EVT_TREE_SEL_CHANGED (self.tree, tID, self.OnSelChanged)
EVT_LEFT_DOWN (self.tree, self.OnTreeLeftDown)
wx.EVT_TREE_ITEM_EXPANDED (self.tree, tID, self.OnItemExpanded)
wx.EVT_TREE_ITEM_COLLAPSED (self.tree, tID, self.OnItemCollapsed)
wx.EVT_TREE_SEL_CHANGED (self.tree, tID, self.OnSelChanged)
wx.EVT_LEFT_DOWN (self.tree, self.OnTreeLeftDown)
# Create a Notebook
self.nb = wxNotebook(splitter2, -1, style=wxCLIP_CHILDREN)
self.nb = wx.Notebook(splitter2, -1, style=wx.CLIP_CHILDREN)
# Set up a wxHtmlWindow on the Overview Notebook page
# Set up a wx.html.HtmlWindow on the Overview Notebook page
# we put it in a panel first because there seems to be a
# refresh bug of some sort (wxGTK) when it is directly in
# the notebook...
if 0: # the old way
self.ovr = wxHtmlWindow(self.nb, -1, size=(400, 400))
self.ovr = wx.html.HtmlWindow(self.nb, -1, size=(400, 400))
self.nb.AddPage(self.ovr, self.overviewText)
else: # hopefully I can remove this hacky code soon, see bug #216861
panel = wxPanel(self.nb, -1, style=wxCLIP_CHILDREN)
self.ovr = wxHtmlWindow(panel, -1, size=(400, 400))
else: # hopefully I can remove this hacky code soon, see SF bug #216861
panel = wx.Panel(self.nb, -1, style=wx.CLIP_CHILDREN)
self.ovr = wx.html.HtmlWindow(panel, -1, size=(400, 400))
self.nb.AddPage(panel, self.overviewText)
def OnOvrSize(evt, ovr=self.ovr):
ovr.SetSize(evt.GetSize())
EVT_SIZE(panel, OnOvrSize)
EVT_ERASE_BACKGROUND(panel, EmptyHandler)
wx.EVT_SIZE(panel, OnOvrSize)
wx.EVT_ERASE_BACKGROUND(panel, EmptyHandler)
self.SetOverview(self.overviewText, overview)
# Set up a TextCtrl on the Demo Code Notebook page
self.txt = wxTextCtrl(self.nb, -1,
style = wxTE_MULTILINE|wxTE_READONLY|
wxHSCROLL|wxTE_RICH2|wxTE_NOHIDESEL)
# Set up a notebook page for viewing the source code of each sample
self.txt = DemoCodeViewer(self.nb, -1)
self.nb.AddPage(self.txt, "Demo Code")
self.GetDemoFile('Main.py')
# Set up a log on the View Log Notebook page
self.log = wxTextCtrl(splitter2, -1,
style = wxTE_MULTILINE|wxTE_READONLY|wxHSCROLL)
self.log = wx.TextCtrl(splitter2, -1,
style = wx.TE_MULTILINE|wx.TE_READONLY|wx.HSCROLL)
# Set the wxWindows log target to be this textctrl
#wxLog_SetActiveTarget(wxLogTextCtrl(self.log))
#wx.Log_SetActiveTarget(wx.LogTextCtrl(self.log))
# But instead of the above we want to show how to use our own wxLog class
wxLog_SetActiveTarget(MyLog(self.log))
# But instead of the above we want to show how to use our own wx.Log class
wx.Log_SetActiveTarget(MyLog(self.log))
# for serious debugging
#wxLog_SetActiveTarget(wxLogStderr())
#wxLog_SetTraceMask(wxTraceMessages)
#wx.Log_SetActiveTarget(wx.LogStderr())
#wx.Log_SetTraceMask(wx.TraceMessages)
self.Show(True)
@@ -425,14 +487,14 @@ class wxPythonDemo(wxFrame):
self.tree.EnsureVisible(selectedDemo)
wxLogMessage('window handle: %s' % self.GetHandle())
wx.LogMessage('window handle: %s' % self.GetHandle())
#---------------------------------------------
def WriteText(self, text):
if text[-1:] == '\n':
text = text[:-1]
wxLogMessage(text)
wx.LogMessage(text)
def write(self, txt):
@@ -441,13 +503,13 @@ class wxPythonDemo(wxFrame):
#---------------------------------------------
def OnItemExpanded(self, event):
item = event.GetItem()
wxLogMessage("OnItemExpanded: %s" % self.tree.GetItemText(item))
wx.LogMessage("OnItemExpanded: %s" % self.tree.GetItemText(item))
event.Skip()
#---------------------------------------------
def OnItemCollapsed(self, event):
item = event.GetItem()
wxLogMessage("OnItemCollapsed: %s" % self.tree.GetItemText(item))
wx.LogMessage("OnItemCollapsed: %s" % self.tree.GetItemText(item))
event.Skip()
#---------------------------------------------
@@ -478,7 +540,7 @@ class wxPythonDemo(wxFrame):
if self.window is not None:
if hasattr(self.window, "ShutdownDemo"):
self.window.ShutdownDemo()
wxSafeYield() # in case the page has pending events
wx.SafeYield() # in case the page has pending events
self.nb.DeletePage(2)
if itemText == self.overviewText:
@@ -489,19 +551,19 @@ class wxPythonDemo(wxFrame):
else:
if os.path.exists(itemText + '.py'):
wxBeginBusyCursor()
wxLogMessage("Running demo %s.py..." % itemText)
wx.BeginBusyCursor()
wx.LogMessage("Running demo %s.py..." % itemText)
try:
self.GetDemoFile(itemText + '.py')
module = __import__(itemText, globals())
self.SetOverview(itemText + " Overview", module.overview)
finally:
wxEndBusyCursor()
wx.EndBusyCursor()
self.tree.Refresh()
# in case runTest is modal, make sure things look right...
self.nb.Refresh();
wxSafeYield()
wx.SafeYield()
self.window = module.runTest(self, self.nb, self) ###
if self.window is not None:
@@ -523,7 +585,7 @@ class wxPythonDemo(wxFrame):
try:
self.txt.SetValue(open(filename).read())
except IOError:
self.txt.WriteText("Cannot open %s file." % filename)
self.txt.SetValue("Cannot open %s file." % filename)
self.txt.SetInsertionPoint(0)
self.txt.ShowPosition(0)
@@ -550,10 +612,10 @@ class wxPythonDemo(wxFrame):
def OnHelpFind(self, event):
self.nb.SetSelection(1)
self.finddlg = wxFindReplaceDialog(self, self.finddata, "Find",
wxFR_NOUPDOWN |
wxFR_NOMATCHCASE |
wxFR_NOWHOLEWORD)
self.finddlg = wx.FindReplaceDialog(self, self.finddata, "Find",
wx.FR_NOUPDOWN |
wx.FR_NOMATCHCASE |
wx.FR_NOWHOLEWORD)
self.finddlg.Show(True)
def OnFind(self, event):
@@ -568,9 +630,9 @@ class wxPythonDemo(wxFrame):
start = 0
loc = textstring.find(findstring, start)
if loc == -1:
dlg = wxMessageDialog(self, 'Find String Not Found',
dlg = wx.MessageDialog(self, 'Find String Not Found',
'Find String Not Found in Demo File',
wxOK | wxICON_INFORMATION)
wx.OK | wx.ICON_INFORMATION)
dlg.ShowModal()
dlg.Destroy()
if self.finddlg:
@@ -579,8 +641,8 @@ class wxPythonDemo(wxFrame):
return
else:
self.finddlg.Destroy()
self.txt.SetSelection(loc, loc + len(findstring))
self.txt.ShowPosition(loc)
self.txt.SetSelection(loc, loc + len(findstring))
@@ -620,9 +682,9 @@ class wxPythonDemo(wxFrame):
except IOError:
showTip, index = (1, 0)
if showTip:
tp = wxCreateFileTipProvider(opj("data/tips.txt"), index)
tp = wx.CreateFileTipProvider(opj("data/tips.txt"), index)
##tp = MyTP(0)
showTip = wxShowTip(self, tp)
showTip = wx.ShowTip(self, tp)
index = tp.GetCurrentTip()
open(opj("data/showTips"), "w").write(str( (showTip, index) ))
@@ -652,7 +714,7 @@ class wxPythonDemo(wxFrame):
TBMENU_CLOSE = 1001
def OnTaskBarMenu(self, evt):
menu = wxMenu()
menu = wx.Menu()
menu.Append(self.TBMENU_RESTORE, "Restore wxPython Demo")
menu.Append(self.TBMENU_CLOSE, "Close")
self.tbicon.PopupMenu(menu)
@@ -662,19 +724,19 @@ class wxPythonDemo(wxFrame):
def OnTaskBarClose(self, evt):
self.Close()
# because of the way wxTaskBarIcon.PopupMenu is implemented we have to
# because of the way wx.TaskBarIcon.PopupMenu is implemented we have to
# prod the main idle handler a bit to get the window to actually close
wxGetApp().ProcessIdle()
wx.GetApp().ProcessIdle()
#---------------------------------------------
def OnIconfiy(self, evt):
wxLogMessage("OnIconfiy")
wx.LogMessage("OnIconfiy")
evt.Skip()
#---------------------------------------------
def OnMaximize(self, evt):
wxLogMessage("OnMaximize")
wx.LogMessage("OnMaximize")
evt.Skip()
@@ -683,14 +745,14 @@ class wxPythonDemo(wxFrame):
#---------------------------------------------------------------------------
#---------------------------------------------------------------------------
class MySplashScreen(wxSplashScreen):
class MySplashScreen(wx.SplashScreen):
def __init__(self):
bmp = wxImage(opj("bitmaps/splash.gif")).ConvertToBitmap()
wxSplashScreen.__init__(self, bmp,
wxSPLASH_CENTRE_ON_SCREEN|wxSPLASH_TIMEOUT,
bmp = wx.Image(opj("bitmaps/splash.gif")).ConvertToBitmap()
wx.SplashScreen.__init__(self, bmp,
wx.SPLASH_CENTRE_ON_SCREEN|wx.SPLASH_TIMEOUT,
4000, None, -1,
style = wxSIMPLE_BORDER|wxFRAME_NO_TASKBAR|wxSTAY_ON_TOP)
EVT_CLOSE(self, self.OnClose)
style = wx.SIMPLE_BORDER|wx.FRAME_NO_TASKBAR|wx.STAY_ON_TOP)
wx.EVT_CLOSE(self, self.OnClose)
def OnClose(self, evt):
frame = wxPythonDemo(None, -1, "wxPython: (A Demonstration)")
@@ -698,7 +760,7 @@ class MySplashScreen(wxSplashScreen):
evt.Skip() # Make sure the default handler runs too...
class MyApp(wxApp):
class MyApp(wx.App):
def OnInit(self):
"""
Create and show the splash screen. It will then create and show
@@ -706,10 +768,10 @@ class MyApp(wxApp):
"""
#import locale
#self.locale = wxLocale(wxLANGUAGE_FRENCH)
#self.locale = wx.Locale(wx.LANGUAGE_FRENCH)
#locale.setlocale(locale.LC_ALL, 'fr')
wxInitAllImageHandlers()
wx.InitAllImageHandlers()
splash = MySplashScreen()
splash.Show()
return True
@@ -724,7 +786,7 @@ def main():
os.chdir(demoPath)
except:
pass
app = MyApp(wxPlatform == "__WXMAC__")
app = MyApp(wx.Platform == "__WXMAC__")
app.MainLoop()
@@ -733,76 +795,36 @@ def main():
overview = """<html><body>
<h2>Python</h2>
<h2>wxPython</h2>
Python is an interpreted, interactive, object-oriented programming
language often compared to Tcl, Perl, Scheme, or Java.
<p> wxPython is a <b>GUI toolkit</b> for the <a
href="http://www.python.org/">Python</a> programming language. It
allows Python programmers to create programs with a robust, highly
functional graphical user interface, simply and easily. It is
implemented as a Python extension module (native code) that wraps the
popular <a href="http://wxwindows.org/front.htm">wxWindows</a> cross
platform GUI library, which is written in C++.
<p> Python combines remarkable power with very clear syntax. It has
modules, classes, exceptions, very high level dynamic data types, and
dynamic typing. There are interfaces to many system calls and
libraries, and new built-in modules are easily written in C or
C++. Python is also usable as an extension language for applications
that need a programmable interface. <p>
<p> Like Python and wxWindows, wxPython is <b>Open Source</b> which
means that it is free for anyone to use and the source code is
available for anyone to look at and modify. Or anyone can contribute
fixes or enhnacments to the project.
<h2>wxWindows</h2>
<p> wxPython is a <b>cross-platform</b> toolkit. This means that the
same program will run on multiple platforms without modification.
Currently supported platforms are 32-bit Microsoft Windows, most Unix
or unix-like systems, and Macintosh OS X. Since the language is
Python, wxPython programs are <b>simple, easy</b> to write and easy to
understand.
wxWindows is a free C++ framework designed to make cross-platform
programming child's play. Well, almost. wxWindows 2 supports Windows
3.1/95/98/NT, Unix with GTK/Motif/Lesstif, with a Mac version
underway. Other ports are under consideration. <p>
<p> <b>This demo</b> is not only a collection of test cases for
wxPython, but is also designed to help you learn about and how to use
wxPython. Each sample is listed in the tree control on the left.
When a sample is selected in the tree then a module is loaded and run
(usually in a tab of this notebook,) and the source code of the module
is loaded in another tab for you to browse and learn from.
wxWindows is a set of libraries that allows C++ applications to
compile and run on several different types of computers, with minimal
source code changes. There is one library per supported GUI (such as
Motif, or Windows). As well as providing a common API (Application
Programming Interface) for GUI functionality, it provides
functionality for accessing some commonly-used operating system
facilities, such as copying or deleting files. wxWindows is a
'framework' in the sense that it provides a lot of built-in
functionality, which the application can use or replace as required,
thus saving a great deal of coding effort. Basic data structures such
as strings, linked lists and hash tables are also supported.
<p>
<h2>wxPython</h2>
wxPython is a Python extension module that encapsulates the wxWindows
GUI classes. Currently it is only available for the Win32 and GTK
ports of wxWindows, but as soon as the other ports are brought up to
the same level as Win32 and GTK, it should be fairly trivial to
enable wxPython to be used with the new GUI.
<p>
The wxPython extension module attempts to mirror the class heiarchy
of wxWindows as closely as possible. This means that there is a
wxFrame class in wxPython that looks, smells, tastes and acts almost
the same as the wxFrame class in the C++ version. Unfortunately,
because of differences in the languages, wxPython doesn't match
wxWindows exactly, but the differences should be easy to absorb
because they are natural to Python. For example, some methods that
return multiple values via argument pointers in C++ will return a
tuple of values in Python.
<p>
There is still much to be done for wxPython, many classes still need
to be mirrored. Also, wxWindows is still somewhat of a moving target
so it is a bit of an effort just keeping wxPython up to date. On the
other hand, there are enough of the core classes completed that
useful applications can be written.
<p>
wxPython is close enough to the C++ version that the majority of
the wxPython documentation is actually just notes attached to the C++
documents that describe the places where wxPython is different. There
is also a series of sample programs included, and a series of
documentation pages that assist the programmer in getting started
with wxPython.
"""
"""
#----------------------------------------------------------------------------

View File

@@ -0,0 +1,540 @@
from wxPython.wx import *
from wxPython.lib.maskededit import Field, wxMaskedTextCtrl, wxMaskedComboBox, wxIpAddrCtrl, states, months
from wxPython.lib.maskededit import __doc__ as overviewdoc
from wxPython.lib.maskededit import autoformats
from wxPython.lib.scrolledpanel import wxScrolledPanel
import string, sys, traceback
class demoMixin:
"""
Centralized routines common to demo pages, to remove repetition.
"""
def labelGeneralTable(self, sizer):
description = wxStaticText( self, -1, "Description", )
mask = wxStaticText( self, -1, "Mask Value" )
formatcode = wxStaticText( self, -1, "Format" )
regex = wxStaticText( self, -1, "Regexp Validator(opt.)" )
ctrl = wxStaticText( self, -1, "wxMaskedEdit Ctrl" )
description.SetFont( wxFont(9, wxSWISS, wxNORMAL, wxBOLD))
mask.SetFont( wxFont(9, wxSWISS, wxNORMAL, wxBOLD))
formatcode.SetFont( wxFont(9, wxSWISS, wxNORMAL, wxBOLD) )
regex.SetFont( wxFont(9, wxSWISS, wxNORMAL, wxBOLD))
ctrl.SetFont( wxFont(9, wxSWISS, wxNORMAL, wxBOLD))
sizer.Add(description)
sizer.Add(mask)
sizer.Add(formatcode)
sizer.Add(regex)
sizer.Add(ctrl)
def layoutGeneralTable(self, controls, sizer):
for control in controls:
sizer.Add( wxStaticText( self, -1, control[0]) )
sizer.Add( wxStaticText( self, -1, control[1]) )
sizer.Add( wxStaticText( self, -1, control[3]) )
sizer.Add( wxStaticText( self, -1, control[4]) )
if control in controls:
newControl = wxMaskedTextCtrl( self, -1, "",
mask = control[1],
excludeChars = control[2],
formatcodes = control[3],
includeChars = "",
validRegex = control[4],
validRange = control[5],
choices = control[6],
choiceRequired = True,
defaultValue = control[7],
demo = True,
name = control[0])
self.editList.append(newControl)
sizer.Add(newControl)
def changeControlParams(self, event, parameter, checked_value, notchecked_value):
if event.Checked(): value = checked_value
else: value = notchecked_value
kwargs = {parameter: value}
for control in self.editList:
control.SetCtrlParameters(**kwargs)
control.Refresh()
self.Refresh()
#----------------------------------------------------------------------------
class demoPage1(wxScrolledPanel, demoMixin):
def __init__(self, parent, log):
wxScrolledPanel.__init__(self, parent, -1)
self.sizer = wxBoxSizer( wxVERTICAL )
self.editList = []
label = wxStaticText( self, -1, """\
Here are some basic wxMaskedTextCtrls to give you an idea of what you can do
with this control. Note that all controls have been auto-sized by including 'F' in
the format codes.
Try entering nonsensical or partial values in validated fields to see what happens.
Note that the State and Last Name fields are list-limited (valid last names are:
Smith, Jones, Williams). Signs on numbers can be toggled with the minus key.
""")
label.SetForegroundColour( "Blue" )
header = wxBoxSizer( wxHORIZONTAL )
header.Add( label, 0, flag=wxALIGN_LEFT|wxALL, border = 5 )
highlight = wxCheckBox( self, -1, "Highlight Empty" )
disallow = wxCheckBox( self, -1, "Disallow Empty" )
showFill = wxCheckBox( self, -1, "change fillChar" )
vbox = wxBoxSizer( wxVERTICAL )
vbox.Add( highlight, 0, wxALIGN_LEFT|wxALL, 5 )
vbox.Add( disallow, 0, wxALIGN_LEFT|wxALL, 5 )
vbox.Add( showFill, 0, wxALIGN_LEFT|wxALL, 5 )
header.AddSpacer(15, 0)
header.Add(vbox, 0, flag=wxALIGN_LEFT|wxALL, border=5 )
EVT_CHECKBOX( self, highlight.GetId(), self.onHighlightEmpty )
EVT_CHECKBOX( self, disallow.GetId(), self.onDisallowEmpty )
EVT_CHECKBOX( self, showFill.GetId(), self.onShowFill )
grid = wxFlexGridSizer( 0, 5, vgap=10, hgap=10 )
self.labelGeneralTable(grid)
# The following list is of the controls for the demo. Feel free to play around with
# the options!
controls = [
#description mask excl format regexp range,list,initial
("Phone No", "(###) ###-#### x:###", "", 'F^-', "^\(\d{3}\) \d{3}-\d{4}", '','',''),
("Social Sec#", "###-##-####", "", 'F', "\d{3}-\d{2}-\d{4}", '','',''),
("Full Name", "C{14}", "", 'F_', '^[A-Z][a-zA-Z]+ [A-Z][a-zA-Z]+', '','',''),
("Last Name Only", "C{14}", "", 'F {list}', '^[A-Z][a-zA-Z]+', '',('Smith','Jones','Williams'),''),
("Zip plus 4", "#{5}-#{4}", "", 'F', "\d{5}-(\s{4}|\d{4})", '','',''),
("Customer No", "\CAA-###", "", 'F!', "C[A-Z]{2}-\d{3}", '','',''),
("Invoice Total", "#{9}.##", "", 'F-_,', "", '','',''),
("Integer", "#{9}", "", 'F-_', "", '','',''),
]
self.layoutGeneralTable(controls, grid)
self.sizer.Add( header, 0, flag=wxALIGN_LEFT|wxALL, border=5 )
self.sizer.Add( grid, 0, flag= wxALIGN_LEFT|wxLEFT, border=5 )
self.SetSizer(self.sizer)
self.SetupScrolling()
self.SetAutoLayout(1)
def onDisallowEmpty( self, event ):
""" Set emptyInvalid parameter on/off """
self.changeControlParams( event, "emptyInvalid", True, False )
def onHighlightEmpty( self, event ):
""" Highlight empty values"""
self.changeControlParams( event, "emptyBackgroundColor", "Blue", "White" )
def onShowFill( self, event ):
""" Set fillChar parameter to '?' or ' ' """
self.changeControlParams( event, "fillChar", '?', ' ' )
class demoPage2(wxScrolledPanel, demoMixin):
def __init__( self, parent, log ):
self.log = log
wxScrolledPanel.__init__( self, parent, -1 )
self.sizer = wxBoxSizer( wxVERTICAL )
label = wxStaticText( self, -1, """\
All these controls have been created by passing a single parameter, the autoformat code.
The class contains an internal dictionary of types and formats (autoformats).
Many of these already do complicated validation; To see some examples, try
29 Feb 2002 vs. 2004 for the date formats, or email address validation.
""")
label.SetForegroundColour( "Blue" )
self.sizer.Add( label, 0, wxALIGN_LEFT|wxALL, 5 )
description = wxStaticText( self, -1, "Description")
autofmt = wxStaticText( self, -1, "AutoFormat Code")
ctrl = wxStaticText( self, -1, "wxMaskedEdit Control")
description.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
autofmt.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
ctrl.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
grid = wxFlexGridSizer( 0, 3, vgap=10, hgap=5 )
grid.Add( description, 0, wxALIGN_LEFT )
grid.Add( autofmt, 0, wxALIGN_LEFT )
grid.Add( ctrl, 0, wxALIGN_LEFT )
for autoformat, desc in autoformats:
grid.Add( wxStaticText( self, -1, desc), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, autoformat), 0, wxALIGN_LEFT )
grid.Add( wxMaskedTextCtrl( self, -1, "",
autoformat = autoformat,
demo = True,
name = autoformat),
0, wxALIGN_LEFT )
self.sizer.Add( grid, 0, wxALIGN_LEFT|wxALL, border=5 )
self.SetSizer( self.sizer )
self.SetAutoLayout( 1 )
self.SetupScrolling()
class demoPage3(wxScrolledPanel, demoMixin):
def __init__(self, parent, log):
self.log = log
wxScrolledPanel.__init__(self, parent, -1)
self.sizer = wxBoxSizer( wxVERTICAL )
self.editList = []
label = wxStaticText( self, -1, """\
Here wxMaskedTextCtrls that have default values. The states
control has a list of valid values, and the unsigned integer
has a legal range specified.
""")
label.SetForegroundColour( "Blue" )
requireValid = wxCheckBox( self, -1, "Require Valid Value" )
EVT_CHECKBOX( self, requireValid.GetId(), self.onRequireValid )
header = wxBoxSizer( wxHORIZONTAL )
header.Add( label, 0, flag=wxALIGN_LEFT|wxALL, border = 5)
header.AddSpacer(75, 0)
header.Add( requireValid, 0, flag=wxALIGN_LEFT|wxALL, border=10 )
grid = wxFlexGridSizer( 0, 5, vgap=10, hgap=10 )
self.labelGeneralTable( grid )
controls = [
#description mask excl format regexp range,list,initial
("U.S. State (2 char)", "AA", "", 'F!_', "[A-Z]{2}", '',states, states[0]),
("Integer (signed)", "#{6}", "", 'F-_R', "", '','', '0 '),
("Integer (unsigned)\n(1-399)","######", "", 'F_', "", (1,399),'', '1 '),
("Float (signed)", "#{6}.#{9}", "", 'F-_R', "", '','', '000000.000000000'),
("Date (MDY) + Time", "##/##/#### ##:##:## AM", 'BCDEFGHIJKLMNOQRSTUVWXYZ','DF!',"", '','', wxDateTime_Now().Format("%m/%d/%Y %I:%M:%S %p")),
]
self.layoutGeneralTable( controls, grid )
self.sizer.Add( header, 0, flag=wxALIGN_LEFT|wxALL, border=5 )
self.sizer.Add( grid, 0, flag=wxALIGN_LEFT|wxALL, border=5 )
self.SetSizer( self.sizer )
self.SetAutoLayout( 1 )
self.SetupScrolling()
def onRequireValid( self, event ):
""" Set validRequired parameter on/off """
self.changeControlParams( event, "validRequired", True, False )
class demoPage4(wxScrolledPanel, demoMixin):
def __init__( self, parent, log ):
self.log = log
wxScrolledPanel.__init__( self, parent, -1 )
self.sizer = wxBoxSizer( wxVERTICAL )
label = wxStaticText( self, -1, """\
These controls have field-specific choice lists and allow autocompletion.
Down arrow or Page Down in an uncompleted field with an auto-completable field will attempt
to auto-complete a field if it has a choice list.
Page Down and Shift-Down arrow will also auto-complete, or cycle through the complete list.
Page Up and Shift-Up arrow will similarly cycle backwards through the list.
""")
label.SetForegroundColour( "Blue" )
self.sizer.Add( label, 0, wxALIGN_LEFT|wxALL, 5 )
description = wxStaticText( self, -1, "Description" )
autofmt = wxStaticText( self, -1, "AutoFormat Code" )
fields = wxStaticText( self, -1, "Field Objects" )
ctrl = wxStaticText( self, -1, "wxMaskedEdit Control" )
description.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
autofmt.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
fields.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
ctrl.SetFont( wxFont( 9, wxSWISS, wxNORMAL, wxBOLD ) )
grid = wxFlexGridSizer( 0, 4, vgap=10, hgap=10 )
grid.Add( description, 0, wxALIGN_LEFT )
grid.Add( autofmt, 0, wxALIGN_LEFT )
grid.Add( fields, 0, wxALIGN_LEFT )
grid.Add( ctrl, 0, wxALIGN_LEFT )
autoformat = "USPHONEFULLEXT"
fieldsDict = {0: Field(choices=["617","781","508","978","413"], choiceRequired=True)}
fieldsLabel = """\
{0: Field(choices=[
"617","781",
"508","978","413"],
choiceRequired=True)}"""
grid.Add( wxStaticText( self, -1, "Restricted Area Code"), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, autoformat), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, fieldsLabel), 0, wxALIGN_LEFT )
grid.Add( wxMaskedTextCtrl( self, -1, "",
autoformat = autoformat,
fields = fieldsDict,
demo = True,
name = autoformat),
0, wxALIGN_LEFT )
autoformat = "EXPDATEMMYY"
fieldsDict = {1: Field(choices=["03", "04", "05"], choiceRequired=True)}
fieldsLabel = """\
{1: Field(choices=[
"03", "04", "05"],
choiceRequired=True)}"""
exp = wxMaskedTextCtrl( self, -1, "",
autoformat = autoformat,
fields = fieldsDict,
demo = True,
name = autoformat)
grid.Add( wxStaticText( self, -1, "Restricted Expiration"), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, autoformat), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, fieldsLabel), 0, wxALIGN_LEFT )
grid.Add( exp, 0, wxALIGN_LEFT )
fieldsDict = {0: Field(choices=["02134","02155"], choiceRequired=True),
1: Field(choices=["1234", "5678"], choiceRequired=False)}
fieldsLabel = """\
{0: Field(choices=["02134","02155"],
choiceRequired=True),
1: Field(choices=["1234", "5678"],
choiceRequired=False)}"""
autoformat = "USZIPPLUS4"
zip = wxMaskedTextCtrl( self, -1, "",
autoformat = autoformat,
fields = fieldsDict,
demo = True,
name = autoformat)
grid.Add( wxStaticText( self, -1, "Restricted Zip + 4"), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, autoformat), 0, wxALIGN_LEFT )
grid.Add( wxStaticText( self, -1, fieldsLabel), 0, wxALIGN_LEFT )
grid.Add( zip, 0, wxALIGN_LEFT )
self.sizer.Add( grid, 0, wxALIGN_LEFT|wxALL, border=5 )
self.SetSizer( self.sizer )
self.SetAutoLayout(1)
self.SetupScrolling()
class demoPage5(wxScrolledPanel, demoMixin):
def __init__( self, parent, log ):
self.log = log
wxScrolledPanel.__init__( self, parent, -1 )
self.sizer = wxBoxSizer( wxVERTICAL )
label = wxStaticText( self, -1, """\
These are examples of wxMaskedComboBox and wxIpAddrCtrl, and more useful
configurations of a wxMaskedTextCtrl for integer and floating point input.
""")
label.SetForegroundColour( "Blue" )
self.sizer.Add( label, 0, wxALIGN_LEFT|wxALL, 5 )
numerators = [ str(i) for i in range(1, 4) ]
denominators = [ string.ljust(str(i), 2) for i in [2,3,4,5,8,16,32,64] ]
fieldsDict = {0: Field(choices=numerators, choiceRequired=False),
1: Field(choices=denominators, choiceRequired=True)}
choices = []
for n in numerators:
for d in denominators:
if n != d:
choices.append( '%s/%s' % (n,d) )
text1 = wxStaticText( self, -1, """\
A masked ComboBox for fraction selection.
Choices for each side of the fraction can be
selected with PageUp/Down:""")
fraction = wxMaskedComboBox( self, -1, "",
choices = choices,
choiceRequired = True,
mask = "#/##",
formatcodes = "F_",
validRegex = "^\d\/\d\d?",
fields = fieldsDict )
text2 = wxStaticText( self, -1, """
A masked ComboBox to validate
text from a list of numeric codes:""")
choices = ["91", "136", "305", "4579"]
code = wxMaskedComboBox( self, -1, choices[0],
choices = choices,
choiceRequired = True,
formatcodes = "F_r",
mask = "####")
text3 = wxStaticText( self, -1, """\
A masked state selector; only "legal" values
can be entered:""")
state = wxMaskedComboBox( self, -1, states[0],
choices = states,
autoformat="USSTATE")
text4 = wxStaticText( self, -1, "An empty IP Address entry control:")
ip_addr1 = wxIpAddrCtrl( self, -1, style = wxTE_PROCESS_TAB )
text5 = wxStaticText( self, -1, "An IP Address control with a restricted mask:")
ip_addr2 = wxIpAddrCtrl( self, -1, mask=" 10. 1.109.###" )
text6 = wxStaticText( self, -1, """\
An IP Address control with restricted choices
of form: 10. (1|2) . (129..255) . (0..255)""")
ip_addr3 = wxIpAddrCtrl( self, -1, mask=" 10. #.###.###")
ip_addr3.SetFieldParameters(0, validRegex="1|2" ) # requires entry to match or not allowed
# This allows any value in penultimate field, but colors anything outside of the range invalid:
ip_addr3.SetFieldParameters(1, validRange=(129,255), validRequired=False )
text7 = wxStaticText( self, -1, """\
A right-insert integer entry control:""")
intctrl = wxMaskedTextCtrl(self, -1, name='intctrl', mask="#{9}", formatcodes = '_-r,F')
text8 = wxStaticText( self, -1, """\
A floating point entry control
with right-insert for ordinal:""")
self.floatctrl = wxMaskedTextCtrl(self, -1, name='floatctrl', mask="#{9}.#{2}", formatcodes="F,_-R")
self.floatctrl.SetFieldParameters(0, formatcodes='r<', validRequired=True) # right-insert, require explicit cursor movement to change fields
self.floatctrl.SetFieldParameters(1, defaultValue='00') # don't allow blank fraction
text9 = wxStaticText( self, -1, """\
Use this control to programmatically set
the value of the above float control:""")
number_combo = wxComboBox(self, -1, choices = [ '', '111', '222.22', '-3', '54321.666666666', '-1353.978',
'1234567', '-1234567', '123456789', '-123456789.1',
'1234567890.', '-1234567890.1' ])
grid = wxFlexGridSizer( 0, 2, vgap=10, hgap = 5 )
grid.Add( text1, 0, wxALIGN_LEFT )
grid.Add( fraction, 0, wxALIGN_LEFT )
grid.Add( text2, 0, wxALIGN_LEFT )
grid.Add( code, 0, wxALIGN_LEFT )
grid.Add( text3, 0, wxALIGN_LEFT )
grid.Add( state, 0, wxALIGN_LEFT )
grid.Add( text4, 0, wxALIGN_LEFT )
grid.Add( ip_addr1, 0, wxALIGN_LEFT )
grid.Add( text5, 0, wxALIGN_LEFT )
grid.Add( ip_addr2, 0, wxALIGN_LEFT )
grid.Add( text6, 0, wxALIGN_LEFT )
grid.Add( ip_addr3, 0, wxALIGN_LEFT )
grid.Add( text7, 0, wxALIGN_LEFT )
grid.Add( intctrl, 0, wxALIGN_LEFT )
grid.Add( text8, 0, wxALIGN_LEFT )
grid.Add( self.floatctrl, 0, wxALIGN_LEFT )
grid.Add( text9, 0, wxALIGN_LEFT )
grid.Add( number_combo, 0, wxALIGN_LEFT )
self.sizer.Add( grid, 0, wxALIGN_LEFT|wxALL, border=5 )
self.SetSizer( self.sizer )
self.SetAutoLayout(1)
self.SetupScrolling()
EVT_COMBOBOX( self, fraction.GetId(), self.OnComboChange )
EVT_COMBOBOX( self, code.GetId(), self.OnComboChange )
EVT_COMBOBOX( self, state.GetId(), self.OnComboChange )
EVT_TEXT( self, fraction.GetId(), self.OnComboChange )
EVT_TEXT( self, code.GetId(), self.OnComboChange )
EVT_TEXT( self, state.GetId(), self.OnComboChange )
EVT_TEXT( self, ip_addr1.GetId(), self.OnIpAddrChange )
EVT_TEXT( self, ip_addr2.GetId(), self.OnIpAddrChange )
EVT_TEXT( self, ip_addr3.GetId(), self.OnIpAddrChange )
EVT_TEXT( self, intctrl.GetId(), self.OnTextChange )
EVT_TEXT( self, self.floatctrl.GetId(), self.OnTextChange )
EVT_COMBOBOX( self, number_combo.GetId(), self.OnNumberSelect )
def OnComboChange( self, event ):
ctl = self.FindWindowById( event.GetId() )
if not ctl.IsValid():
self.log.write('current value not a valid choice')
def OnIpAddrChange( self, event ):
ip_addr = self.FindWindowById( event.GetId() )
if ip_addr.IsValid():
self.log.write('new addr = %s\n' % ip_addr.GetAddress() )
def OnTextChange( self, event ):
ctl = self.FindWindowById( event.GetId() )
if ctl.IsValid():
self.log.write('new value = %s\n' % ctl.GetValue() )
def OnNumberSelect( self, event ):
value = event.GetString()
# Format choice to fit into format for #{9}.#{2}, with sign position reserved:
# (ordinal + fraction == 11 + decimal point + sign == 13)
#
# Note: since self.floatctrl a right-aligned control, you could also just use
# "%.2f", but this wouldn't work properly for a left-aligned control.
# (See .SetValue() documentation in Overview.)
#
if value:
floattext = "%13.2f" % float(value)
else:
floattext = value # clear the value again
try:
self.floatctrl.SetValue(floattext)
except:
type, value, tb = sys.exc_info()
for line in traceback.format_exception_only(type, value):
self.log.write(line)
# ---------------------------------------------------------------------
class TestMaskedTextCtrls(wxNotebook):
def __init__(self, parent, id, log):
wxNotebook.__init__(self, parent, id)
self.log = log
win = demoPage1(self, log)
self.AddPage(win, "General examples")
win = demoPage2(self, log)
self.AddPage(win, 'Auto-formatted controls')
win = demoPage3(self, log)
self.AddPage(win, "Using default values")
win = demoPage4(self, log)
self.AddPage(win, 'Using auto-complete fields')
win = demoPage5(self, log)
self.AddPage(win, 'Other masked controls')
#----------------------------------------------------------------------------
def runTest(frame, nb, log):
testWin = TestMaskedTextCtrls(nb, -1, log)
return testWin
def RunStandalone():
app = wxPySimpleApp()
frame = wxFrame(None, -1, "Test wxMaskedTextCtrl", size=(640, 480))
win = TestMaskedTextCtrls(frame, -1, sys.stdout)
frame.Show(True)
app.MainLoop()
#----------------------------------------------------------------------------
if __name__ == "__main__":
RunStandalone()
overview = """<html>
<PRE><FONT SIZE=-1>
""" + overviewdoc + """
</FONT></PRE>
"""
if __name__ == "__main__":
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -0,0 +1,47 @@
import wx # This module uses the new wx namespace
from wx import html
from Main import opj
#----------------------------------------------------------------------
class TestPanel(wx.Panel):
def __init__(self, parent, log):
self.log = log
wx.Panel.__init__(self, parent, -1)
hwin = html.HtmlWindow(self, -1)
hwin.LoadFile(opj('data/wxPackage.html'))
sizer = wx.BoxSizer(wx.VERTICAL)
sizer.Add(hwin, 1, wx.EXPAND)
self.SetSizer(sizer)
#----------------------------------------------------------------------
def runTest(frame, nb, log):
win = TestPanel(nb, log)
return win
#----------------------------------------------------------------------
overview = """<html><body>
<h2><center>Using the New Namespace</center></h2>
This sample isn't really a demo, but rather a place to display the
introductory doc for using the new namespace.
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -136,3 +136,12 @@ and the second will show #2 (<i>working as of 2.3.2</i>)
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

148
wxPython/demo/PopupMenu.py Normal file
View File

@@ -0,0 +1,148 @@
from wxPython.wx import *
import images
#----------------------------------------------------------------------
text = """\
Right-click on the panel (or Ctrl-click on the Mac) to show a popup
menu. Then look at the code for this sample. Notice how the
PopupMenu method is similar to the ShowModal method of a wxDialog in
that it doesn't return until the popup menu has been dismissed. The
event handlers for the popup menu items can either be attached to the
menu itself, or to the window that invokes PopupMenu.
"""
#----------------------------------------------------------------------
class TestPanel(wxPanel):
def __init__(self, parent, log):
self.log = log
wxPanel.__init__(self, parent, -1)
box = wxBoxSizer(wxVERTICAL)
# Make and layout the controls
fs = self.GetFont().GetPointSize()
bf = wxFont(fs+4, wxSWISS, wxNORMAL, wxBOLD)
nf = wxFont(fs+2, wxSWISS, wxNORMAL, wxNORMAL)
t = wxStaticText(self, -1, "PopupMenu")
t.SetFont(bf)
box.Add(t, 0, wxCENTER|wxALL, 5)
box.Add(wxStaticLine(self, -1), 0, wxEXPAND)
box.Add(10,20)
t = wxStaticText(self, -1, text)
t.SetFont(nf)
box.Add(t, 0, wxCENTER|wxALL, 5)
self.SetSizer(box)
EVT_RIGHT_UP(self, self.OnRightClick)
def OnRightClick(self, event):
self.log.WriteText("OnRightClick\n")
# only do this part the first time so the events are only bound once
if not hasattr(self, "popupID1"):
self.popupID1 = wxNewId()
self.popupID2 = wxNewId()
self.popupID3 = wxNewId()
self.popupID4 = wxNewId()
self.popupID5 = wxNewId()
self.popupID6 = wxNewId()
self.popupID7 = wxNewId()
self.popupID8 = wxNewId()
self.popupID9 = wxNewId()
EVT_MENU(self, self.popupID1, self.OnPopupOne)
EVT_MENU(self, self.popupID2, self.OnPopupTwo)
EVT_MENU(self, self.popupID3, self.OnPopupThree)
EVT_MENU(self, self.popupID4, self.OnPopupFour)
EVT_MENU(self, self.popupID5, self.OnPopupFive)
EVT_MENU(self, self.popupID6, self.OnPopupSix)
EVT_MENU(self, self.popupID7, self.OnPopupSeven)
EVT_MENU(self, self.popupID8, self.OnPopupEIght)
EVT_MENU(self, self.popupID9, self.OnPopupNine)
# make a menu
menu = wxMenu()
# Show how to put an icon in the menu
item = wxMenuItem(menu, self.popupID1,"One")
item.SetBitmap(images.getSmilesBitmap())
menu.AppendItem(item)
# add some other items
menu.Append(self.popupID2, "Two")
menu.Append(self.popupID3, "Three")
menu.Append(self.popupID4, "Four")
menu.Append(self.popupID5, "Five")
menu.Append(self.popupID6, "Six")
# make a submenu
sm = wxMenu()
sm.Append(self.popupID8, "sub item 1")
sm.Append(self.popupID9, "sub item 1")
menu.AppendMenu(self.popupID7, "Test Submenu", sm)
# Popup the menu. If an item is selected then its handler
# will be called before PopupMenu returns.
self.PopupMenu(menu, event.GetPosition())
menu.Destroy()
def OnPopupOne(self, event):
self.log.WriteText("Popup one\n")
def OnPopupTwo(self, event):
self.log.WriteText("Popup two\n")
def OnPopupThree(self, event):
self.log.WriteText("Popup three\n")
def OnPopupFour(self, event):
self.log.WriteText("Popup four\n")
def OnPopupFive(self, event):
self.log.WriteText("Popup five\n")
def OnPopupSix(self, event):
self.log.WriteText("Popup six\n")
def OnPopupSeven(self, event):
self.log.WriteText("Popup seven\n")
def OnPopupEIght(self, event):
self.log.WriteText("Popup eight\n")
def OnPopupNine(self, event):
self.log.WriteText("Popup nine\n")
#----------------------------------------------------------------------
def runTest(frame, nb, log):
win = TestPanel(nb, log)
return win
#----------------------------------------------------------------------
overview = """<html><body>
<h2><center>PopupMenu</center></h2>
""" + text + """
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -79,7 +79,7 @@ class MyPrintout(wxPrintout):
#-------------------------------------------
self.canvas.DoDrawing(dc)
self.canvas.DoDrawing(dc, True)
dc.DrawText("Page: %d" % page, marginX/2, maxY-marginY)
return True
@@ -176,3 +176,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -1,20 +1,18 @@
from wxPython.lib.PyCrust import shell, version
from wx import py
#----------------------------------------------------------------------
intro = 'Welcome To PyCrust %s - The Flakiest Python Shell' % version.VERSION
intro = 'Welcome To PyCrust %s - The Flakiest Python Shell' % py.version.VERSION
def runTest(frame, nb, log):
win = shell.Shell(nb, -1, introText=intro)
win = py.crust.Crust(nb, intro=intro)
return win
#----------------------------------------------------------------------
overview = shell.__doc__
overview = py.filling.__doc__ + "\n\n" + py.crust.__doc__
if __name__ == '__main__':
import sys,os

View File

@@ -1,28 +0,0 @@
from wxPython.wx import wxSplitterWindow
from wxPython.lib.PyCrust import shell, version, filling
#----------------------------------------------------------------------
intro = 'Welcome To PyCrust %s - The Flakiest Python Shell' % version.VERSION
def runTest(frame, nb, log):
win = wxSplitterWindow(nb, -1, size=(640, 480))
shellWin = shell.Shell(win, -1, introText=intro)
fillingWin = filling.Filling(win, -1, size=(640, 480),
rootObject=shellWin.interp.locals,
rootIsNamespace=1
)
win.SplitHorizontally(shellWin, fillingWin)
return win
#----------------------------------------------------------------------
overview = filling.__doc__
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

23
wxPython/demo/PyShell.py Normal file
View File

@@ -0,0 +1,23 @@
from wx import py
#----------------------------------------------------------------------
intro = 'Welcome To PyCrust %s - The Flakiest Python Shell' % py.version.VERSION
def runTest(frame, nb, log):
win = py.shell.Shell(nb, -1, introText=intro)
return win
#----------------------------------------------------------------------
overview = py.shell.__doc__
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -83,3 +83,10 @@ This demo is a contrived example of defining an event class in wxPython and send
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -0,0 +1,122 @@
from wxPython.wx import *
import images
#----------------------------------------------------------------------
class TestFrame(wxFrame):
def __init__(self, parent, log):
self.log = log
wxFrame.__init__(self, parent, -1, "Shaped Window",
style =
wxFRAME_SHAPED
| wxSIMPLE_BORDER
| wxFRAME_NO_TASKBAR
| wxSTAY_ON_TOP
)
self.hasShape = False
self.delta = wxPoint(0,0)
EVT_LEFT_DCLICK(self, self.OnDoubleClick)
EVT_LEFT_DOWN(self, self.OnLeftDown)
EVT_LEFT_UP(self, self.OnLeftUp)
EVT_MOTION(self, self.OnMouseMove)
EVT_RIGHT_UP(self, self.OnExit)
EVT_PAINT(self, self.OnPaint)
self.bmp = images.getTuxBitmap()
w, h = self.bmp.GetWidth(), self.bmp.GetHeight()
self.SetClientSize( (w, h) )
if wxPlatform != "__WXMAC__":
# wxMac clips the tooltip to the window shape, YUCK!!!
self.SetToolTipString("Right-click to close the window\n"
"Double-click the image to set/unset the window shape")
if wxPlatform == "__WXGTK__":
# wxGTK requires that the window be created before you can
# set its shape, so delay the call to SetWindowShape until
# this event.
EVT_WINDOW_CREATE(self, self.SetWindowShape)
else:
# On wxMSW and wxMac the window has already been created, so go for it.
self.SetWindowShape()
dc = wxClientDC(self)
dc.DrawBitmap(self.bmp, 0,0, True)
def SetWindowShape(self, *evt):
# Use the bitmap's mask to determine the region
r = wxRegionFromBitmap(self.bmp)
self.hasShape = self.SetShape(r)
def OnDoubleClick(self, evt):
if self.hasShape:
self.SetShape(wxRegion())
self.hasShape = False
else:
self.SetWindowShape()
def OnPaint(self, evt):
dc = wxPaintDC(self)
dc.DrawBitmap(self.bmp, 0,0, True)
def OnExit(self, evt):
self.Close()
def OnLeftDown(self, evt):
self.CaptureMouse()
pos = self.ClientToScreen(evt.GetPosition())
origin = self.GetPosition()
dx = pos.x - origin.x
dy = pos.y - origin.y
self.delta = wxPoint(dx, dy)
def OnLeftUp(self, evt):
if self.HasCapture():
self.ReleaseMouse()
def OnMouseMove(self, evt):
if evt.Dragging() and evt.LeftIsDown():
pos = self.ClientToScreen(evt.GetPosition())
fp = (pos.x - self.delta.x, pos.y - self.delta.y)
self.Move(fp)
#----------------------------------------------------------------------
def runTest(frame, nb, log):
win = TestFrame(nb, log)
frame.otherWin = win
win.Show(True)
#----------------------------------------------------------------------
overview = """<html><body>
<h2><center>Shaped Window</center></h2>
Top level windows now have a SetShape method that lets you set a
non-rectangular shape for the window using a wxRegion. All pixels
outside of the region will not be drawn and the window will not be
sensitive to the mouse in those areas either.
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -141,11 +141,11 @@ def makeBoxInBox(win):
box.Add(wxButton(win, 1010, "one"), 0, wxEXPAND)
box2 = wxBoxSizer(wxHORIZONTAL)
box2.AddMany([ (wxButton(win, 1010, "two"), 0, wxEXPAND),
(wxButton(win, 1010, "three"), 0, wxEXPAND),
(wxButton(win, 1010, "four"), 0, wxEXPAND),
(wxButton(win, 1010, "five"), 0, wxEXPAND),
])
box2.Add(wxButton(win, 1010, "two"), 0, wxEXPAND)
btn3 = wxButton(win, 1010, "three")
box2.Add(btn3, 0, wxEXPAND)
box2.Add(wxButton(win, 1010, "four"), 0, wxEXPAND)
box2.Add(wxButton(win, 1010, "five"), 0, wxEXPAND)
box3 = wxBoxSizer(wxVERTICAL)
box3.AddMany([ (wxButton(win, 1010, "six"), 0, wxEXPAND),
@@ -159,6 +159,8 @@ def makeBoxInBox(win):
box.Add(wxButton(win, 1010, "ten"), 0, wxEXPAND)
##box.Hide(btn3)
return box
#----------------------------------------------------------------------

View File

@@ -1,379 +0,0 @@
#!/usr/bin/python
"""This is SlashDot 1.2
It's the obligatory Slashdot.org headlines reader that
any modern widget set/library must have in order to be taken
seriously :-)
Usage is quite simple; wxSlash attempts to download the
'ultramode.txt' file from http://slashdot.org, which
contains the headlines in a computer friendly format. It
then displays said headlines in a wxWindows list control.
You can read articles using either Python's html library
or an external browser. Uncheck the 'browser->internal' menu
item to use the latter option. Use the settings dialog box
to set which external browser is started.
This code is available under the wxWindows license, see
elsewhere. If you modify this code, be aware of the fact
that slashdot.org's maintainer, CmdrTaco, explicitly asks
'ultramode.txt' downloaders not to do this automatically
more than twice per hour. If this feature is abused,
CmdrTaco may remove the ultramode file completely and that
will make a *lot* of people unhappy.
I want to thank Alex Shnitman whose slashes.pl
(Perl/GTK) script gave me the idea for this applet.
Have fun with it,
Harm van der Heijden (H.v.d.Heijden@phys.tue.nl)
"""
from wxPython.wx import *
from httplib import HTTP
from htmllib import HTMLParser
import os
import re
import formatter
class HTMLTextView(wxFrame):
def __init__(self, parent, id, title='HTMLTextView', url=None):
wxFrame.__init__(self, parent, id, title, wxPyDefaultPosition,
wxSize(600,400))
EVT_CLOSE(self, self.OnCloseWindow)
self.mainmenu = wxMenuBar()
menu = wxMenu()
menu.Append(201, '&Open URL...', 'Open URL')
EVT_MENU(self, 201, self.OnFileOpen)
menu.Append(209, 'E&xit', 'Exit viewer')
EVT_MENU(self, 209, self.OnFileExit)
self.mainmenu.Append(menu, '&File')
self.SetMenuBar(self.mainmenu)
self.CreateStatusBar(1)
self.text = wxTextCtrl(self, -1, "", wxPyDefaultPosition,
wxPyDefaultSize, wxTE_MULTILINE | wxTE_READONLY)
if (url):
self.OpenURL(url)
def logprint(self, x):
self.SetStatusText(x)
def OpenURL(self, url):
self.url = url
m = re.match('file:(\S+)\s*', url)
if m:
f = open(m.groups()[0],'r')
else:
m = re.match('http://([^/]+)(/\S*)\s*', url)
if m:
host = m.groups()[0]
path = m.groups()[1]
else:
m = re.match('http://(\S+)\s*', url)
if not m:
# Invalid URL
self.logprint("Invalid or unsupported URL: %s" % (url))
return
host = m.groups()[0]
path = ''
f = RetrieveAsFile(host,path,self.logprint)
if not f:
self.logprint("Could not open %s" % (url))
return
self.logprint("Receiving data...")
data = f.read()
tmp = open('tmphtml.txt','w')
fmt = formatter.AbstractFormatter(formatter.DumbWriter(tmp))
p = HTMLParser(fmt)
self.logprint("Parsing data...")
p.feed(data)
p.close()
tmp.close()
tmp = open('tmphtml.txt', 'r')
self.text.SetValue(tmp.read())
self.SetTitle(url)
self.logprint(url)
def OnFileOpen(self, event):
dlg = wxTextEntryDialog(self, "Enter URL to open:", "")
if dlg.ShowModal() == wxID_OK:
url = dlg.GetValue()
else:
url = None
if url:
self.OpenURL(url)
def OnFileExit(self, event):
self.Close()
def OnCloseWindow(self, event):
self.Destroy()
def ParseSlashdot(f):
art_sep = re.compile('%%\r?\n')
line_sep = re.compile('\r?\n')
data = f.read()
list = art_sep.split(data)
art_list = []
for i in range(1,len(list)-1):
art_list.append(line_sep.split(list[i]))
return art_list
def myprint(x):
print x
def RetrieveAsFile(host, path='', logprint = myprint):
try:
h = HTTP(host)
except:
logprint("Failed to create HTTP connection to %s... is the network available?" % (host))
return None
h.putrequest('GET',path)
h.putheader('Accept','text/html')
h.putheader('Accept','text/plain')
h.endheaders()
errcode, errmsg, headers = h.getreply()
if errcode != 200:
logprint("HTTP error code %d: %s" % (errcode, errmsg))
return None
f = h.getfile()
# f = open('/home/harm/ultramode.txt','r')
return f
class AppStatusBar(wxStatusBar):
def __init__(self, parent):
wxStatusBar.__init__(self,parent, -1)
self.SetFieldsCount(2)
self.SetStatusWidths([-1, 100])
self.but = wxButton(self, 1001, "Refresh")
EVT_BUTTON(self, 1001, parent.OnViewRefresh)
EVT_SIZE(self, self.OnSize)
self.OnSize(None)
def logprint(self,x):
self.SetStatusText(x,0)
def OnSize(self, event):
rect = self.GetFieldRect(1)
self.but.SetPosition(wxPoint(rect.x+2, rect.y+2))
self.but.SetSize(wxSize(rect.width-4, rect.height-4))
# This is a simple timer class to start a function after a short delay;
class QuickTimer(wxTimer):
def __init__(self, func, wait=100):
wxTimer.__init__(self)
self.callback = func
self.Start(wait); # wait .1 second (.001 second doesn't work. why?)
def Notify(self):
self.Stop();
apply(self.callback, ());
class AppFrame(wxFrame):
def __init__(self, parent, id, title):
wxFrame.__init__(self, parent, id, title, wxPyDefaultPosition,
wxSize(650, 250))
# if the window manager closes the window:
EVT_CLOSE(self, self.OnCloseWindow);
# Now Create the menu bar and items
self.mainmenu = wxMenuBar()
menu = wxMenu()
menu.Append(209, 'E&xit', 'Enough of this already!')
EVT_MENU(self, 209, self.OnFileExit)
self.mainmenu.Append(menu, '&File')
menu = wxMenu()
menu.Append(210, '&Refresh', 'Refresh headlines')
EVT_MENU(self, 210, self.OnViewRefresh)
menu.Append(211, '&Slashdot Index', 'View Slashdot index')
EVT_MENU(self, 211, self.OnViewIndex)
menu.Append(212, 'Selected &Article', 'View selected article')
EVT_MENU(self, 212, self.OnViewArticle)
self.mainmenu.Append(menu, '&View')
menu = wxMenu()
menu.Append(220, '&Internal', 'Use internal text browser',True)
menu.Check(220, True)
self.UseInternal = 1;
EVT_MENU(self, 220, self.OnBrowserInternal)
menu.Append(222, '&Settings...', 'External browser Settings')
EVT_MENU(self, 222, self.OnBrowserSettings)
self.mainmenu.Append(menu, '&Browser')
menu = wxMenu()
menu.Append(230, '&About', 'Some documentation');
EVT_MENU(self, 230, self.OnAbout)
self.mainmenu.Append(menu, '&Help')
self.SetMenuBar(self.mainmenu)
if wxPlatform == '__WXGTK__':
# I like lynx. Also Netscape 4.5 doesn't react to my cmdline opts
self.BrowserSettings = "xterm -e lynx %s &"
elif wxPlatform == '__WXMSW__':
# netscape 4.x likes to hang out here...
self.BrowserSettings = '\\progra~1\\Netscape\\Communicator\\Program\\netscape.exe %s'
else:
# a wild guess...
self.BrowserSettings = 'netscape %s'
# A status bar to tell people what's happening
self.sb = AppStatusBar(self)
self.SetStatusBar(self.sb)
self.list = wxListCtrl(self, 1100, style=wxLC_REPORT)
self.list.InsertColumn(0, 'Subject')
self.list.InsertColumn(1, 'Date')
self.list.InsertColumn(2, 'Posted by')
self.list.InsertColumn(3, 'Comments')
self.list.SetColumnWidth(0, 300)
self.list.SetColumnWidth(1, 150)
self.list.SetColumnWidth(2, 100)
self.list.SetColumnWidth(3, 100)
EVT_LIST_ITEM_SELECTED(self, 1100, self.OnItemSelected)
EVT_LEFT_DCLICK(self.list, self.OnLeftDClick)
self.logprint("Connecting to slashdot... Please wait.")
# wxYield doesn't yet work here. That's why we use a timer
# to make sure that we see some GUI stuff before the slashdot
# file is transfered.
self.timer = QuickTimer(self.DoRefresh, 1000)
def logprint(self, x):
self.sb.logprint(x)
def OnFileExit(self, event):
self.Destroy()
def DoRefresh(self):
f = RetrieveAsFile('slashdot.org','/ultramode.txt',self.sb.logprint)
art_list = ParseSlashdot(f)
self.list.DeleteAllItems()
self.url = []
self.current = -1
i = 0;
for article in art_list:
self.list.InsertStringItem(i, article[0])
self.list.SetStringItem(i, 1, article[2])
self.list.SetStringItem(i, 2, article[3])
self.list.SetStringItem(i, 3, article[6])
self.url.append(article[1])
i = i + 1
self.logprint("File retrieved OK.")
def OnViewRefresh(self, event):
self.logprint("Connecting to slashdot... Please wait.");
wxYield()
self.DoRefresh()
def DoViewIndex(self):
if self.UseInternal:
self.view = HTMLTextView(self, -1, 'slashdot.org',
'http://slashdot.org')
self.view.Show(True)
else:
self.logprint(self.BrowserSettings % ('http://slashdot.org'))
#os.system(self.BrowserSettings % ('http://slashdot.org'))
wxExecute(self.BrowserSettings % ('http://slashdot.org'))
self.logprint("OK")
def OnViewIndex(self, event):
self.logprint("Starting browser... Please wait.")
wxYield()
self.DoViewIndex()
def DoViewArticle(self):
if self.current<0: return
url = self.url[self.current]
if self.UseInternal:
self.view = HTMLTextView(self, -1, url, url)
self.view.Show(True)
else:
self.logprint(self.BrowserSettings % (url))
os.system(self.BrowserSettings % (url))
self.logprint("OK")
def OnViewArticle(self, event):
self.logprint("Starting browser... Please wait.")
wxYield()
self.DoViewArticle()
def OnBrowserInternal(self, event):
if self.mainmenu.Checked(220):
self.UseInternal = 1
else:
self.UseInternal = 0
def OnBrowserSettings(self, event):
dlg = wxTextEntryDialog(self, "Enter command to view URL.\nUse %s as a placeholder for the URL.", "", self.BrowserSettings);
if dlg.ShowModal() == wxID_OK:
self.BrowserSettings = dlg.GetValue()
def OnAbout(self, event):
dlg = wxMessageDialog(self, __doc__, "wxSlash", wxOK | wxICON_INFORMATION)
dlg.ShowModal()
def OnItemSelected(self, event):
self.current = event.m_itemIndex
self.logprint("URL: %s" % (self.url[self.current]))
def OnLeftDClick(self, event):
(x,y) = event.Position();
# Actually, we should convert x,y to logical coords using
# a dc, but only for a wxScrolledWindow widget.
# Now wxGTK derives wxListCtrl from wxScrolledWindow,
# and wxMSW from wxControl... So that doesn't work.
#dc = wxClientDC(self.list)
##self.list.PrepareDC(dc)
#x = dc.DeviceToLogicalX( event.GetX() )
#y = dc.DeviceToLogicalY( event.GetY() )
id = self.list.HitTest(wxPoint(x,y))
#print "Double click at %d %d" % (x,y), id
# Okay, we got a double click. Let's assume it's the current selection
wxYield()
self.OnViewArticle(event)
def OnCloseWindow(self, event):
self.Destroy()
#---------------------------------------------------------------------------
# if running standalone
if __name__ == '__main__':
class MyApp(wxApp):
def OnInit(self):
frame = AppFrame(None, -1, "Slashdot Breaking News")
frame.Show(True)
self.SetTopWindow(frame)
return True
app = MyApp(0)
app.MainLoop()
#---------------------------------------------------------------------------
# if running as part of the Demo Framework...
def runTest(frame, nb, log):
win = AppFrame(None, -1, "Slashdot Breaking News")
frame.otherWin = win
win.Show(True)
overview = __doc__
#----------------------------------------------------------------------------

View File

@@ -205,3 +205,12 @@ when the framework allows for it.
""" % os.path.join(os.path.dirname(wxPython.lib.printout.__file__), "printout.py")
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -244,3 +244,11 @@ ProcessEvent does, it processes it later from the context of the GUI
thread.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -121,3 +121,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -139,3 +139,12 @@ and then pass the unicode to the wxPython method.
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -110,3 +110,11 @@ else:
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

View File

@@ -1,7 +1,7 @@
<html>
<head>
<title>/home/others/projects/wx2.3/contrib/include/wx/stc/stc.h.html</title>
<meta name="Generator" content="Vim/6.0">
<title>/home/work/projects/wx2.4/contrib/include/wx/stc/stc.h.html</title>
<meta name="Generator" content="Vim/6.1">
</head>
<body bgcolor="#f5deb3" text="#000000">
<pre>
@@ -31,6 +31,30 @@
<font color="#a020f0">#include </font><font color="#ff00ff">&lt;wx/wx.h&gt;</font>
<font color="#a020f0">#include </font><font color="#ff00ff">&lt;wx/dnd.h&gt;</font>
<font color="#a020f0">#ifndef SWIG</font>
<font color="#0000ff">/*</font>
<font color="#0000ff"> * If we're using wx in Dynamic Library format do we</font>
<font color="#0000ff"> * want wxStyledTextCtrl to be in DLL form as well?</font>
<font color="#0000ff"> */</font>
<font color="#a020f0">#if defined(WXUSINGDLL) &amp;&amp; \</font>
<font color="#a020f0"> (defined(WXMAKING_STC_DLL) || defined(WXUSING_STC_DLL))</font>
<font color="#a020f0">#if defined(WXMAKING_STC_DLL)</font>
<font color="#0000ff">// When building the DLL WXSTC_DECLSPEC exports classes</font>
<font color="#a020f0"># define WXSTC_DECLSPEC WXEXPORT</font>
<font color="#a020f0">#elif defined(WXUSING_STC_DLL)</font>
<font color="#0000ff">// When using the DLL WXSTC_DECLSPEC imports classes</font>
<font color="#a020f0"># define WXSTC_DECLSPEC WXIMPORT</font>
<font color="#a020f0">#endif</font> <font color="#0000ff">// defined(WXBUILD_STC_DLL)</font>
<font color="#a020f0">#else</font>
<font color="#0000ff">// When building the static library nullify the effect of WXSTC_DECLSPEC</font>
<font color="#a020f0">#define WXSTC_DECLSPEC</font>
<font color="#a020f0">#endif</font> <font color="#0000ff">// WXUSINGDLL &amp;&amp; (WXMAKING_STC_DLL || WXUSING_STC_DLL)</font>
<font color="#a020f0">#endif</font> <font color="#0000ff">// SWIG</font>
<font color="#0000ff">//----------------------------------------------------------------------</font>
<font color="#0000ff">// Should a wxPopupWindow be used for the call tips and autocomplete windows?</font>
@@ -50,12 +74,6 @@
<font color="#a020f0">#define wxSTC_START </font><font color="#ff00ff">2000</font>
<font color="#a020f0">#define wxSTC_OPTIONAL_START </font><font color="#ff00ff">3000</font>
<font color="#a020f0">#define wxSTC_LEXER_START </font><font color="#ff00ff">4000</font>
<font color="#0000ff">// Redoes the next action on the undo history.</font>
<font color="#a020f0">#define wxSTC_CMD_REDO </font><font color="#ff00ff">2011</font>
<font color="#0000ff">// Select all the text in the document.</font>
<font color="#a020f0">#define wxSTC_CMD_SELECTALL </font><font color="#ff00ff">2013</font>
<font color="#a020f0">#define wxSTC_WS_INVISIBLE </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_WS_VISIBLEALWAYS </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_WS_VISIBLEAFTERINDENT </font><font color="#ff00ff">2</font>
@@ -66,6 +84,9 @@
<font color="#0000ff">// The SC_CP_UTF8 value can be used to enter Unicode mode.</font>
<font color="#0000ff">// This is the same value as CP_UTF8 in Windows</font>
<font color="#a020f0">#define wxSTC_CP_UTF8 </font><font color="#ff00ff">65001</font>
<font color="#0000ff">// The SC_CP_DBCS value can be used to indicate a DBCS mode for GTK+.</font>
<font color="#a020f0">#define wxSTC_CP_DBCS </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_MARKER_MAX </font><font color="#ff00ff">31</font>
<font color="#a020f0">#define wxSTC_MARK_CIRCLE </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_MARK_ROUNDRECT </font><font color="#ff00ff">1</font>
@@ -96,6 +117,7 @@
<font color="#a020f0">#define wxSTC_MARK_BACKGROUND </font><font color="#ff00ff">22</font>
<font color="#a020f0">#define wxSTC_MARK_DOTDOTDOT </font><font color="#ff00ff">23</font>
<font color="#a020f0">#define wxSTC_MARK_ARROWS </font><font color="#ff00ff">24</font>
<font color="#a020f0">#define wxSTC_MARK_PIXMAP </font><font color="#ff00ff">25</font>
<font color="#a020f0">#define wxSTC_MARK_CHARACTER </font><font color="#ff00ff">10000</font>
<font color="#0000ff">// Markers used for outlining column.</font>
@@ -174,22 +196,20 @@
<font color="#a020f0">#define wxSTC_FIND_MATCHCASE </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_FIND_WORDSTART </font><font color="#ff00ff">0x00100000</font>
<font color="#a020f0">#define wxSTC_FIND_REGEXP </font><font color="#ff00ff">0x00200000</font>
<font color="#0000ff">// Undo one action in the undo history.</font>
<font color="#a020f0">#define wxSTC_CMD_UNDO </font><font color="#ff00ff">2176</font>
<font color="#0000ff">// Cut the selection to the clipboard.</font>
<font color="#a020f0">#define wxSTC_CMD_CUT </font><font color="#ff00ff">2177</font>
<font color="#0000ff">// Copy the selection to the clipboard.</font>
<font color="#a020f0">#define wxSTC_CMD_COPY </font><font color="#ff00ff">2178</font>
<font color="#0000ff">// Paste the contents of the clipboard into the document replacing the selection.</font>
<font color="#a020f0">#define wxSTC_CMD_PASTE </font><font color="#ff00ff">2179</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELBASE </font><font color="#ff00ff">0x400</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELWHITEFLAG </font><font color="#ff00ff">0x1000</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELHEADERFLAG </font><font color="#ff00ff">0x2000</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELBOXHEADERFLAG </font><font color="#ff00ff">0x4000</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELBOXFOOTERFLAG </font><font color="#ff00ff">0x8000</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELCONTRACTED </font><font color="#ff00ff">0x10000</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELUNINDENT </font><font color="#ff00ff">0x20000</font>
<font color="#a020f0">#define wxSTC_FOLDLEVELNUMBERMASK </font><font color="#ff00ff">0x0FFF</font>
<font color="#a020f0">#define wxSTC_FOLDFLAG_LINEBEFORE_EXPANDED </font><font color="#ff00ff">0x0002</font>
<font color="#a020f0">#define wxSTC_FOLDFLAG_LINEBEFORE_CONTRACTED </font><font color="#ff00ff">0x0004</font>
<font color="#a020f0">#define wxSTC_FOLDFLAG_LINEAFTER_EXPANDED </font><font color="#ff00ff">0x0008</font>
<font color="#a020f0">#define wxSTC_FOLDFLAG_LINEAFTER_CONTRACTED </font><font color="#ff00ff">0x0010</font>
<font color="#a020f0">#define wxSTC_FOLDFLAG_LEVELNUMBERS </font><font color="#ff00ff">0x0040</font>
<font color="#a020f0">#define wxSTC_FOLDFLAG_BOX </font><font color="#ff00ff">0x0001</font>
<font color="#a020f0">#define wxSTC_TIME_FOREVER </font><font color="#ff00ff">10000000</font>
<font color="#a020f0">#define wxSTC_WRAP_NONE </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_WRAP_WORD </font><font color="#ff00ff">1</font>
@@ -197,163 +217,11 @@
<font color="#a020f0">#define wxSTC_CACHE_CARET </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_CACHE_PAGE </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_CACHE_DOCUMENT </font><font color="#ff00ff">3</font>
<font color="#0000ff">// Move caret down one line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDOWN </font><font color="#ff00ff">2300</font>
<font color="#0000ff">// Move caret down one line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDOWNEXTEND </font><font color="#ff00ff">2301</font>
<font color="#0000ff">// Move caret up one line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEUP </font><font color="#ff00ff">2302</font>
<font color="#0000ff">// Move caret up one line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEUPEXTEND </font><font color="#ff00ff">2303</font>
<font color="#0000ff">// Move caret left one character.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARLEFT </font><font color="#ff00ff">2304</font>
<font color="#0000ff">// Move caret left one character extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARLEFTEXTEND </font><font color="#ff00ff">2305</font>
<font color="#0000ff">// Move caret right one character.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARRIGHT </font><font color="#ff00ff">2306</font>
<font color="#0000ff">// Move caret right one character extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARRIGHTEXTEND </font><font color="#ff00ff">2307</font>
<font color="#0000ff">// Move caret left one word.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDLEFT </font><font color="#ff00ff">2308</font>
<font color="#0000ff">// Move caret left one word extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDLEFTEXTEND </font><font color="#ff00ff">2309</font>
<font color="#0000ff">// Move caret right one word.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDRIGHT </font><font color="#ff00ff">2310</font>
<font color="#0000ff">// Move caret right one word extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDRIGHTEXTEND </font><font color="#ff00ff">2311</font>
<font color="#0000ff">// Move caret to first position on line.</font>
<font color="#a020f0">#define wxSTC_CMD_HOME </font><font color="#ff00ff">2312</font>
<font color="#0000ff">// Move caret to first position on line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_HOMEEXTEND </font><font color="#ff00ff">2313</font>
<font color="#0000ff">// Move caret to last position on line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEEND </font><font color="#ff00ff">2314</font>
<font color="#0000ff">// Move caret to last position on line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEENDEXTEND </font><font color="#ff00ff">2315</font>
<font color="#0000ff">// Move caret to first position in document.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTSTART </font><font color="#ff00ff">2316</font>
<font color="#0000ff">// Move caret to first position in document extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTSTARTEXTEND </font><font color="#ff00ff">2317</font>
<font color="#0000ff">// Move caret to last position in document.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTEND </font><font color="#ff00ff">2318</font>
<font color="#0000ff">// Move caret to last position in document extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTENDEXTEND </font><font color="#ff00ff">2319</font>
<font color="#0000ff">// Move caret one page up.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEUP </font><font color="#ff00ff">2320</font>
<font color="#0000ff">// Move caret one page up extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEUPEXTEND </font><font color="#ff00ff">2321</font>
<font color="#0000ff">// Move caret one page down.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEDOWN </font><font color="#ff00ff">2322</font>
<font color="#0000ff">// Move caret one page down extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEDOWNEXTEND </font><font color="#ff00ff">2323</font>
<font color="#0000ff">// Switch from insert to overtype mode or the reverse.</font>
<font color="#a020f0">#define wxSTC_CMD_EDITTOGGLEOVERTYPE </font><font color="#ff00ff">2324</font>
<font color="#0000ff">// Cancel any modes such as call tip or auto-completion list display.</font>
<font color="#a020f0">#define wxSTC_CMD_CANCEL </font><font color="#ff00ff">2325</font>
<font color="#0000ff">// Delete the selection or if no selection, the character before the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_DELETEBACK </font><font color="#ff00ff">2326</font>
<font color="#0000ff">// If selection is empty or all on one line replace the selection with a tab character.</font>
<font color="#0000ff">// If more than one line selected, indent the lines.</font>
<font color="#a020f0">#define wxSTC_CMD_TAB </font><font color="#ff00ff">2327</font>
<font color="#0000ff">// Dedent the selected lines.</font>
<font color="#a020f0">#define wxSTC_CMD_BACKTAB </font><font color="#ff00ff">2328</font>
<font color="#0000ff">// Insert a new line, may use a CRLF, CR or LF depending on EOL mode.</font>
<font color="#a020f0">#define wxSTC_CMD_NEWLINE </font><font color="#ff00ff">2329</font>
<font color="#0000ff">// Insert a Form Feed character.</font>
<font color="#a020f0">#define wxSTC_CMD_FORMFEED </font><font color="#ff00ff">2330</font>
<font color="#0000ff">// Move caret to before first visible character on line.</font>
<font color="#0000ff">// If already there move to first character on line.</font>
<font color="#a020f0">#define wxSTC_CMD_VCHOME </font><font color="#ff00ff">2331</font>
<font color="#0000ff">// Like VCHome but extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_VCHOMEEXTEND </font><font color="#ff00ff">2332</font>
<font color="#0000ff">// Magnify the displayed text by increasing the sizes by 1 point.</font>
<font color="#a020f0">#define wxSTC_CMD_ZOOMIN </font><font color="#ff00ff">2333</font>
<font color="#0000ff">// Make the displayed text smaller by decreasing the sizes by 1 point.</font>
<font color="#a020f0">#define wxSTC_CMD_ZOOMOUT </font><font color="#ff00ff">2334</font>
<font color="#0000ff">// Delete the word to the left of the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_DELWORDLEFT </font><font color="#ff00ff">2335</font>
<font color="#0000ff">// Delete the word to the right of the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_DELWORDRIGHT </font><font color="#ff00ff">2336</font>
<font color="#0000ff">// Cut the line containing the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_LINECUT </font><font color="#ff00ff">2337</font>
<font color="#0000ff">// Delete the line containing the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDELETE </font><font color="#ff00ff">2338</font>
<font color="#0000ff">// Switch the current line with the previous.</font>
<font color="#a020f0">#define wxSTC_CMD_LINETRANSPOSE </font><font color="#ff00ff">2339</font>
<font color="#0000ff">// Transform the selection to lower case.</font>
<font color="#a020f0">#define wxSTC_CMD_LOWERCASE </font><font color="#ff00ff">2340</font>
<font color="#0000ff">// Transform the selection to upper case.</font>
<font color="#a020f0">#define wxSTC_CMD_UPPERCASE </font><font color="#ff00ff">2341</font>
<font color="#0000ff">// Scroll the document down, keeping the caret visible.</font>
<font color="#a020f0">#define wxSTC_CMD_LINESCROLLDOWN </font><font color="#ff00ff">2342</font>
<font color="#0000ff">// Scroll the document up, keeping the caret visible.</font>
<font color="#a020f0">#define wxSTC_CMD_LINESCROLLUP </font><font color="#ff00ff">2343</font>
<font color="#0000ff">// Delete the selection or if no selection, the character before the caret.</font>
<font color="#0000ff">// Will not delete the character before at the start of a line.</font>
<font color="#a020f0">#define wxSTC_CMD_DELETEBACKNOTLINE </font><font color="#ff00ff">2344</font>
<font color="#0000ff">// Move caret to first position on display line.</font>
<font color="#a020f0">#define wxSTC_CMD_HOMEDISPLAY </font><font color="#ff00ff">2345</font>
<font color="#0000ff">// Move caret to first position on display line extending selection to </font>
<font color="#0000ff">// new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_HOMEDISPLAYEXTEND </font><font color="#ff00ff">2346</font>
<font color="#0000ff">// Move caret to last position on display line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEENDDISPLAY </font><font color="#ff00ff">2347</font>
<font color="#0000ff">// Move caret to last position on display line extending selection to new </font>
<font color="#0000ff">// caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEENDDISPLAYEXTEND </font><font color="#ff00ff">2348</font>
<font color="#a020f0">#define wxSTC_EDGE_NONE </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_EDGE_LINE </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_EDGE_BACKGROUND </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_CURSORNORMAL -</font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_CURSORWAIT </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_CURSORWAIT </font><font color="#ff00ff">4</font>
<font color="#0000ff">// Constants for use with SetVisiblePolicy, similar to SetCaretPolicy.</font>
<font color="#a020f0">#define wxSTC_VISIBLE_SLOP </font><font color="#ff00ff">0x01</font>
@@ -461,6 +329,11 @@
<font color="#a020f0">#define wxSTC_LEX_BAAN </font><font color="#ff00ff">31</font>
<font color="#a020f0">#define wxSTC_LEX_MATLAB </font><font color="#ff00ff">32</font>
<font color="#a020f0">#define wxSTC_LEX_SCRIPTOL </font><font color="#ff00ff">33</font>
<font color="#a020f0">#define wxSTC_LEX_ASM </font><font color="#ff00ff">34</font>
<font color="#a020f0">#define wxSTC_LEX_CPPNOCASE </font><font color="#ff00ff">35</font>
<font color="#a020f0">#define wxSTC_LEX_FORTRAN </font><font color="#ff00ff">36</font>
<font color="#a020f0">#define wxSTC_LEX_F77 </font><font color="#ff00ff">37</font>
<font color="#a020f0">#define wxSTC_LEX_CSS </font><font color="#ff00ff">38</font>
<font color="#0000ff">// When a lexer specifies its language as SCLEX_AUTOMATIC it receives a</font>
<font color="#0000ff">// value assigned in sequence from SCLEX_AUTOMATIC+1.</font>
@@ -729,6 +602,7 @@
<font color="#a020f0">#define wxSTC_ERR_DIFF_ADDITION </font><font color="#ff00ff">11</font>
<font color="#a020f0">#define wxSTC_ERR_DIFF_DELETION </font><font color="#ff00ff">12</font>
<font color="#a020f0">#define wxSTC_ERR_DIFF_MESSAGE </font><font color="#ff00ff">13</font>
<font color="#a020f0">#define wxSTC_ERR_PHP </font><font color="#ff00ff">14</font>
<font color="#0000ff">// Lexical states for SCLEX_BATCH</font>
<font color="#a020f0">#define wxSTC_BAT_DEFAULT </font><font color="#ff00ff">0</font>
@@ -775,24 +649,31 @@
<font color="#a020f0">#define wxSTC_AVE_COMMENT </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_AVE_NUMBER </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_AVE_WORD </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_AVE_KEYWORD </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_AVE_STATEMENT </font><font color="#ff00ff">5</font>
<font color="#a020f0">#define wxSTC_AVE_STRING </font><font color="#ff00ff">6</font>
<font color="#a020f0">#define wxSTC_AVE_ENUM </font><font color="#ff00ff">7</font>
<font color="#a020f0">#define wxSTC_AVE_STRINGEOL </font><font color="#ff00ff">8</font>
<font color="#a020f0">#define wxSTC_AVE_IDENTIFIER </font><font color="#ff00ff">9</font>
<font color="#a020f0">#define wxSTC_AVE_OPERATOR </font><font color="#ff00ff">10</font>
<font color="#a020f0">#define wxSTC_AVE_WORD1 </font><font color="#ff00ff">11</font>
<font color="#a020f0">#define wxSTC_AVE_WORD2 </font><font color="#ff00ff">12</font>
<font color="#a020f0">#define wxSTC_AVE_WORD3 </font><font color="#ff00ff">13</font>
<font color="#a020f0">#define wxSTC_AVE_WORD4 </font><font color="#ff00ff">14</font>
<font color="#a020f0">#define wxSTC_AVE_WORD5 </font><font color="#ff00ff">15</font>
<font color="#a020f0">#define wxSTC_AVE_WORD6 </font><font color="#ff00ff">16</font>
<font color="#0000ff">// Lexical states for SCLEX_ADA</font>
<font color="#a020f0">#define wxSTC_ADA_DEFAULT </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_ADA_COMMENT </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_ADA_NUMBER </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_ADA_WORD </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_ADA_STRING </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_ADA_WORD </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_ADA_IDENTIFIER </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_ADA_NUMBER </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_ADA_DELIMITER </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_ADA_CHARACTER </font><font color="#ff00ff">5</font>
<font color="#a020f0">#define wxSTC_ADA_OPERATOR </font><font color="#ff00ff">6</font>
<font color="#a020f0">#define wxSTC_ADA_IDENTIFIER </font><font color="#ff00ff">7</font>
<font color="#a020f0">#define wxSTC_ADA_CHARACTEREOL </font><font color="#ff00ff">6</font>
<font color="#a020f0">#define wxSTC_ADA_STRING </font><font color="#ff00ff">7</font>
<font color="#a020f0">#define wxSTC_ADA_STRINGEOL </font><font color="#ff00ff">8</font>
<font color="#a020f0">#define wxSTC_ADA_LABEL </font><font color="#ff00ff">9</font>
<font color="#a020f0">#define wxSTC_ADA_COMMENTLINE </font><font color="#ff00ff">10</font>
<font color="#a020f0">#define wxSTC_ADA_ILLEGAL </font><font color="#ff00ff">11</font>
<font color="#0000ff">// Lexical states for SCLEX_BAAN</font>
<font color="#a020f0">#define wxSTC_BAAN_DEFAULT </font><font color="#ff00ff">0</font>
@@ -873,6 +754,252 @@
<font color="#a020f0">#define wxSTC_SCRIPTOL_COMMENTDOCKEYWORDERROR </font><font color="#ff00ff">18</font>
<font color="#a020f0">#define wxSTC_SCRIPTOL_COMMENTBASIC </font><font color="#ff00ff">19</font>
<font color="#0000ff">// Lexical states for SCLEX_ASM</font>
<font color="#a020f0">#define wxSTC_ASM_DEFAULT </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_ASM_COMMENT </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_ASM_NUMBER </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_ASM_STRING </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_ASM_OPERATOR </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_ASM_IDENTIFIER </font><font color="#ff00ff">5</font>
<font color="#a020f0">#define wxSTC_ASM_CPUINSTRUCTION </font><font color="#ff00ff">6</font>
<font color="#a020f0">#define wxSTC_ASM_MATHINSTRUCTION </font><font color="#ff00ff">7</font>
<font color="#a020f0">#define wxSTC_ASM_REGISTER </font><font color="#ff00ff">8</font>
<font color="#a020f0">#define wxSTC_ASM_DIRECTIVE </font><font color="#ff00ff">9</font>
<font color="#a020f0">#define wxSTC_ASM_DIRECTIVEOPERAND </font><font color="#ff00ff">10</font>
<font color="#0000ff">// Lexical states for SCLEX_FORTRAN</font>
<font color="#a020f0">#define wxSTC_F_DEFAULT </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_F_COMMENT </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_F_NUMBER </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_F_STRING1 </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_F_STRING2 </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_F_STRINGEOL </font><font color="#ff00ff">5</font>
<font color="#a020f0">#define wxSTC_F_OPERATOR </font><font color="#ff00ff">6</font>
<font color="#a020f0">#define wxSTC_F_IDENTIFIER </font><font color="#ff00ff">7</font>
<font color="#a020f0">#define wxSTC_F_WORD </font><font color="#ff00ff">8</font>
<font color="#a020f0">#define wxSTC_F_WORD2 </font><font color="#ff00ff">9</font>
<font color="#a020f0">#define wxSTC_F_WORD3 </font><font color="#ff00ff">10</font>
<font color="#a020f0">#define wxSTC_F_PREPROCESSOR </font><font color="#ff00ff">11</font>
<font color="#a020f0">#define wxSTC_F_OPERATOR2 </font><font color="#ff00ff">12</font>
<font color="#a020f0">#define wxSTC_F_LABEL </font><font color="#ff00ff">13</font>
<font color="#a020f0">#define wxSTC_F_CONTINUATION </font><font color="#ff00ff">14</font>
<font color="#0000ff">// Lexical states for SCLEX_CSS</font>
<font color="#a020f0">#define wxSTC_CSS_DEFAULT </font><font color="#ff00ff">0</font>
<font color="#a020f0">#define wxSTC_CSS_TAG </font><font color="#ff00ff">1</font>
<font color="#a020f0">#define wxSTC_CSS_CLASS </font><font color="#ff00ff">2</font>
<font color="#a020f0">#define wxSTC_CSS_PSEUDOCLASS </font><font color="#ff00ff">3</font>
<font color="#a020f0">#define wxSTC_CSS_UNKNOWN_PSEUDOCLASS </font><font color="#ff00ff">4</font>
<font color="#a020f0">#define wxSTC_CSS_OPERATOR </font><font color="#ff00ff">5</font>
<font color="#a020f0">#define wxSTC_CSS_IDENTIFIER </font><font color="#ff00ff">6</font>
<font color="#a020f0">#define wxSTC_CSS_UNKNOWN_IDENTIFIER </font><font color="#ff00ff">7</font>
<font color="#a020f0">#define wxSTC_CSS_VALUE </font><font color="#ff00ff">8</font>
<font color="#a020f0">#define wxSTC_CSS_COMMENT </font><font color="#ff00ff">9</font>
<font color="#a020f0">#define wxSTC_CSS_ID </font><font color="#ff00ff">10</font>
<font color="#a020f0">#define wxSTC_CSS_IMPORTANT </font><font color="#ff00ff">11</font>
<font color="#a020f0">#define wxSTC_CSS_DIRECTIVE </font><font color="#ff00ff">12</font>
<font color="#0000ff">//-----------------------------------------</font>
<font color="#0000ff">// Commands that can be bound to keystrokes</font>
<font color="#0000ff">// Redoes the next action on the undo history.</font>
<font color="#a020f0">#define wxSTC_CMD_REDO </font><font color="#ff00ff">2011</font>
<font color="#0000ff">// Select all the text in the document.</font>
<font color="#a020f0">#define wxSTC_CMD_SELECTALL </font><font color="#ff00ff">2013</font>
<font color="#0000ff">// Undo one action in the undo history.</font>
<font color="#a020f0">#define wxSTC_CMD_UNDO </font><font color="#ff00ff">2176</font>
<font color="#0000ff">// Cut the selection to the clipboard.</font>
<font color="#a020f0">#define wxSTC_CMD_CUT </font><font color="#ff00ff">2177</font>
<font color="#0000ff">// Copy the selection to the clipboard.</font>
<font color="#a020f0">#define wxSTC_CMD_COPY </font><font color="#ff00ff">2178</font>
<font color="#0000ff">// Paste the contents of the clipboard into the document replacing the selection.</font>
<font color="#a020f0">#define wxSTC_CMD_PASTE </font><font color="#ff00ff">2179</font>
<font color="#0000ff">// Clear the selection.</font>
<font color="#a020f0">#define wxSTC_CMD_CLEAR </font><font color="#ff00ff">2180</font>
<font color="#0000ff">// Move caret down one line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDOWN </font><font color="#ff00ff">2300</font>
<font color="#0000ff">// Move caret down one line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDOWNEXTEND </font><font color="#ff00ff">2301</font>
<font color="#0000ff">// Move caret up one line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEUP </font><font color="#ff00ff">2302</font>
<font color="#0000ff">// Move caret up one line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEUPEXTEND </font><font color="#ff00ff">2303</font>
<font color="#0000ff">// Move caret left one character.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARLEFT </font><font color="#ff00ff">2304</font>
<font color="#0000ff">// Move caret left one character extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARLEFTEXTEND </font><font color="#ff00ff">2305</font>
<font color="#0000ff">// Move caret right one character.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARRIGHT </font><font color="#ff00ff">2306</font>
<font color="#0000ff">// Move caret right one character extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_CHARRIGHTEXTEND </font><font color="#ff00ff">2307</font>
<font color="#0000ff">// Move caret left one word.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDLEFT </font><font color="#ff00ff">2308</font>
<font color="#0000ff">// Move caret left one word extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDLEFTEXTEND </font><font color="#ff00ff">2309</font>
<font color="#0000ff">// Move caret right one word.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDRIGHT </font><font color="#ff00ff">2310</font>
<font color="#0000ff">// Move caret right one word extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDRIGHTEXTEND </font><font color="#ff00ff">2311</font>
<font color="#0000ff">// Move caret to first position on line.</font>
<font color="#a020f0">#define wxSTC_CMD_HOME </font><font color="#ff00ff">2312</font>
<font color="#0000ff">// Move caret to first position on line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_HOMEEXTEND </font><font color="#ff00ff">2313</font>
<font color="#0000ff">// Move caret to last position on line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEEND </font><font color="#ff00ff">2314</font>
<font color="#0000ff">// Move caret to last position on line extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEENDEXTEND </font><font color="#ff00ff">2315</font>
<font color="#0000ff">// Move caret to first position in document.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTSTART </font><font color="#ff00ff">2316</font>
<font color="#0000ff">// Move caret to first position in document extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTSTARTEXTEND </font><font color="#ff00ff">2317</font>
<font color="#0000ff">// Move caret to last position in document.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTEND </font><font color="#ff00ff">2318</font>
<font color="#0000ff">// Move caret to last position in document extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_DOCUMENTENDEXTEND </font><font color="#ff00ff">2319</font>
<font color="#0000ff">// Move caret one page up.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEUP </font><font color="#ff00ff">2320</font>
<font color="#0000ff">// Move caret one page up extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEUPEXTEND </font><font color="#ff00ff">2321</font>
<font color="#0000ff">// Move caret one page down.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEDOWN </font><font color="#ff00ff">2322</font>
<font color="#0000ff">// Move caret one page down extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_PAGEDOWNEXTEND </font><font color="#ff00ff">2323</font>
<font color="#0000ff">// Switch from insert to overtype mode or the reverse.</font>
<font color="#a020f0">#define wxSTC_CMD_EDITTOGGLEOVERTYPE </font><font color="#ff00ff">2324</font>
<font color="#0000ff">// Cancel any modes such as call tip or auto-completion list display.</font>
<font color="#a020f0">#define wxSTC_CMD_CANCEL </font><font color="#ff00ff">2325</font>
<font color="#0000ff">// Delete the selection or if no selection, the character before the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_DELETEBACK </font><font color="#ff00ff">2326</font>
<font color="#0000ff">// If selection is empty or all on one line replace the selection with a tab character.</font>
<font color="#0000ff">// If more than one line selected, indent the lines.</font>
<font color="#a020f0">#define wxSTC_CMD_TAB </font><font color="#ff00ff">2327</font>
<font color="#0000ff">// Dedent the selected lines.</font>
<font color="#a020f0">#define wxSTC_CMD_BACKTAB </font><font color="#ff00ff">2328</font>
<font color="#0000ff">// Insert a new line, may use a CRLF, CR or LF depending on EOL mode.</font>
<font color="#a020f0">#define wxSTC_CMD_NEWLINE </font><font color="#ff00ff">2329</font>
<font color="#0000ff">// Insert a Form Feed character.</font>
<font color="#a020f0">#define wxSTC_CMD_FORMFEED </font><font color="#ff00ff">2330</font>
<font color="#0000ff">// Move caret to before first visible character on line.</font>
<font color="#0000ff">// If already there move to first character on line.</font>
<font color="#a020f0">#define wxSTC_CMD_VCHOME </font><font color="#ff00ff">2331</font>
<font color="#0000ff">// Like VCHome but extending selection to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_VCHOMEEXTEND </font><font color="#ff00ff">2332</font>
<font color="#0000ff">// Magnify the displayed text by increasing the sizes by 1 point.</font>
<font color="#a020f0">#define wxSTC_CMD_ZOOMIN </font><font color="#ff00ff">2333</font>
<font color="#0000ff">// Make the displayed text smaller by decreasing the sizes by 1 point.</font>
<font color="#a020f0">#define wxSTC_CMD_ZOOMOUT </font><font color="#ff00ff">2334</font>
<font color="#0000ff">// Delete the word to the left of the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_DELWORDLEFT </font><font color="#ff00ff">2335</font>
<font color="#0000ff">// Delete the word to the right of the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_DELWORDRIGHT </font><font color="#ff00ff">2336</font>
<font color="#0000ff">// Cut the line containing the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_LINECUT </font><font color="#ff00ff">2337</font>
<font color="#0000ff">// Delete the line containing the caret.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDELETE </font><font color="#ff00ff">2338</font>
<font color="#0000ff">// Switch the current line with the previous.</font>
<font color="#a020f0">#define wxSTC_CMD_LINETRANSPOSE </font><font color="#ff00ff">2339</font>
<font color="#0000ff">// Duplicate the current line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEDUPLICATE </font><font color="#ff00ff">2404</font>
<font color="#0000ff">// Transform the selection to lower case.</font>
<font color="#a020f0">#define wxSTC_CMD_LOWERCASE </font><font color="#ff00ff">2340</font>
<font color="#0000ff">// Transform the selection to upper case.</font>
<font color="#a020f0">#define wxSTC_CMD_UPPERCASE </font><font color="#ff00ff">2341</font>
<font color="#0000ff">// Scroll the document down, keeping the caret visible.</font>
<font color="#a020f0">#define wxSTC_CMD_LINESCROLLDOWN </font><font color="#ff00ff">2342</font>
<font color="#0000ff">// Scroll the document up, keeping the caret visible.</font>
<font color="#a020f0">#define wxSTC_CMD_LINESCROLLUP </font><font color="#ff00ff">2343</font>
<font color="#0000ff">// Delete the selection or if no selection, the character before the caret.</font>
<font color="#0000ff">// Will not delete the character before at the start of a line.</font>
<font color="#a020f0">#define wxSTC_CMD_DELETEBACKNOTLINE </font><font color="#ff00ff">2344</font>
<font color="#0000ff">// Move caret to first position on display line.</font>
<font color="#a020f0">#define wxSTC_CMD_HOMEDISPLAY </font><font color="#ff00ff">2345</font>
<font color="#0000ff">// Move caret to first position on display line extending selection to</font>
<font color="#0000ff">// new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_HOMEDISPLAYEXTEND </font><font color="#ff00ff">2346</font>
<font color="#0000ff">// Move caret to last position on display line.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEENDDISPLAY </font><font color="#ff00ff">2347</font>
<font color="#0000ff">// Move caret to last position on display line extending selection to new</font>
<font color="#0000ff">// caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_LINEENDDISPLAYEXTEND </font><font color="#ff00ff">2348</font>
<font color="#0000ff">// Move to the previous change in capitalisation.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDPARTLEFT </font><font color="#ff00ff">2390</font>
<font color="#0000ff">// Move to the previous change in capitalisation extending selection</font>
<font color="#0000ff">// to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDPARTLEFTEXTEND </font><font color="#ff00ff">2391</font>
<font color="#0000ff">// Move to the change next in capitalisation.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDPARTRIGHT </font><font color="#ff00ff">2392</font>
<font color="#0000ff">// Move to the next change in capitalisation extending selection</font>
<font color="#0000ff">// to new caret position.</font>
<font color="#a020f0">#define wxSTC_CMD_WORDPARTRIGHTEXTEND </font><font color="#ff00ff">2393</font>
<font color="#0000ff">// Delete back from the current position to the start of the line.</font>
<font color="#a020f0">#define wxSTC_CMD_DELLINELEFT </font><font color="#ff00ff">2395</font>
<font color="#0000ff">// Delete forwards from the current position to the end of the line.</font>
<font color="#a020f0">#define wxSTC_CMD_DELLINERIGHT </font><font color="#ff00ff">2396</font>
<font color="#0000ff">// END of generated section</font>
<font color="#0000ff">//----------------------------------------------------------------------</font>
@@ -880,8 +1007,11 @@
<font color="#2e8b57"><b>class</b></font> WordList;
<font color="#2e8b57"><b>struct</b></font> SCNotification;
<font color="#2e8b57"><b>extern</b></font> <font color="#2e8b57"><b>const</b></font> wxChar* wxSTCNameStr;
<font color="#a020f0">#ifndef SWIG</font>
<font color="#2e8b57"><b>extern</b></font> WXSTC_DECLSPEC <font color="#2e8b57"><b>const</b></font> wxChar* wxSTCNameStr;
<font color="#2e8b57"><b>class</b></font> WXSTC_DECLSPEC wxStyledTextCtrl;
<font color="#2e8b57"><b>class</b></font> WXSTC_DECLSPEC wxStyledTextEvent;
<font color="#a020f0">#endif</font>
<font color="#0000ff">//----------------------------------------------------------------------</font>
@@ -1070,6 +1200,9 @@
<font color="#0000ff">// Find the previous line before lineStart that includes a marker in mask.</font>
<font color="#2e8b57"><b>int</b></font> MarkerPrevious(<font color="#2e8b57"><b>int</b></font> lineStart, <font color="#2e8b57"><b>int</b></font> markerMask);
<font color="#0000ff">// Define a marker from a bitmap</font>
<font color="#2e8b57"><b>void</b></font> MarkerDefineBitmap(<font color="#2e8b57"><b>int</b></font> markerNumber, <font color="#2e8b57"><b>const</b></font> wxBitmap&amp; bmp);
<font color="#0000ff">// Set a margin to be either numeric or symbolic.</font>
<font color="#2e8b57"><b>void</b></font> SetMarginType(<font color="#2e8b57"><b>int</b></font> margin, <font color="#2e8b57"><b>int</b></font> marginType);
@@ -1291,6 +1424,19 @@
<font color="#0000ff">// after the inserted text upon completion.</font>
<font color="#2e8b57"><b>bool</b></font> AutoCompGetDropRestOfWord();
<font color="#0000ff">// Register an image for use in autocompletion lists.</font>
<font color="#2e8b57"><b>void</b></font> RegisterImage(<font color="#2e8b57"><b>int</b></font> type, <font color="#2e8b57"><b>const</b></font> wxBitmap&amp; bmp);
<font color="#0000ff">// Clear all the registered images.</font>
<font color="#2e8b57"><b>void</b></font> ClearRegisteredImages();
<font color="#0000ff">// Retrieve the auto-completion list type-separator character.</font>
<font color="#2e8b57"><b>int</b></font> AutoCompGetTypeSeparator();
<font color="#0000ff">// Change the type-separator character in the string setting up an auto-completion list.</font>
<font color="#0000ff">// Default is '?' but can be changed if items contain '?'.</font>
<font color="#2e8b57"><b>void</b></font> AutoCompSetTypeSeparator(<font color="#2e8b57"><b>int</b></font> separatorCharacter);
<font color="#0000ff">// Set the number of spaces used for one level of indentation.</font>
<font color="#2e8b57"><b>void</b></font> SetIndent(<font color="#2e8b57"><b>int</b></font> indentSize);
@@ -1386,7 +1532,7 @@
wxRect renderRect,
wxRect pageRect);
<font color="#0000ff">// Retrieve the line at the top of the display.</font>
<font color="#0000ff">// Retrieve the display line at the top of the display.</font>
<font color="#2e8b57"><b>int</b></font> GetFirstVisibleLine();
<font color="#0000ff">// Retrieve the contents of a line.</font>
@@ -1582,7 +1728,7 @@
<font color="#0000ff">// Ensure a particular line is visible by expanding any header line hiding it.</font>
<font color="#2e8b57"><b>void</b></font> EnsureVisible(<font color="#2e8b57"><b>int</b></font> line);
<font color="#0000ff">// Set some debugging options for folding.</font>
<font color="#0000ff">// Set some style options for folding.</font>
<font color="#2e8b57"><b>void</b></font> SetFoldFlags(<font color="#2e8b57"><b>int</b></font> flags);
<font color="#0000ff">// Ensure a particular line is visible by expanding any header line hiding it.</font>
@@ -1648,17 +1794,51 @@
<font color="#0000ff">// Retrieve the height of a particular line of text in pixels.</font>
<font color="#2e8b57"><b>int</b></font> TextHeight(<font color="#2e8b57"><b>int</b></font> line);
<font color="#0000ff">// Show or hide the vertical scroll bar.</font>
<font color="#2e8b57"><b>void</b></font> SetUseVerticalScrollBar(<font color="#2e8b57"><b>bool</b></font> show);
<font color="#0000ff">// Is the vertical scroll bar visible?</font>
<font color="#2e8b57"><b>bool</b></font> GetUseVerticalScrollBar();
<font color="#0000ff">// Append a string to the end of the document without changing the selection.</font>
<font color="#2e8b57"><b>void</b></font> AppendText(<font color="#2e8b57"><b>int</b></font> length, <font color="#2e8b57"><b>const</b></font> wxString&amp; text);
<font color="#0000ff">// Is drawing done in two phases with backgrounds drawn before foregrounds?</font>
<font color="#2e8b57"><b>bool</b></font> GetTwoPhaseDraw();
<font color="#0000ff">// In twoPhaseDraw mode, drawing is performed in two phases, first the background</font>
<font color="#0000ff">// and then the foreground. This avoids chopping off characters that overlap the next run.</font>
<font color="#2e8b57"><b>void</b></font> SetTwoPhaseDraw(<font color="#2e8b57"><b>bool</b></font> twoPhase);
<font color="#0000ff">// Make the target range start and end be the same as the selection range start and end.</font>
<font color="#2e8b57"><b>void</b></font> TargetFromSelection();
<font color="#0000ff">// Join the lines in the target.</font>
<font color="#0000ff">// This is an experimental feature and may be changed or removed.</font>
<font color="#2e8b57"><b>void</b></font> LinesJoin();
<font color="#0000ff">// Split the lines in the target into lines that are less wide than pixelWidth</font>
<font color="#0000ff">// where possible.</font>
<font color="#2e8b57"><b>void</b></font> LinesSplit(<font color="#2e8b57"><b>int</b></font> pixelWidth);
<font color="#0000ff">// Set the colours used as a chequerboard pattern in the fold margin</font>
<font color="#2e8b57"><b>void</b></font> SetFoldMarginColour(<font color="#2e8b57"><b>bool</b></font> useSetting, <font color="#2e8b57"><b>const</b></font> wxColour&amp; back);
<font color="#2e8b57"><b>void</b></font> SetFoldMarginHiColour(<font color="#2e8b57"><b>bool</b></font> useSetting, <font color="#2e8b57"><b>const</b></font> wxColour&amp; fore);
<font color="#0000ff">// Duplicate the current line.</font>
<font color="#2e8b57"><b>void</b></font> LineDuplicate();
<font color="#0000ff">// Move caret to first position on display line.</font>
<font color="#2e8b57"><b>void</b></font> HomeDisplay();
<font color="#0000ff">// Move caret to first position on display line extending selection to </font>
<font color="#0000ff">// Move caret to first position on display line extending selection to</font>
<font color="#0000ff">// new caret position.</font>
<font color="#2e8b57"><b>void</b></font> HomeDisplayExtend();
<font color="#0000ff">// Move caret to last position on display line.</font>
<font color="#2e8b57"><b>void</b></font> LineEndDisplay();
<font color="#0000ff">// Move caret to last position on display line extending selection to new </font>
<font color="#0000ff">// Move caret to last position on display line extending selection to new</font>
<font color="#0000ff">// caret position.</font>
<font color="#2e8b57"><b>void</b></font> LineEndDisplayExtend();
@@ -1812,6 +1992,9 @@
<font color="#2e8b57"><b>void</b></font> SetXOffset(<font color="#2e8b57"><b>int</b></font> newOffset);
<font color="#2e8b57"><b>int</b></font> GetXOffset();
<font color="#0000ff">// Set the last x chosen value to be the caret x position</font>
<font color="#2e8b57"><b>void</b></font> ChooseCaretX();
<font color="#0000ff">// Set the way the caret is kept visible when going sideway.</font>
<font color="#0000ff">// The exclusion zone is given in pixels.</font>
<font color="#2e8b57"><b>void</b></font> SetXCaretPolicy(<font color="#2e8b57"><b>int</b></font> caretPolicy, <font color="#2e8b57"><b>int</b></font> caretSlop);
@@ -1820,6 +2003,12 @@
<font color="#0000ff">// The exclusion zone is given in lines.</font>
<font color="#2e8b57"><b>void</b></font> SetYCaretPolicy(<font color="#2e8b57"><b>int</b></font> caretPolicy, <font color="#2e8b57"><b>int</b></font> caretSlop);
<font color="#0000ff">// Set printing to line wrapped (SC_WRAP_WORD) or not line wrapped (SC_WRAP_NONE).</font>
<font color="#2e8b57"><b>void</b></font> SetPrintWrapMode(<font color="#2e8b57"><b>int</b></font> mode);
<font color="#0000ff">// Is printing line wrapped.</font>
<font color="#2e8b57"><b>int</b></font> GetPrintWrapMode();
<font color="#0000ff">// Start notifying the container of all key presses and commands.</font>
<font color="#2e8b57"><b>void</b></font> StartRecord();
@@ -1940,6 +2129,7 @@
<font color="#2e8b57"><b>void</b></font> OnMouseMove(wxMouseEvent&amp; evt);
<font color="#2e8b57"><b>void</b></font> OnMouseLeftUp(wxMouseEvent&amp; evt);
<font color="#2e8b57"><b>void</b></font> OnMouseRightUp(wxMouseEvent&amp; evt);
<font color="#2e8b57"><b>void</b></font> OnMouseMiddleUp(wxMouseEvent&amp; evt);
<font color="#2e8b57"><b>void</b></font> OnContextMenu(wxContextMenuEvent&amp; evt);
<font color="#2e8b57"><b>void</b></font> OnMouseWheel(wxMouseEvent&amp; evt);
<font color="#2e8b57"><b>void</b></font> OnChar(wxKeyEvent&amp; evt);
@@ -1975,7 +2165,7 @@
<font color="#0000ff">//----------------------------------------------------------------------</font>
<font color="#0000ff">// SWIG can't handle &quot;#if&quot; type of conditionals, onlu &quot;#ifdef&quot;</font>
<font color="#0000ff">// SWIG can't handle &quot;#if&quot; type of conditionals, only &quot;#ifdef&quot;</font>
<font color="#a020f0">#ifdef SWIG</font>
<font color="#a020f0">#define STC_USE_DND </font><font color="#ff00ff">1</font>
<font color="#a020f0">#else</font>

View File

@@ -0,0 +1,290 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<meta name="generator" content="Docutils 0.2.8: http://docutils.sourceforge.net/" />
<title>The wxPython wx Package</title>
<meta name="author" content="Patrick K. O'Brien" />
<meta name="organization" content="Orbtech" />
<meta name="date" content="2003-05-08" />
<link rel="stylesheet" href="default.css" type="text/css" />
</head>
<body>
<div class="document" id="the-wxpython-wx-package">
<h1 class="title">The wxPython wx Package</h1>
<h2 class="subtitle" id="or-how-to-survive-the-new-wx-namespace-changes">Or, how to survive the new wx namespace changes.</h2>
<table class="docinfo" frame="void" rules="none">
<col class="docinfo-name" />
<col class="docinfo-content" />
<tbody valign="top">
<tr><th class="docinfo-name">Author:</th>
<td>Patrick K. O'Brien</td></tr>
<tr><th class="docinfo-name">Contact:</th>
<td><a class="first last reference" href="mailto:pobrien&#64;orbtech.com">pobrien&#64;orbtech.com</a></td></tr>
<tr><th class="docinfo-name">Organization:</th>
<td><a class="first last reference" href="http://www.orbtech.com/">Orbtech</a></td></tr>
<tr><th class="docinfo-name">Date:</th>
<td>2003-05-08</td></tr>
<tr><th class="docinfo-name">Revision:</th>
<td>1.1.2.4</td></tr>
</tbody>
</table>
<div class="contents topic" id="contents">
<p class="topic-title"><a name="contents">Contents</a></p>
<ul class="simple">
<li><a class="reference" href="#introduction" id="id1" name="id1">Introduction</a></li>
<li><a class="reference" href="#why-change-anything" id="id2" name="id2">Why change anything?</a></li>
<li><a class="reference" href="#what-does-the-new-wx-package-do" id="id3" name="id3">What does the new wx package do?</a></li>
<li><a class="reference" href="#will-any-of-this-effect-my-existing-code" id="id4" name="id4">Will any of this effect my existing code?</a></li>
<li><a class="reference" href="#how-does-the-new-wx-package-work" id="id5" name="id5">How does the new wx package work?</a></li>
<li><a class="reference" href="#what-about-all-the-other-modules-like-grid-html-and-stc" id="id6" name="id6">What about all the other modules, like grid, html, and stc?</a></li>
<li><a class="reference" href="#how-do-i-use-this-new-wx-package" id="id7" name="id7">How do I use this new wx package?</a></li>
<li><a class="reference" href="#what-are-the-issues-with-converting-old-code-to-use-the-new-wx-package" id="id8" name="id8">What are the issues with converting old code to use the new wx package?</a></li>
<li><a class="reference" href="#where-can-i-find-example-programs-using-the-new-wx-syntax" id="id9" name="id9">Where can I find example programs using the new wx syntax?</a></li>
</ul>
</div>
<div class="section" id="introduction">
<h1><a class="toc-backref" href="#id1" name="introduction">Introduction</a></h1>
<p>Big things sometimes come in small packages. This is certainly true
of the new wx package, which is being introduced in wxPython 2.4.1 as
a way to allow the &quot;wx&quot; prefix to be dropped from the names of all
wxPython classes, functions, and constants. This document should
answer all the questions you might have concerning the new wx package.
If not, feel free to contact the author. I hope you like the new wx
package as much as I do.</p>
</div>
<div class="section" id="why-change-anything">
<h1><a class="toc-backref" href="#id2" name="why-change-anything">Why change anything?</a></h1>
<p>This change is being made for a couple of reasons. The first reason
is to discourage the use of <tt class="literal"><span class="pre">import</span> <span class="pre">*</span></tt>, which is a dangerous
technique that can create name conflicts and bloated namespaces.</p>
<p>The second reason is to remove what some perceive to be a &quot;wart.&quot; For
example, the following code is rather ugly in that the &quot;wx&quot; prefix on
the wxFrame class name is no longer useful when you're using the wx
module prefix:</p>
<pre class="literal-block">
from wxPython import wx
class Frame(wx.wxFrame)
</pre>
<p>The new wx package allows you to write code like this, instead:</p>
<pre class="literal-block">
import wx
class Frame(wx.Frame)
</pre>
<p>The third reason is that the wxWindows project intends to do the same
thing (implement a new wx namespace and drop the &quot;wx&quot; prefix) and we
want wxPython to lead the way.</p>
</div>
<div class="section" id="what-does-the-new-wx-package-do">
<h1><a class="toc-backref" href="#id3" name="what-does-the-new-wx-package-do">What does the new wx package do?</a></h1>
<p>As a way of getting to this new syntax as quickly as possible, the
code in this new wx package was created. What it does is alter the
existing wx namespace dynamically. By making the changes on-the-fly
at runtime, we can try out the new syntax before any permanent changes
are made to the underlying class library. The downside of making
these changes at runtime is that there is a slight delay when you
<tt class="literal"><span class="pre">import</span> <span class="pre">wx</span></tt>; the upside is that you can start using the new syntax
now.</p>
</div>
<div class="section" id="will-any-of-this-effect-my-existing-code">
<h1><a class="toc-backref" href="#id4" name="will-any-of-this-effect-my-existing-code">Will any of this effect my existing code?</a></h1>
<p>No. Your existing code will continue to work and be supported for
some time. It will be up to you to decide when to switch to the new
syntax. But all new documentation and code examples will use the new
syntax. So don't wait too long. You wouldn't want anyone calling you
old-fashioned, would you?</p>
</div>
<div class="section" id="how-does-the-new-wx-package-work">
<h1><a class="toc-backref" href="#id5" name="how-does-the-new-wx-package-work">How does the new wx package work?</a></h1>
<p>It's pretty simple, and pretty clever. The wx directory contains an
<tt class="literal"><span class="pre">__init__.py</span></tt> file, making it a Python package. (In contrast, the
old wxPython.wx module is a module, not a package.) When you <tt class="literal"><span class="pre">import</span>
<span class="pre">wx</span></tt> the code in the <tt class="literal"><span class="pre">__init__.py</span></tt> file is executed, and that's
where all the magic takes place. Let's take a look at the code inside
the <tt class="literal"><span class="pre">__init__.py</span></tt> file:</p>
<pre class="literal-block">
&quot;&quot;&quot;wx package
Provides a way to drop the wx prefix from wxPython objects.&quot;&quot;&quot;
__author__ = &quot;Patrick K. O'Brien &lt;pobrien&#64;orbtech.com&gt;&quot;
__cvsid__ = &quot;$Id$&quot;
__revision__ = &quot;$Revision$&quot;[11:-2]
from wxPython import wx
import types
d_new = globals()
d_old = wx.__dict__
for old, obj in d_old.items():
if type(obj) is types.ModuleType or old.startswith('_'):
# Skip modules and private names.
continue
new = old
if old.startswith('EVT_'):
# Leave name unmodified; add to the new wx namespace.
d_new[new] = obj
elif old.startswith('wxEVT_'):
# Leave name unmodified; add to the new wx namespace.
d_new[new] = obj
else:
if old.startswith('wx'):
# Remove the 'wx' prefix.
new = old[2:]
# Add to the new wx package namespace.
d_new[new] = obj
del d_new
del d_old
del new
del obj
del old
del types
del wx
</pre>
<p>Namespaces in Python are implemented as dictionaries. The dictionary
used to create the wx package's namespace is accessible using the
<tt class="literal"><span class="pre">globals()</span></tt> function. The dictionary used to create the old
wxPython.wx module's namespace is <tt class="literal"><span class="pre">wx.__dict__</span></tt>. Once we have these
two dictionaries, it's a simple matter of iterating through one,
changing the names, adding the renamed object to the other dictionary,
and cleaning up a few local variables and imported modules. Voila!</p>
</div>
<div class="section" id="what-about-all-the-other-modules-like-grid-html-and-stc">
<h1><a class="toc-backref" href="#id6" name="what-about-all-the-other-modules-like-grid-html-and-stc">What about all the other modules, like grid, html, and stc?</a></h1>
<p>There's more to wxPython than just the wx namespace. And we've got
those extra modules covered as well. For each of those modules (as
well as the lib package) we've got matching modules in the new wx
package. Let's take a look at a few of them.</p>
<p>Here is <tt class="literal"><span class="pre">html.py</span></tt>:</p>
<pre class="literal-block">
&quot;&quot;&quot;Provides a way to drop the wx prefix from wxPython objects.&quot;&quot;&quot;
__author__ = &quot;Patrick K. O'Brien &lt;pobrien&#64;orbtech.com&gt;&quot;
__cvsid__ = &quot;$Id$&quot;
__revision__ = &quot;$Revision$&quot;[11:-2]
import wx
from wx import prefix
from wxPython import html
prefix.rename(d_new=globals(), d_old=html.__dict__)
del html
del prefix
del wx
</pre>
<p>And here is <tt class="literal"><span class="pre">lib/dialogs.py</span></tt>:</p>
<pre class="literal-block">
&quot;&quot;&quot;Provides a way to drop the wx prefix from wxPython objects.&quot;&quot;&quot;
__author__ = &quot;Patrick K. O'Brien &lt;pobrien&#64;orbtech.com&gt;&quot;
__cvsid__ = &quot;$Id$&quot;
__revision__ = &quot;$Revision$&quot;[11:-2]
import wx
from wx import prefix
from wxPython.lib import dialogs
prefix.rename(d_new=globals(), d_old=dialogs.__dict__)
del dialogs
del prefix
del wx
</pre>
<p>As you can see, they both rely on the <tt class="literal"><span class="pre">prefix.rename()</span></tt> function
defined in <tt class="literal"><span class="pre">prefix.py</span></tt>:</p>
<pre class="literal-block">
&quot;&quot;&quot;Renaming utility.
Provides a way to drop the wx prefix from wxPython objects.&quot;&quot;&quot;
__author__ = &quot;Patrick K. O'Brien &lt;pobrien&#64;orbtech.com&gt;&quot;
__cvsid__ = &quot;$Id$&quot;
__revision__ = &quot;$Revision$&quot;[11:-2]
import types
def rename(d_new, d_old):
for old, obj in d_old.items():
if type(obj) is types.ModuleType or old.startswith('_'):
# Skip modules and private names.
continue
## mod = d_old['__name__']
## if hasattr(obj, '__module__') and not obj.__module__.startswith(mod):
## # Skip objects imported from other modules, except those
## # related to the current module, such as stc_.
## continue
new = old
if old.startswith('EVT_') or old.startswith('wxEVT_'):
# Leave these names unmodified.
pass
elif old.startswith('wx'):
new = old[2:]
if new:
d_new[new] = d_old[old]
</pre>
<p>Again, the technique is very similar to the one used by the wx
package.</p>
</div>
<div class="section" id="how-do-i-use-this-new-wx-package">
<h1><a class="toc-backref" href="#id7" name="how-do-i-use-this-new-wx-package">How do I use this new wx package?</a></h1>
<p>The wx package is automatically created when you install wxPython
version 2.4.1 or higher. So all you have to do is:</p>
<pre class="literal-block">
import wx
</pre>
</div>
<div class="section" id="what-are-the-issues-with-converting-old-code-to-use-the-new-wx-package">
<h1><a class="toc-backref" href="#id8" name="what-are-the-issues-with-converting-old-code-to-use-the-new-wx-package">What are the issues with converting old code to use the new wx package?</a></h1>
<p>Obviously, you need to change your import statements from:</p>
<pre class="literal-block">
from wxPython import wx
</pre>
<p>or:</p>
<pre class="literal-block">
from wxPython.wx import *
</pre>
<p>to:</p>
<pre class="literal-block">
import wx
</pre>
<p>Then you need to refer to wx attributes without a &quot;wx&quot; prefix, such
as:</p>
<pre class="literal-block">
class MyFrame(wx.Frame):
</pre>
<p>In most cases, existing code can be modified with a simple search and
replace.</p>
<p>One extra issue you might run into when converting existing code is
that the wx.__version__ attribute is no longer available, since the
new wx namespace doesn't include any private attributes from the old
wxPython.wx namespace. The solution is to use the wx.VERSION_STRING
attribute, which was introduced in wxPython 2.4.1.</p>
</div>
<div class="section" id="where-can-i-find-example-programs-using-the-new-wx-syntax">
<h1><a class="toc-backref" href="#id9" name="where-can-i-find-example-programs-using-the-new-wx-syntax">Where can I find example programs using the new wx syntax?</a></h1>
<p>Example programs are included in the wxPython/samples/wx_examples
directory, and are documented in the <a class="reference" href="wxPythonExamples.html">wxPythonExamples</a> documentation
file. Also, all the code in the py package uses the new wx syntax.
You can learn more about these in the <a class="reference" href="PyManual.html">PyManual</a>.</p>
</div>
</div>
<hr class="footer"/>
<div class="footer">
<a class="reference" href="wxPackage.txt">View document source</a>.
Generated on: 2003-06-04 18:07 UTC.
Generated by <a class="reference" href="http://docutils.sourceforge.net/">Docutils</a> from <a class="reference" href="http://docutils.sourceforge.net/rst.html">reStructuredText</a> source.
</div>
</body>
</html>

View File

@@ -9,48 +9,48 @@ in Python. This is not part of the demo framework.
"""
from wxPython.wx import *
import wx # This module uses the new wx namespace
import time
#---------------------------------------------------------------------------
class MyFrame(wxFrame):
class MyFrame(wx.Frame):
def __init__(self, parent, id, title):
wxFrame.__init__(self, parent, id, title,
wxPoint(100, 100), wxSize(160, 150))
wx.Frame.__init__(self, parent, id, title,
wx.Point(100, 100), wx.Size(160, 150))
EVT_SIZE(self, self.OnSize)
EVT_MOVE(self, self.OnMove)
EVT_CLOSE(self, self.OnCloseWindow)
EVT_IDLE(self, self.OnIdle)
wx.EVT_SIZE(self, self.OnSize)
wx.EVT_MOVE(self, self.OnMove)
wx.EVT_CLOSE(self, self.OnCloseWindow)
wx.EVT_IDLE(self, self.OnIdle)
self.count = 0
panel = wxPanel(self, -1)
wxStaticText(panel, -1, "Size:",
wxDLG_PNT(panel, wxPoint(4, 4)), wxDefaultSize)
wxStaticText(panel, -1, "Pos:",
wxDLG_PNT(panel, wxPoint(4, 16)), wxDefaultSize)
panel = wx.Panel(self, -1)
wx.StaticText(panel, -1, "Size:",
wx.DLG_PNT(panel, wx.Point(4, 4)), wx.DefaultSize)
wx.StaticText(panel, -1, "Pos:",
wx.DLG_PNT(panel, wx.Point(4, 16)), wx.DefaultSize)
wxStaticText(panel, -1, "Idle:",
wxDLG_PNT(panel, wxPoint(4, 28)), wxDefaultSize)
wx.StaticText(panel, -1, "Idle:",
wx.DLG_PNT(panel, wx.Point(4, 28)), wx.DefaultSize)
self.sizeCtrl = wxTextCtrl(panel, -1, "",
wxDLG_PNT(panel, wxPoint(24, 4)),
wxDLG_SZE(panel, wxSize(36, -1)),
wxTE_READONLY)
self.sizeCtrl = wx.TextCtrl(panel, -1, "",
wx.DLG_PNT(panel, wx.Point(24, 4)),
wx.DLG_SZE(panel, wx.Size(36, -1)),
wx.TE_READONLY)
self.posCtrl = wxTextCtrl(panel, -1, "",
wxDLG_PNT(panel, wxPoint(24, 16)),
wxDLG_SZE(panel, wxSize(36, -1)),
wxTE_READONLY)
self.posCtrl = wx.TextCtrl(panel, -1, "",
wx.DLG_PNT(panel, wx.Point(24, 16)),
wx.DLG_SZE(panel, wx.Size(36, -1)),
wx.TE_READONLY)
self.idleCtrl = wxTextCtrl(panel, -1, "",
wxDLG_PNT(panel, wxPoint(24, 28)),
wxDLG_SZE(panel, wxSize(36, -1)),
wxTE_READONLY)
self.idleCtrl = wx.TextCtrl(panel, -1, "",
wx.DLG_PNT(panel, wx.Point(24, 28)),
wx.DLG_SZE(panel, wx.Size(36, -1)),
wx.TE_READONLY)
def OnCloseWindow(self, event):
@@ -74,7 +74,7 @@ class MyFrame(wxFrame):
#---------------------------------------------------------------------------
class MyApp(wxApp):
class MyApp(wx.App):
def MainLoop(self):
# This outer loop determines when to exit the application, for
# this example we let the main frame reset this flag when it

View File

@@ -60,6 +60,7 @@ command_lines = [
"-a -u -n WizTest1 bmp_source/wiztest1.bmp images.py",
"-a -u -n WizTest2 bmp_source/wiztest2.bmp images.py",
"-a -u -n Tux bmp_source/Tux.png images.py",
" -u -c bmp_source/001.png throbImages.py",

File diff suppressed because it is too large Load Diff

View File

@@ -9,10 +9,10 @@ class MyFrame(wxFrame):
wxFrame.__init__(self,None,-1,"Close me...",size=(300,100))
menubar = wxMenuBar()
menu = wxMenu()
mID = NewId()
mID = wxNewId()
menu.Append(mID,"&Enable output","Display output frame")
EVT_MENU(self,mID,output.EnableOutput)
mID = NewId()
mID = wxNewId()
menu.Append(mID,"&Disable output","Close output frame")
EVT_MENU(self,mID,output.DisableOutput)
menubar.Append(menu,"&Output")
@@ -63,10 +63,10 @@ if __name__ == "__main__":
## EVT_CLOSE(self,self.OnClose)
## menubar = wxMenuBar()
## menu = wxMenu()
## mID = NewId()
## mID = wxNewId()
## menu.Append(mID,"&Enable output","Display output frame")
## EVT_MENU(self,mID,output.EnableOutput)
## mID = NewId()
## mID = wxNewId()
## menu.Append(mID,"&Disable output","Close output frame")
## EVT_MENU(self,mID,output.DisableOutput)
## menubar.Append(menu,"&Output")

View File

@@ -17,9 +17,9 @@ directory within its own frame window. Just specify the module name
on the command line.
"""
import wx # This module uses the new wx namespace
import sys, os
from wxPython.wx import *
#----------------------------------------------------------------------------
@@ -27,32 +27,34 @@ class Log:
def WriteText(self, text):
if text[-1:] == '\n':
text = text[:-1]
wxLogMessage(text)
wx.LogMessage(text)
write = WriteText
class RunDemoApp(wxApp):
class RunDemoApp(wx.App):
def __init__(self, name, module):
self.name = name
self.demoModule = module
wxApp.__init__(self, 0) ##wxPlatform == "__WXMAC__")
wx.App.__init__(self, 0)
def OnInit(self):
wxInitAllImageHandlers()
wxLog_SetActiveTarget(wxLogStderr())
wx.InitAllImageHandlers()
wx.Log_SetActiveTarget(wx.LogStderr())
frame = wxFrame(None, -1, "RunDemo: " + self.name, pos=(50,50), size=(0,0),
style=wxNO_FULL_REPAINT_ON_RESIZE|wxDEFAULT_FRAME_STYLE)
#self.SetAssertMode(wx.PYAPP_ASSERT_DIALOG)
frame = wx.Frame(None, -1, "RunDemo: " + self.name, pos=(50,50), size=(0,0),
style=wx.NO_FULL_REPAINT_ON_RESIZE|wx.DEFAULT_FRAME_STYLE)
frame.CreateStatusBar()
menuBar = wxMenuBar()
menu = wxMenu()
menuBar = wx.MenuBar()
menu = wx.Menu()
menu.Append(101, "E&xit\tAlt-X", "Exit demo")
EVT_MENU(self, 101, self.OnButton)
wx.EVT_MENU(self, 101, self.OnButton)
menuBar.Append(menu, "&File")
frame.SetMenuBar(menuBar)
frame.Show(True)
EVT_CLOSE(frame, self.OnCloseFrame)
wx.EVT_CLOSE(frame, self.OnCloseFrame)
win = self.demoModule.runTest(frame, frame, Log())
@@ -68,9 +70,9 @@ class RunDemoApp(wxApp):
# otherwise the demo made its own frame, so just put a
# button in this one
if hasattr(frame, 'otherWin'):
b = wxButton(frame, -1, " Exit ")
b = wx.Button(frame, -1, " Exit ")
frame.SetSize((200, 100))
EVT_BUTTON(frame, b.GetId(), self.OnButton)
wx.EVT_BUTTON(frame, b.GetId(), self.OnButton)
else:
# It was probably a dialog or something that is already
# gone, so we're done.
@@ -79,8 +81,8 @@ class RunDemoApp(wxApp):
self.SetTopWindow(frame)
self.frame = frame
#wxLog_SetActiveTarget(wxLogStderr())
#wxLog_SetTraceMask(wxTraceMessages)
#wx.Log_SetActiveTarget(wx.LogStderr())
#wx.Log_SetTraceMask(wx.TraceMessages)
return True

View File

@@ -5,38 +5,38 @@
# structure of any wxPython application.
#----------------------------------------------------------------------
from wxPython.wx import *
import wx # This module uses the new wx namespace
class MyFrame(wxFrame):
class MyFrame(wx.Frame):
"""
This is MyFrame. It just shows a few controls on a wxPanel,
and has a simple menu.
"""
def __init__(self, parent, title):
wxFrame.__init__(self, parent, -1, title, size=(350, 200))
wx.Frame.__init__(self, parent, -1, title, size=(350, 200))
menuBar = wxMenuBar()
menu = wxMenu()
menuBar = wx.MenuBar()
menu = wx.Menu()
menu.Append(101, "E&xit\tAlt-X", "Exit demo")
EVT_MENU(self, 101, self.OnButton)
wx.EVT_MENU(self, 101, self.OnButton)
menuBar.Append(menu, "&File")
self.SetMenuBar(menuBar)
panel = wxPanel(self, -1)
text = wxStaticText(panel, -1, "Hello World!")
text.SetFont(wxFont(12, wxSWISS, wxNORMAL, wxBOLD))
panel = wx.Panel(self, -1)
text = wx.StaticText(panel, -1, "Hello World!")
text.SetFont(wx.Font(12, wx.SWISS, wx.NORMAL, wx.BOLD))
text.SetSize(text.GetBestSize())
btn = wxButton(panel, -1, "Close")
btn = wx.Button(panel, -1, "Close")
btn.SetDefault()
sizer = wxBoxSizer(wxVERTICAL)
sizer.Add(text, 0, wxALL, 10)
sizer.Add(btn, 0, wxALL, 10)
sizer = wx.BoxSizer(wx.VERTICAL)
sizer.Add(text, 0, wx.ALL, 10)
sizer.Add(btn, 0, wx.ALL, 10)
panel.SetSizer(sizer)
panel.SetAutoLayout(True)
panel.Layout()
EVT_BUTTON(self, btn.GetId(), self.OnButton)
wx.EVT_BUTTON(self, btn.GetId(), self.OnButton)
def OnButton(self, evt):
@@ -44,7 +44,8 @@ class MyFrame(wxFrame):
print "OnButton"
self.Close()
app = wxPySimpleApp()
app = wx.PySimpleApp()
frame = MyFrame(None, "Simple wxPython App")
frame.Show(True)
app.MainLoop()

View File

@@ -1,12 +1,12 @@
from wxPython.wx import *
import wx # This module uses the new wx namespace
#----------------------------------------------------------------------
class TestPanel(wxPanel):
class TestPanel(wx.Panel):
def __init__(self, parent, log):
self.log = log
wxPanel.__init__(self, parent, -1)
wx.Panel.__init__(self, parent, -1)
#----------------------------------------------------------------------

View File

@@ -61,7 +61,7 @@ class TestPanel(wxPanel):
monthlist = GetMonthList()
mID = NewId()
mID = wxNewId()
self.date = wxComboBox(self, mID, "",
wxPoint(100, 20), wxSize(90, -1),
monthlist, wxCB_DROPDOWN)
@@ -89,7 +89,7 @@ class TestPanel(wxPanel):
# scroll bar for month selection
mID = NewId()
mID = wxNewId()
self.scroll = wxScrollBar(self, mID, wxPoint(100, 240), wxSize(200, 20), wxSB_HORIZONTAL)
self.scroll.SetScrollbar(start_month-1, 1, 12, 1, True)
EVT_COMMAND_SCROLL(self, mID, self.Scroll)
@@ -99,7 +99,7 @@ class TestPanel(wxPanel):
self.dtext = wxTextCtrl(self, -1, str(start_year), wxPoint(200, 20), wxSize(60, -1))
h = self.dtext.GetSize().height
mID = NewId()
mID = wxNewId()
self.spin = wxSpinButton(self, mID, wxPoint(270, 20), wxSize(h*2, h))
self.spin.SetRange(1980, 2010)
self.spin.SetValue(start_year)
@@ -109,7 +109,7 @@ class TestPanel(wxPanel):
wxStaticText(self, -1, "Test Calendar Dialog", wxPoint(350, 50), wxSize(150, -1))
mID = NewId()
mID = wxNewId()
bmp = images.getCalendarBitmap()
self.but = wxBitmapButton(self, mID, bmp, wxPoint(380, 80))#, wxSize(30, 30))
EVT_BUTTON(self, mID, self.TestDlg)
@@ -118,13 +118,13 @@ class TestPanel(wxPanel):
wxStaticText(self, -1, "Test Calendar Window", wxPoint(350, 150), wxSize(150, -1))
mID = NewId()
mID = wxNewId()
self.but = wxBitmapButton(self, mID, bmp, wxPoint(380, 180))#, wxSize(30, 30))
EVT_BUTTON(self, mID, self.TestFrame)
wxStaticText(self, -1, "Test Calendar Print", wxPoint(350, 250), wxSize(150, -1))
mID = NewId()
mID = wxNewId()
self.but = wxBitmapButton(self, mID, bmp, wxPoint(380, 280))#, wxSize(30, 30))
EVT_BUTTON(self, mID, self.OnPreview)
@@ -299,17 +299,17 @@ class CalendFrame(wxFrame):
def MakeFileMenu(self):
menu = wxMenu()
mID = NewId()
mID = wxNewId()
menu.Append(mID, 'Decrement', 'Next')
EVT_MENU(self, mID, self.OnDecMonth)
mID = NewId()
mID = wxNewId()
menu.Append(mID, 'Increment', 'Dec')
EVT_MENU(self, mID, self.OnIncMonth)
menu.AppendSeparator()
mID = NewId()
mID = wxNewId()
menu.Append(mID, 'E&xit', 'Exit')
EVT_MENU(self, mID, self.OnCloseWindow)
@@ -318,23 +318,23 @@ class CalendFrame(wxFrame):
def MakeToolMenu(self):
tb = self.CreateToolBar(wxTB_HORIZONTAL|wxNO_BORDER)
mID = NewId()
mID = wxNewId()
SetToolPath(self, tb, mID, images.getDbDecBitmap(), 'Dec Year')
EVT_TOOL(self, mID, self.OnDecYear)
mID = NewId()
mID = wxNewId()
SetToolPath(self, tb, mID, images.getDecBitmap(), 'Dec Month')
EVT_TOOL(self, mID, self.OnDecMonth)
mID = NewId()
mID = wxNewId()
SetToolPath(self, tb, mID, images.getPtBitmap(), 'Current Month')
EVT_TOOL(self, mID, self.OnCurrent)
mID = NewId()
mID = wxNewId()
SetToolPath(self, tb, mID, images.getIncBitmap(), 'Inc Month')
EVT_TOOL(self, mID, self.OnIncMonth)
mID = NewId()
mID = wxNewId()
SetToolPath(self, tb, mID, images.getDbIncBitmap(), 'Inc Year')
EVT_TOOL(self, mID, self.OnIncYear)

View File

@@ -11,7 +11,10 @@ class TestPanel(wxPanel):
self.log = log
cal = wxCalendarCtrl(self, -1, wxDateTime_Now(), pos = (25,50),
style = wxCAL_SHOW_HOLIDAYS | wxCAL_SUNDAY_FIRST)
style = wxCAL_SHOW_HOLIDAYS
| wxCAL_SUNDAY_FIRST
#| wxCAL_SEQUENTIAL_MONTH_SELECTION
)
EVT_CALENDAR(self, cal.GetId(), self.OnCalSelected)
@@ -55,3 +58,12 @@ version described in the docs. This one will probably be a bit more efficient
than the one in wxPython.lib.calendar, but I like a few things about it better,
so I think both will stay in wxPython.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -11,7 +11,7 @@ class TestCheckBox(wxPanel):
wxStaticText(self, -1, "This example uses the wxCheckBox control.",
wxPoint(10, 10))
cID = NewId()
cID = wxNewId()
cb1 = wxCheckBox(self, cID, " Apples", wxPoint(65, 40), wxSize(150, 20), wxNO_BORDER)
cb2 = wxCheckBox(self, cID+1, " Oranges", wxPoint(65, 60), wxSize(150, 20), wxNO_BORDER)
cb2.SetValue(True)
@@ -51,3 +51,11 @@ overview = """\
A checkbox is a labelled box which is either on (checkmark is visible) or off (no checkmark).
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -70,13 +70,15 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -46,3 +46,13 @@ def runTest(frame, nb, log):
overview = """\
A choice item is used to select one of a list of strings. Unlike a listbox, only the selection is visible until the user pulls down the menu of choices.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -29,3 +29,13 @@ This class represents the colour chooser dialog.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -15,6 +15,7 @@ class TestComboBox(wxPanel):
wxPanel.__init__(self, parent, -1)
sampleList = ['zero', 'one', 'two', 'three', 'four', 'five',
##'this is a long item that needs a scrollbar...',
'six', 'seven', 'eight']
wxStaticText(self, -1, "This example uses the wxComboBox control.",
@@ -23,6 +24,11 @@ class TestComboBox(wxPanel):
wxStaticText(self, -1, "Select one:", wxPoint(15, 50), wxSize(75, 18))
cb = wxComboBox(self, 500, "default value", wxPoint(90, 50), wxSize(95, -1),
sampleList, wxCB_DROPDOWN)#|wxTE_PROCESS_ENTER)
##import win32api, win32con
##win32api.SendMessage(cb.GetHandle(),
## win32con.CB_SETHORIZONTALEXTENT,
## 200, 0)
EVT_COMBOBOX(self, 500, self.EvtComboBox)
EVT_TEXT(self, 500, self.EvtText)
EVT_TEXT_ENTER(self, 500, self.EvtTextEnter)

View File

@@ -40,3 +40,12 @@ overview = """\
This class provides a composite control that lets the
user easily enter and edit a list of strings.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -1,5 +1,6 @@
from wxPython.wx import *
import os
#---------------------------------------------------------------------------
@@ -8,12 +9,18 @@ wildcard = "Python source (*.py)|*.py|" \
"All files (*.*)|*.*"
def runTest(frame, nb, log):
dlg = wxFileDialog(frame, "Choose a file", "", "", wildcard, wxOPEN|wxMULTIPLE)
log.WriteText("CWD: %s\n" % os.getcwd())
dlg = wxFileDialog(frame, "Choose a file", os.getcwd(), "", wildcard,
wxOPEN
| wxMULTIPLE
#| wxCHANGE_DIR
)
if dlg.ShowModal() == wxID_OK:
paths = dlg.GetPaths()
log.WriteText('You selected %d files:' % len(paths))
for path in paths:
log.WriteText(' %s\n' % path)
log.WriteText("CWD: %s\n" % os.getcwd())
dlg.Destroy()
#---------------------------------------------------------------------------
@@ -24,14 +31,14 @@ def runTest(frame, nb, log):
overview = """\
This class represents the file chooser dialog.
This class provides the file chooser dialog.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -0,0 +1,44 @@
from wxPython.wx import *
import os
#---------------------------------------------------------------------------
wildcard = "Python source (*.py)|*.py|" \
"Compiled Python (*.pyc)|*.pyc|" \
"SPAM files (*.spam)|*.spam|" \
"Egg file (*.egg)|*.egg|" \
"All files (*.*)|*.*"
def runTest(frame, nb, log):
log.WriteText("CWD: %s\n" % os.getcwd())
dlg = wxFileDialog(frame, "Save file as...", os.getcwd(), "", wildcard,
wxSAVE
#| wxCHANGE_DIR
)
dlg.SetFilterIndex(2)
if dlg.ShowModal() == wxID_OK:
path = dlg.GetPath()
log.WriteText('You selected "%s"' % path)
log.WriteText("CWD: %s\n" % os.getcwd())
dlg.Destroy()
#---------------------------------------------------------------------------
overview = """\
This class provides the file chooser dialog.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -76,3 +76,12 @@ def runTest(frame, nb, log):
overview = """\
A generic find and replace dialog.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -75,9 +75,11 @@ def runTest(frame, nb, log):
#---------------------------------------------------------------------------
overview = """\
wxFloatBar is a subclass of wxToolBar, implemented in Python, which can be detached from its frame.
wxFloatBar is a subclass of wxToolBar, implemented in Python, which
can be detached from its frame.
Drag the toolbar with the mouse to make it float, and drag it back, or close it to make the toolbar return to its original position.
Drag the toolbar with the mouse to make it float, and drag it back, or
close it to make the toolbar return to its original position.
"""
@@ -87,6 +89,13 @@ Drag the toolbar with the mouse to make it float, and drag it back, or close it
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -43,3 +43,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -52,3 +52,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -57,3 +57,10 @@ overview = """\
This control can be used to place a directory listing (with optional files)
on an arbitrary window.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -11,6 +11,7 @@ buttonDefs = {
819 : ('GridEnterHandler',' Remapping keys to behave differently '),
820 : ('GridCustEditor', ' Shows how to create a custom Cell Editor '),
821 : ('GridDragable', ' A wxGrid with dragable rows and columns '),
822 : ('GridDragAndDrop', 'Shows how to make a grid a drop target for files'),
}
@@ -26,7 +27,7 @@ class ButtonPanel(wxPanel):
for k in keys:
text = buttonDefs[k][1]
btn = wxButton(self, k, text)
box.Add(btn, 0, wxALIGN_CENTER|wxALL, 15)
box.Add(btn, 0, wxALIGN_CENTER|wxALL, 10)
EVT_BUTTON(self, k, self.OnButton)
self.SetAutoLayout(True)
@@ -94,9 +95,6 @@ changes how the ENTER key works, moving the current cell left to right
and wrapping around to the next row when needed.
</ol>
<p>
You can also look at the <a href="data/grid.i">SWIG interface
file</a> used to generate the grid module for a lot more clues as to
how things work.
"""

View File

@@ -0,0 +1,451 @@
from wxPython.wx import *
from wxPython.grid import *
import images
class MegaTable(wxPyGridTableBase):
"""
A custom wxGrid Table using user supplied data
"""
def __init__(self, data, colnames, plugins):
"""data is a list of the form
[(rowname, dictionary),
dictionary.get(colname, None) returns the data for column
colname
"""
# The base class must be initialized *first*
wxPyGridTableBase.__init__(self)
self.data = data
self.colnames = colnames
self.plugins = plugins or {}
# XXX
# we need to store the row length and collength to
# see if the table has changed size
self._rows = self.GetNumberRows()
self._cols = self.GetNumberCols()
def GetNumberCols(self):
return len(self.colnames)
def GetNumberRows(self):
return len(self.data)
def GetColLabelValue(self, col):
return self.colnames[col]
def GetRowLabelValues(self, row):
return self.data[row][0]
def GetValue(self, row, col):
return str(self.data[row][1].get(self.GetColLabelValue(col), ""))
def GetRawValue(self, row, col):
return self.data[row][1].get(self.GetColLabelValue(col), "")
def SetValue(self, row, col, value):
self.data[row][1][self.GetColLabelValue(col)] = value
def ResetView(self, grid):
"""
(wxGrid) -> Reset the grid view. Call this to
update the grid if rows and columns have been added or deleted
"""
grid.BeginBatch()
for current, new, delmsg, addmsg in [
(self._rows, self.GetNumberRows(), wxGRIDTABLE_NOTIFY_ROWS_DELETED, wxGRIDTABLE_NOTIFY_ROWS_APPENDED),
(self._cols, self.GetNumberCols(), wxGRIDTABLE_NOTIFY_COLS_DELETED, wxGRIDTABLE_NOTIFY_COLS_APPENDED),
]:
if new < current:
msg = wxGridTableMessage(self,delmsg,new,current-new)
grid.ProcessTableMessage(msg)
elif new > current:
msg = wxGridTableMessage(self,addmsg,new-current)
grid.ProcessTableMessage(msg)
self.UpdateValues(grid)
grid.EndBatch()
self._rows = self.GetNumberRows()
self._cols = self.GetNumberCols()
# update the column rendering plugins
self._updateColAttrs(grid)
# update the scrollbars and the displayed part of the grid
grid.AdjustScrollbars()
grid.ForceRefresh()
def UpdateValues(self, grid):
"""Update all displayed values"""
# This sends an event to the grid table to update all of the values
msg = wxGridTableMessage(self, wxGRIDTABLE_REQUEST_VIEW_GET_VALUES)
grid.ProcessTableMessage(msg)
def _updateColAttrs(self, grid):
"""
wxGrid -> update the column attributes to add the
appropriate renderer given the column name. (renderers
are stored in the self.plugins dictionary)
Otherwise default to the default renderer.
"""
col = 0
for colname in self.colnames:
attr = wxGridCellAttr()
if colname in self.plugins:
renderer = self.plugins[colname](self)
if renderer.colSize:
grid.SetColSize(col, renderer.colSize)
if renderer.rowSize:
grid.SetDefaultRowSize(renderer.rowSize)
attr.SetReadOnly(true)
attr.SetRenderer(renderer)
grid.SetColAttr(col, attr)
col += 1
# ------------------------------------------------------
# begin the added code to manipulate the table (non wx related)
def AppendRow(self, row):
entry = {}
for name in self.colnames:
entry[name] = "Appended_%i"%row
# XXX Hack
# entry["A"] can only be between 1..4
entry["A"] = random.choice(range(4))
self.data.insert(row, ["Append_%i"%row, entry])
def DeleteCols(self, cols):
"""
cols -> delete the columns from the dataset
cols hold the column indices
"""
# we'll cheat here and just remove the name from the
# list of column names. The data will remain but
# it won't be shown
deleteCount = 0
cols = cols[:]
cols.sort()
for i in cols:
self.colnames.pop(i-deleteCount)
# we need to advance the delete count
# to make sure we delete the right columns
deleteCount += 1
if not len(self.colnames):
self.data = []
def DeleteRows(self, rows):
"""
rows -> delete the rows from the dataset
rows hold the row indices
"""
deleteCount = 0
rows = rows[:]
rows.sort()
for i in rows:
self.data.pop(i-deleteCount)
# we need to advance the delete count
# to make sure we delete the right rows
deleteCount += 1
def SortColumn(self, col):
"""
col -> sort the data based on the column indexed by col
"""
name = self.colnames[col]
_data = []
for row in self.data:
rowname, entry = row
_data.append((entry.get(name, None), row))
_data.sort()
self.data = []
for sortvalue, row in _data:
self.data.append(row)
# end table manipulation code
# ----------------------------------------------------------
# --------------------------------------------------------------------
# Sample wxGrid renderers
class MegaImageRenderer(wxPyGridCellRenderer):
def __init__(self, table):
"""
Image Renderer Test. This just places an image in a cell
based on the row index. There are N choices and the
choice is made by choice[row%N]
"""
wxPyGridCellRenderer.__init__(self)
self.table = table
self._choices = [images.getSmilesBitmap,
images.getMondrianBitmap,
images.get_10s_Bitmap,
images.get_01c_Bitmap]
self.colSize = None
self.rowSize = None
def Draw(self, grid, attr, dc, rect, row, col, isSelected):
choice = self.table.GetRawValue(row, col)
bmp = self._choices[ choice % len(self._choices)]()
image = wxMemoryDC()
image.SelectObject(bmp)
# clear the background
dc.SetBackgroundMode(wxSOLID)
if isSelected:
dc.SetBrush(wxBrush(wxBLUE, wxSOLID))
dc.SetPen(wxPen(wxBLUE, 1, wxSOLID))
else:
dc.SetBrush(wxBrush(wxWHITE, wxSOLID))
dc.SetPen(wxPen(wxWHITE, 1, wxSOLID))
dc.DrawRectangle(rect.x, rect.y, rect.width, rect.height)
# copy the image but only to the size of the grid cell
width, height = bmp.GetWidth(), bmp.GetHeight()
if width > rect.width-2:
width = rect.width-2
if height > rect.height-2:
height = rect.height-2
dc.Blit(rect.x+1, rect.y+1, width, height,
image,
0, 0, wxCOPY, True)
class MegaFontRenderer(wxPyGridCellRenderer):
def __init__(self, table, color="blue", font="ARIAL", fontsize=8):
"""Render data in the specified color and font and fontsize"""
wxPyGridCellRenderer.__init__(self)
self.table = table
self.color = color
self.font = wxFont(fontsize, wxDEFAULT, wxNORMAL, wxNORMAL,
0, font)
self.selectedBrush = wxBrush("blue",
wxSOLID)
self.normalBrush = wxBrush(wxWHITE, wxSOLID)
self.colSize = None
self.rowSize = 50
def Draw(self, grid, attr, dc, rect, row, col, isSelected):
# Here we draw text in a grid cell using various fonts
# and colors. We have to set the clipping region on
# the grid's DC, otherwise the text will spill over
# to the next cell
dc.SetClippingRect(rect)
# clear the background
dc.SetBackgroundMode(wxSOLID)
if isSelected:
dc.SetBrush(wxBrush(wxBLUE, wxSOLID))
dc.SetPen(wxPen(wxBLUE, 1, wxSOLID))
else:
dc.SetBrush(wxBrush(wxWHITE, wxSOLID))
dc.SetPen(wxPen(wxWHITE, 1, wxSOLID))
dc.DrawRectangle(rect.x, rect.y, rect.width, rect.height)
text = self.table.GetValue(row, col)
dc.SetBackgroundMode(wxSOLID)
# change the text background based on whether the grid is selected
# or not
if isSelected:
dc.SetBrush(self.selectedBrush)
dc.SetTextBackground("blue")
else:
dc.SetBrush(self.normalBrush)
dc.SetTextBackground("white")
dc.SetTextForeground(self.color)
dc.SetFont(self.font)
dc.DrawText(text, rect.x+1, rect.y+1)
# Okay, now for the advanced class :)
# Let's add three dots "..."
# to indicate that that there is more text to be read
# when the text is larger than the grid cell
width, height = dc.GetTextExtent(text)
if width > rect.width-2:
width, height = dc.GetTextExtent("...")
x = rect.x+1 + rect.width-2 - width
dc.DrawRectangle(x, rect.y+1, width+1, height)
dc.DrawText("...", x, rect.y+1)
dc.DestroyClippingRegion()
# --------------------------------------------------------------------
# Sample Grid using a specialized table and renderers that can
# be plugged in based on column names
class MegaGrid(wxGrid):
def __init__(self, parent, data, colnames, plugins=None):
"""parent, data, colnames, plugins=None
Initialize a grid using the data defined in data and colnames
(see MegaTable for a description of the data format)
plugins is a dictionary of columnName -> column renderers.
"""
# The base class must be initialized *first*
wxGrid.__init__(self, parent, -1)
self._table = MegaTable(data, colnames, plugins)
self.SetTable(self._table)
self._plugins = plugins
EVT_GRID_LABEL_RIGHT_CLICK(self, self.OnLabelRightClicked)
def Reset(self):
"""reset the view based on the data in the table. Call
this when rows are added or destroyed"""
self._table.ResetView(self)
def OnLabelRightClicked(self, evt):
# Did we click on a row or a column?
row, col = evt.GetRow(), evt.GetCol()
if row == -1: self.colPopup(col, evt)
elif col == -1: self.rowPopup(row, evt)
def rowPopup(self, row, evt):
"""(row, evt) -> display a popup menu when a row label is right clicked"""
appendID = wxNewId()
deleteID = wxNewId()
x = self.GetRowSize(row)/2
if not self.GetSelectedRows():
self.SelectRow(row)
menu = wxMenu()
xo, yo = evt.GetPosition()
menu.Append(appendID, "Append Row")
menu.Append(deleteID, "Delete Row(s)")
def append(event, self=self, row=row):
self._table.AppendRow(row)
self.Reset()
def delete(event, self=self, row=row):
rows = self.GetSelectedRows()
self._table.DeleteRows(rows)
self.Reset()
EVT_MENU(self, appendID, append)
EVT_MENU(self, deleteID, delete)
self.PopupMenu(menu, wxPoint(x, yo))
menu.Destroy()
def colPopup(self, col, evt):
"""(col, evt) -> display a popup menu when a column label is
right clicked"""
x = self.GetColSize(col)/2
menu = wxMenu()
id1 = wxNewId()
sortID = wxNewId()
xo, yo = evt.GetPosition()
self.SelectCol(col)
cols = self.GetSelectedCols()
self.Refresh()
menu.Append(id1, "Delete Col(s)")
menu.Append(sortID, "Sort Column")
def delete(event, self=self, col=col):
cols = self.GetSelectedCols()
self._table.DeleteCols(cols)
self.Reset()
def sort(event, self=self, col=col):
self._table.SortColumn(col)
self.Reset()
EVT_MENU(self, id1, delete)
if len(cols) == 1:
EVT_MENU(self, sortID, sort)
self.PopupMenu(menu, wxPoint(xo, 0))
menu.Destroy()
# -----------------------------------------------------------------
# Test data
# data is in the form
# [rowname, dictionary]
# where dictionary.get(colname, None) -> returns the value for the cell
#
# the colname must also be supplied
import random
colnames = ["Row", "This", "Is", "A", "Test"]
data = []
for row in range(1000):
d = {}
for name in ["This", "Test", "Is"]:
d[name] = random.random()
d["Row"] = len(data)
# XXX
# the "A" column can only be between one and 4
d["A"] = random.choice(range(4))
data.append((str(row), d))
class MegaFontRendererFactory:
def __init__(self, color, font, fontsize):
"""
(color, font, fontsize) -> set of a factory to generate
renderers when called.
func = MegaFontRenderFactory(color, font, fontsize)
renderer = func(table)
"""
self.color = color
self.font = font
self.fontsize = fontsize
def __call__(self, table):
return MegaFontRenderer(table, self.color, self.font, self.fontsize)
#---------------------------------------------------------------------------
class TestFrame(wxFrame):
def __init__(self, parent, plugins={"This":MegaFontRendererFactory("red", "ARIAL", 8),
"A":MegaImageRenderer,
"Test":MegaFontRendererFactory("orange", "TIMES", 24),}):
wxFrame.__init__(self, parent, -1,
"Test Frame", size=(640,480))
grid = MegaGrid(self, data, colnames, plugins)
grid.Reset()
#---------------------------------------------------------------------------
def runTest(frame, nb, log):
win = TestFrame(frame)
frame.otherWin = win
win.Show(True)
overview = """Mega Grid Example
This example attempts to show many examples and tricks of
using a virtual grid object. Hopefully the source isn't too jumbled.
Features:
1) Uses a virtual grid
2) Columns and rows have popup menus (right click on labels)
3) Columns and rows can be deleted (i.e. table can be
resized)
4) Dynamic renderers. Renderers are plugins based on
column header name. Shows a simple Font Renderer and
an Image Renderer.
Look for XXX in the code to indicate some workarounds for non-obvious
behavior and various hacks.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -35,3 +35,12 @@ overview = """\
At long last there is finally a way to load any supported image type
directly from any Python file-like object, such as a memory buffer
using StringIO. """
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -195,3 +195,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -46,3 +46,11 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -114,10 +114,13 @@ def runTest(frame, nb, log):
overview = """\
Objects of this class can be associated with a window to define its layout constraints, with respect to siblings or its parent.
overview = """\<html><body>
Objects of this class can be associated with a window to define its
layout constraints, with respect to siblings or its parent.
The class consists of the following eight constraints of class wxIndividualLayoutConstraint, some or all of which should be accessed directly to set the appropriate constraints.
The class consists of the following eight constraints of class
wxIndividualLayoutConstraint, some or all of which should be accessed
directly to set the appropriate constraints.
left: represents the left hand edge of the window
@@ -135,10 +138,21 @@ centreX: represents the horizontal centre point of the window
centreY: represents the vertical centre point of the window
Most constraints are initially set to have the relationship wxUnconstrained, which means that their values should be calculated by looking at known constraints. The exceptions are width and height, which are set to wxAsIs to ensure that if the user does not specify a constraint, the existing width and height will be used, to be compatible with panel items which often have take a default size. If the constraint is wxAsIs, the dimension will not be changed.
Most constraints are initially set to have the relationship
wxUnconstrained, which means that their values should be calculated by
looking at known constraints. The exceptions are width and height,
which are set to wxAsIs to ensure that if the user does not specify a
constraint, the existing width and height will be used, to be
compatible with panel items which often have take a default size. If
the constraint is wxAsIs, the dimension will not be changed.
wxLayoutConstraints()
-------------------------------------------
Constructor.
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -98,6 +98,7 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
self.list = TestListCtrl(self, tID,
style=wxLC_REPORT | wxSUNKEN_BORDER
| wxLC_EDIT_LABELS
#| wxLC_NO_HEADER
#| wxLC_VRULES | wxLC_HRULES
)
@@ -121,6 +122,7 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
EVT_LIST_COL_BEGIN_DRAG(self, tID, self.OnColBeginDrag)
EVT_LIST_COL_DRAGGING(self, tID, self.OnColDragging)
EVT_LIST_COL_END_DRAG(self, tID, self.OnColEndDrag)
EVT_LIST_BEGIN_LABEL_EDIT(self, tID, self.OnBeginEdit)
EVT_LEFT_DCLICK(self.list, self.OnDoubleClick)
EVT_RIGHT_DOWN(self.list, self.OnRightDown)
@@ -218,6 +220,8 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
#event.Veto() # doesn't work
# this does
self.list.SetItemState(10, 0, wxLIST_STATE_SELECTED)
event.Skip()
def OnItemDeselected(self, evt):
item = evt.GetItem()
@@ -233,6 +237,10 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
self.log.WriteText("OnItemActivated: %s\nTopItem: %s" %
(self.list.GetItemText(self.currentItem), self.list.GetTopItem()))
def OnBeginEdit(self, event):
self.log.WriteText("OnBeginEdit")
event.Allow()
def OnItemDelete(self, event):
self.log.WriteText("OnItemDelete\n")
@@ -265,30 +273,30 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
def OnRightClick(self, event):
self.log.WriteText("OnRightClick %s\n" % self.list.GetItemText(self.currentItem))
# only do this part the first time
# only do this part the first time so the events are only bound once
if not hasattr(self, "popupID1"):
self.popupID1 = wxNewId()
self.popupID2 = wxNewId()
self.popupID3 = wxNewId()
self.popupID4 = wxNewId()
self.popupID5 = wxNewId()
self.popupID6 = wxNewId()
EVT_MENU(self, self.popupID1, self.OnPopupOne)
EVT_MENU(self, self.popupID2, self.OnPopupTwo)
EVT_MENU(self, self.popupID3, self.OnPopupThree)
EVT_MENU(self, self.popupID4, self.OnPopupFour)
EVT_MENU(self, self.popupID5, self.OnPopupFive)
EVT_MENU(self, self.popupID6, self.OnPopupSix)
# make a menu
menu = wxMenu()
# Show how to put an icon in the menu
item = wxMenuItem(menu, self.popupID1,"One")
item.SetBitmap(images.getSmilesBitmap())
menu.AppendItem(item)
# add some other items
menu.Append(self.popupID2, "Two")
# add some items
menu.Append(self.popupID1, "FindItem tests")
# menu.Append(self.popupID2, "Two")
menu.Append(self.popupID3, "ClearAll and repopulate")
menu.Append(self.popupID4, "DeleteAllItems")
menu.Append(self.popupID5, "GetItem")
menu.Append(self.popupID6, "Edit")
# Popup the menu. If an item is selected then its handler
# will be called before PopupMenu returns.
@@ -308,8 +316,6 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
self.log.WriteText("Popup three\n")
self.list.ClearAll()
wxCallAfter(self.PopulateList)
#wxYield()
#self.PopulateList()
def OnPopupFour(self, event):
self.list.DeleteAllItems()
@@ -318,6 +324,10 @@ class TestListCtrlPanel(wxPanel, wxColumnSorterMixin):
item = self.list.GetItem(self.currentItem)
print item.m_text, item.m_itemId, self.list.GetItemData(self.currentItem)
def OnPopupSix(self, event):
self.list.EditLabel(self.currentItem)
def OnSize(self, event):
w,h = self.GetClientSizeTuple()
self.list.SetDimensions(0, 0, w, h)

View File

@@ -53,7 +53,7 @@ class TestVirtualList(wxListCtrl):
return item.GetText()
def OnItemDeselected(self, evt):
print evt.m_itemIndex
self.log.WriteText("OnItemDeselected: %s" % evt.m_itemIndex)
#---------------------------------------------------

View File

@@ -52,3 +52,12 @@ it. Here are a couple samples of how to use it.
</body></html>
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -51,13 +51,22 @@ def runTest(frame, nb, log):
overview = """\
wxMVCTree is a control which handles hierarchical data. It is constructed in model-view-controller architecture, so the display of that data, and the content of the data can be changed greatly without affecting the other parts.
wxMVCTree is a control which handles hierarchical data. It is
constructed in model-view-controller architecture, so the display of
that data, and the content of the data can be changed greatly without
affecting the other parts.
Multiple selections are possible by holding down the Ctrl key.
This demo shows the wxPython directory structure. The interesting part is that the tree model is late-bound to the filesystem, so the filenames are not retrieved until the directory is expanded. In mvctree.py are models for generic data, and both the early and late-bound filesystem models.
This demo shows the wxPython directory structure. The interesting part
is that the tree model is late-bound to the filesystem, so the
filenames are not retrieved until the directory is expanded. In
mvctree.py are models for generic data, and both the early and
late-bound filesystem models.
There is also support for editing, though it's not enabled in this demo, to avoid accidentally renaming files!
There is also support for editing, though it's not enabled in this
demo, to avoid accidentally renaming files!
"""
@@ -65,6 +74,7 @@ There is also support for editing, though it's not enabled in this demo, to avoi
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -7,6 +7,8 @@
from wxPython.wx import *
import time
#-------------------------------------------------------------------
class MyFrame(wxFrame):
@@ -68,14 +70,24 @@ check the source for this sample to see how to implement them.
menu5 = wxMenu()
menu5.Append(501, "Interesting thing\tCtrl+A", "Note the shortcut!")
menu5.AppendSeparator()
menu5.Append(502, "Hello\tShift+H")
menu5.AppendSeparator()
menu5.Append(503, "remove the submenu")
menu6 = wxMenu()
menu6.Append(601, "Submenu Item")
menu5.AppendMenu(504, "submenu", menu6)
menu5.Append(505, "remove this menu")
menu5.Append(506, "this is updated")
menu5.Append(507, "insert after this...")
menu5.Append(508, "...and before this")
menuBar.Append(menu5, "&Fun")
self.SetMenuBar(menuBar)
# Menu events
EVT_MENU_HIGHLIGHT_ALL(self, self.OnMenuHighlight)
EVT_MENU(self, 101, self.Menu101)
EVT_MENU(self, 102, self.Menu102)
EVT_MENU(self, 103, self.Menu103)
@@ -97,9 +109,25 @@ check the source for this sample to see how to implement them.
EVT_MENU(self, 501, self.Menu501)
EVT_MENU(self, 502, self.Menu502)
EVT_MENU(self, 503, self.TestRemove)
EVT_MENU(self, 505, self.TestRemove2)
EVT_MENU(self, 507, self.TestInsert)
EVT_MENU(self, 508, self.TestInsert)
EVT_UPDATE_UI(wxGetApp(), 506, self.TestUpdateUI)
# Methods
def OnMenuHighlight(self, event):
# Show how to get menu item imfo from this event handler
id = event.GetMenuId()
item = self.GetMenuBar().FindItemById(id)
text = item.GetText()
help = item.GetHelp()
#print text, help
event.Skip() # but in this case just call Skip so the default is done
def Menu101(self, event):
self.log.write('Welcome to Mercury\n')
@@ -146,8 +174,49 @@ check the source for this sample to see how to implement them.
def Menu502(self, event):
self.log.write('Hello from Jean-Michel\n')
def TestRemove(self, evt):
mb = self.GetMenuBar()
submenuItem = mb.FindItemById(601)
if not submenuItem:
return
submenu = submenuItem.GetMenu()
menu = submenu.GetParent()
#menu.Remove(504) # works
menu.RemoveItem(mb.FindItemById(504)) # this also works
#menu.RemoveItem(submenuItem) # doesn't work, as expected since submenuItem is not on menu
def TestRemove2(self, evt):
mb = self.GetMenuBar()
mb.Remove(4)
def TestUpdateUI(self, evt):
text = time.ctime()
evt.SetText(text)
def TestInsert(self, evt):
# get the menu
mb = self.GetMenuBar()
menuItem = mb.FindItemById(507)
menu = menuItem.GetMenu()
ID = wxNewId()
##menu.Insert(9, ID, "NewItem " + str(ID))
item = wxMenuItem(menu)
item.SetId(ID)
item.SetText("NewItem " + str(ID))
menu.InsertItem(9, item)
#-------------------------------------------------------------------
wxRegisterId(10000)
def runTest(frame, nb, log):
win = MyFrame(frame, -1, log)
frame.otherWin = win

View File

@@ -25,39 +25,14 @@ def runTest(frame, nb, log):
overview = """\
wxMessageDialog()
----------------------------------
wxMessageDialog(wxWindow* parent, const wxString& message, const wxString& caption = "Message box", long style = wxOK | wxCANCEL | wxCENTRE, const wxPoint& pos = wxDefaultPosition)
Constructor. Use wxMessageDialog::ShowModal to show the dialog.
Parameters
-------------------
parent = Parent window.
message = Message to show on the dialog.
caption = The dialog caption.
style = A dialog style (bitlist) containing flags chosen from the following:
wxOK Show an OK button.
wxCANCEL Show a Cancel button.
wxYES_NO Show Yes and No buttons.
wxCENTRE Centre the message. Not Windows.
wxICON_EXCLAMATION Shows an exclamation mark icon. Windows only.
wxICON_HAND Shows a hand icon. Windows only.
wxICON_QUESTION Shows a question mark icon. Windows only.
wxICON_INFORMATION Shows an information (i) icon. Windows only.
pos = Dialog position.
Show a message to the user in a dialog
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -173,3 +173,11 @@ def MyBitmapsFunc( index ):
mimetypes_wdr.MyBitmapsFunc = MyBitmapsFunc
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -45,3 +45,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -25,3 +25,12 @@ def runTest(frame, nb, log):
overview = """\
"""
if __name__ == '__main__':
import sys,os
import run
run.main(['', os.path.basename(sys.argv[0])])

View File

@@ -14,7 +14,7 @@ import sys
class TestNB(wxNotebook):
def __init__(self, parent, id, log):
wxNotebook.__init__(self, parent, id, style=
#0
#wxNB_TOP
wxNB_BOTTOM
#wxNB_LEFT
#wxNB_RIGHT
@@ -59,11 +59,11 @@ class TestNB(wxNotebook):
win = self.makeColorPanel(wxCYAN)
self.AddPage(win, "Cyan")
win = self.makeColorPanel(wxWHITE)
self.AddPage(win, "White")
## win = self.makeColorPanel(wxWHITE)
## self.AddPage(win, "White")
win = self.makeColorPanel(wxBLACK)
self.AddPage(win, "Black")
## win = self.makeColorPanel(wxBLACK)
## self.AddPage(win, "Black")
win = self.makeColorPanel(wxNamedColour('MIDNIGHT BLUE'))
self.AddPage(win, "MIDNIGHT BLUE")
@@ -88,16 +88,17 @@ class TestNB(wxNotebook):
def OnPageChanged(self, event):
old = event.GetOldSelection()
new = event.GetSelection()
self.log.write('OnPageChanged, old:%d, new:%d\n' % (old, new))
sel = self.GetSelection()
self.log.write('OnPageChanged, old:%d, new:%d, sel:%d\n' % (old, new, sel))
event.Skip()
def OnPageChanging(self, event):
old = event.GetOldSelection()
new = event.GetSelection()
self.log.write('OnPageChanging, old:%d, new:%d\n' % (old, new))
sel = self.GetSelection()
self.log.write('OnPageChanging, old:%d, new:%d, sel:%d\n' % (old, new, sel))
event.Skip()
#----------------------------------------------------------------------------
def runTest(frame, nb, log):

View File

@@ -106,7 +106,7 @@ class MyEvtHandler(wxShapeEvtHandler):
def OnLeftClick(self, x, y, keys = 0, attachment = 0):
shape = self.GetShape()
print shape.__class__
print shape.__class__, shape.GetClassName()
canvas = shape.GetCanvas()
dc = wxClientDC(canvas)
canvas.PrepareDC(dc)

Some files were not shown because too many files have changed in this diff Show More