Some bug fixes for Clipboard and Drag-n-Drop.
+Rotated text!!! WooHoo! (See wxDC.DrawRotatedtext())
+
+Added a set of Generic Buttons to the library. These are simple
+window classes that look and act like native buttons, but you can have
+a bit more control over them. The bezel width can be set in addition
+to colours, fonts, etc. There is a ToggleButton as well as Bitmap
+versions too.
--- /dev/null
+
+from wxPython.wx import *
+from wxPython.lib.buttons import wxGenButton, wxGenBitmapButton, \
+ wxGenToggleButton, wxGenBitmapToggleButton
+
+#----------------------------------------------------------------------
+
+
+class TestPanel(wxPanel):
+ def __init__(self, parent, log):
+ wxPanel.__init__(self, parent, -1)
+ self.log = log
+
+ b = wxButton(self, -1, "A real button", (10,10))
+ b.SetDefault()
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+ b = wxButton(self, -1, "non-default", (100, 10))
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+ #wxTextCtrl(self, -1, "", (10,40))
+
+ b = wxGenButton(self, -1, 'Hello', (10,65))
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+ b = wxGenButton(self, -1, 'disabled', (100,65))
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+ b.Enable(false)
+
+ b = wxGenButton(self, -1, 'bigger', (195,50), (120, 55))
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+ b.SetFont(wxFont(20, wxSWISS, wxNORMAL, wxBOLD, false))
+ b.SetBezelWidth(5)
+ b.SetBackgroundColour(wxBLUE)
+ b.SetForegroundColour(wxWHITE)
+ #b.SetUseFocusIndicator(false)
+
+ bmp = wxBitmap('bitmaps/test2.bmp', wxBITMAP_TYPE_BMP)
+ b = wxGenBitmapButton(self, -1, bmp, (10, 130),
+ (bmp.GetWidth()+16, bmp.GetHeight()+16))
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+
+
+ b = wxGenBitmapButton(self, -1, None, (100, 130), (48,48))
+ EVT_BUTTON(self, b.GetId(), self.OnButton)
+ bmp = wxBitmap('bitmaps/lb1.bmp', wxBITMAP_TYPE_BMP)
+ mask = wxMaskColour(bmp, wxBLUE)
+ bmp.SetMask(mask)
+ b.SetBitmapLabel(bmp)
+ bmp = wxBitmap('bitmaps/lb2.bmp', wxBITMAP_TYPE_BMP)
+ mask = wxMaskColour(bmp, wxBLUE)
+ bmp.SetMask(mask)
+ b.SetBitmapSelected(bmp)
+
+
+ b = wxGenToggleButton(self, -1, "Toggle Button", (10, 230), (85, 26))
+ EVT_BUTTON(self, b.GetId(), self.OnToggleButton)
+
+
+ b = wxGenBitmapToggleButton(self, -1, None, (100, 230), (48,48))
+ EVT_BUTTON(self, b.GetId(), self.OnToggleButton)
+ bmp = wxBitmap('bitmaps/lb1.bmp', wxBITMAP_TYPE_BMP)
+ mask = wxMaskColour(bmp, wxBLUE)
+ bmp.SetMask(mask)
+ b.SetBitmapLabel(bmp)
+ bmp = wxBitmap('bitmaps/lb2.bmp', wxBITMAP_TYPE_BMP)
+ mask = wxMaskColour(bmp, wxBLUE)
+ bmp.SetMask(mask)
+ b.SetBitmapSelected(bmp)
+
+
+ def OnButton(self, event):
+ self.log.WriteText("Button Clicked: %d\n" % event.GetId())
+
+ def OnToggleButton(self, event):
+ msg = (event.GetIsDown() and "on") or "off"
+ self.log.WriteText("Button %d Toggled: %s\n" % (event.GetId(), msg))
+
+
+
+#----------------------------------------------------------------------
+
+
+def runTest(frame, nb, log):
+ win = TestPanel(nb, log)
+ return win
+
+
+#----------------------------------------------------------------------
+
+
+import wxPython.lib.buttons
+overview = wxPython.lib.buttons.__doc__
_treeList = [
('New since last release', ['wxMVCTree', 'wxVTKRenderWindow',
- 'FileBrowseButton']),
+ 'FileBrowseButton', #'wxToggleButton',
+ 'GenericButtons']),
('Managed Windows', ['wxFrame', 'wxDialog', 'wxMiniFrame']),
('Controls', ['wxButton', 'wxCheckBox', 'wxCheckListBox', 'wxChoice',
'wxComboBox', 'wxGauge', 'wxListBox', 'wxListCtrl', 'wxTextCtrl',
'wxTreeCtrl', 'wxSpinButton', 'wxStaticText', 'wxStaticBitmap',
- 'wxRadioBox', 'wxSlider']),
+ 'wxRadioBox', 'wxSlider', #'wxToggleButton'
+ ]),
('Window Layout', ['wxLayoutConstraints', 'Sizers', 'OldSizers']),
('wxPython Library', ['Layoutf', 'wxScrolledMessageDialog',
'wxMultipleChoiceDialog', 'wxPlotCanvas', 'wxFloatBar',
'PyShell', 'wxCalendar', 'wxMVCTree', 'wxVTKRenderWindow',
- 'FileBrowseButton',]),
+ 'FileBrowseButton', 'GenericButtons']),
('Cool Contribs', ['pyTree', 'hangman', 'SlashDot', 'XMLtreeview']),
self.treeMap = {}
self.tree = wxTreeCtrl(splitter, tID)
root = self.tree.AddRoot("Overview")
+ firstChild = None
for item in _treeList:
child = self.tree.AppendItem(root, item[0])
+ if not firstChild: firstChild = child
for childItem in item[1]:
theDemo = self.tree.AppendItem(child, childItem)
self.treeMap[childItem] = theDemo
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_BUTTON(self, 20, self.OnClick)
bmp = wxBitmap('bitmaps/test2.bmp', wxBITMAP_TYPE_BMP)
- mask = wxMaskColour(bmp, wxBLUE)
- bmp.SetMask(mask)
+ #mask = wxMaskColour(bmp, wxBLUE)
+ #bmp.SetMask(mask)
wxBitmapButton(self, 30, bmp, wxPoint(140, 20),
wxSize(bmp.GetWidth()+10, bmp.GetHeight()+10))
EVT_BUTTON(self, 30, self.OnClick)
dc.SetTextForeground(wxColour(0, 0xFF, 0x80))
dc.DrawText("a bitmap", 200, 85)
+ font = wxFont(20, wxSWISS, wxNORMAL, wxNORMAL)
+ dc.SetFont(font)
+ dc.SetTextForeground(wxBLACK)
+ for a in range(0, 360, 45):
+ dc.DrawRotatedText("Rotated text...", 300, 300, a)
+
self.DrawSavedLines(dc)
dc.EndDrawing()
from wxPython.wx import *
+#---------------------------------------------------------------------------
+
+class MySplitter(wxSplitterWindow):
+ def __init__(self, parent, ID, log):
+ wxSplitterWindow.__init__(self, parent, ID)
+ self.log = log
+ EVT_SPLITTER_SASH_POS_CHANGED(self, self.GetId(), self.OnSashChanged)
+
+ def OnSashChanged(self, evt):
+ self.log.WriteText("sash changed to " + str(evt.GetSashPosition()))
+
#---------------------------------------------------------------------------
def runTest(frame, nb, log):
- splitter = wxSplitterWindow(nb, -1)
+ splitter = MySplitter(nb, -1, log)
p1 = wxWindow(splitter, -1)
p1.SetBackgroundColour(wxRED)
# This is really the wxPython version number, and will be placed in the
# Makefiles for use with the distribution related targets.
-__version__ = '2.1.11'
+__version__ = '2.1.12'
#----------------------------------------------------------------------------
Flags=0000000010000010
end
item: Install File
- Source=e:\Projects\wx\utils\wxPython\README.txt
- Destination=%MAINDIR%\wxPython\README.txt
+ Source=e:\Projects\wx\utils\wxPython\*.txt
+ Destination=%MAINDIR%\wxPython
Description=README file
Flags=0000000010000010
end
--- /dev/null
+#----------------------------------------------------------------------
+# Name: wxPython.lib.buttons
+# Purpose: Various kinds of generic buttons, (not native controls but
+# self-drawn.)
+#
+# Author: Robin Dunn
+#
+# Created: 9-Dec-1999
+# RCS-ID: $Id$
+# Copyright: (c) 1999 by Total Control Software
+# Licence: wxWindows license
+#----------------------------------------------------------------------
+
+"""
+This module implements various forms of generic buttons, meaning that
+they are not built on native controls but are self-drawn.
+
+The wxGenButton is the base. It acts like a normal button but you
+are able to better control how it looks, bevel width, colours, etc.
+
+wxGenBitmapButton is a button with one or more bitmaps that show
+the various states the button can be in.
+
+wxGenToggleButton stays depressed when clicked, until clicked again.
+
+wxGenBitmapToggleButton the same but with bitmaps.
+
+"""
+
+from wxPython.wx import *
+
+#----------------------------------------------------------------------
+
+class wxGenButtonEvent(wxPyCommandEvent):
+ def __init__(self, eventType, ID):
+ wxPyCommandEvent.__init__(self, eventType, ID)
+ self.isDown = false
+
+ def SetIsDown(self, isDown):
+ self.isDown = isDown
+
+ def GetIsDown(self):
+ return self.isDown
+
+
+#----------------------------------------------------------------------
+
+class wxGenButton(wxWindow):
+ def __init__(self, parent, ID, label,
+ pos = wxDefaultPosition, size = wxDefaultSize,
+ style = 0, validator = wxDefaultValidator,
+ name = "genbutton"):
+ wxWindow.__init__(self, parent, ID, pos, size, style, name)
+ self.SetValidator(validator)
+
+ self.up = true
+ self.bezelWidth = 2
+ self.hasFocus = false
+ self.useFocusInd = true
+
+ self.SetLabel(label)
+ self.SetPosition(pos)
+ if type(size) == type(()):
+ size = wxSize(size[0], size[1])
+ w = size.width
+ h = size.height
+ dsize = wxSize(75,23) ### wxButton_GetDefaultSize()
+ if self.bezelWidth > 2:
+ dsize.width = dsize.width + self.bezelWidth - 2
+ dsize.height = dsize.height + self.bezelWidth - 2
+ if w == -1: w = dsize.width
+ if h == -1: h = dsize.height
+ self.SetSize(wxSize(w,h))
+ font = parent.GetFont()
+ if not font.Ok():
+ font = wxSystemSettings_GetSystemFont(wxSYS_DEFAULT_GUI_FONT)
+ self.SetFont(font)
+ self.InitColours()
+
+ EVT_LEFT_DOWN(self, self.OnLeftDown)
+ EVT_LEFT_UP(self, self.OnLeftUp)
+ EVT_MOTION(self, self.OnMotion)
+ EVT_SET_FOCUS(self, self.OnGainFocus)
+ EVT_KILL_FOCUS(self, self.OnLoseFocus)
+ EVT_KEY_DOWN(self, self.OnKeyDown)
+ EVT_KEY_UP(self, self.OnKeyUp)
+
+
+
+
+ def SetBezelWidth(self, width):
+ """Set the width of the 3D effect"""
+ self.bezelWidth = width
+
+ def GetBezelWidth(self):
+ """Return the width of the 3D effect"""
+ return self.bezelWidth
+
+ def SetUseFocusIndicator(self, flag):
+ """Specifiy if a focus indicator (dotted line) should be used"""
+ self.useFocusInd = flag
+
+ def GetUseFocusIndicator(self):
+ """Return focus indicator flag"""
+ return self.useFocusInd
+
+
+ def InitColours(self):
+ faceClr = wxSystemSettings_GetSystemColour(wxSYS_COLOUR_BTNFACE)
+ textClr = wxSystemSettings_GetSystemColour(wxSYS_COLOUR_BTNTEXT)
+ self.SetBackgroundColour(faceClr)
+ self.SetForegroundColour(textClr)
+
+ shadowClr = wxSystemSettings_GetSystemColour(wxSYS_COLOUR_BTNSHADOW)
+ highlightClr = wxSystemSettings_GetSystemColour(wxSYS_COLOUR_BTNHIGHLIGHT)
+ self.shadowPen = wxPen(shadowClr, 1, wxSOLID)
+ self.highlightPen = wxPen(highlightClr, 1, wxSOLID)
+
+ self.focusIndPen = wxPen(textClr, 1, wxUSER_DASH)
+
+
+ def Notify(self):
+ evt = wxGenButtonEvent(wxEVT_COMMAND_BUTTON_CLICKED, self.GetId())
+ evt.SetIsDown(not self.up)
+ self.GetEventHandler().ProcessEvent(evt)
+
+
+ def DrawBezel(self, dc, x1, y1, x2, y2):
+ # draw the upper left sides
+ if self.up:
+ dc.SetPen(self.highlightPen)
+ else:
+ dc.SetPen(self.shadowPen)
+ for i in range(self.bezelWidth):
+ dc.DrawLine(x1+i, y1, x1+i, y2-i)
+ dc.DrawLine(x1, y1+i, x2-i, y1+i)
+
+ # draw the lower right sides
+ if self.up:
+ dc.SetPen(self.shadowPen)
+ else:
+ dc.SetPen(self.highlightPen)
+ for i in range(self.bezelWidth):
+ dc.DrawLine(x1+i, y2-i, x2+1, y2-i)
+ dc.DrawLine(x2-i, y1+i, x2-i, y2)
+
+
+ def DrawLabel(self, dc, width, height, dw=0, dy=0):
+ dc.SetFont(self.GetFont())
+ if self.IsEnabled():
+ dc.SetTextForeground(self.GetForegroundColour())
+ else:
+ dc.SetTextForeground(wxSystemSettings_GetSystemColour(wxSYS_COLOUR_GRAYTEXT))
+ label = self.GetLabel()
+ tw, th = dc.GetTextExtent(label)
+ if not self.up:
+ dw = dy = 1
+ dc.DrawText(label, (width-tw)/2+dw, (height-th)/2+dy)
+
+
+ def DrawFocusIndicator(self, dc, w, h):
+ bw = self.bezelWidth
+ dc.SetLogicalFunction(wxINVERT)
+ self.focusIndPen.SetColour(self.GetForegroundColour())
+ self.focusIndPen.SetDashes([1,2,1,2]) # This isn't quite working the way I expected...
+ dc.SetPen(self.focusIndPen)
+ dc.SetBrush(wxTRANSPARENT_BRUSH)
+ dc.DrawRectangle(bw+2,bw+2, w-bw*2-4, h-bw*2-4)
+
+
+ def OnPaint(self, event):
+ (width, height) = self.GetClientSizeTuple()
+ x1 = y1 = 0
+ x2 = width-1
+ y2 = height-1
+ dc = wxPaintDC(self)
+ dc.SetBackground(wxBrush(self.GetBackgroundColour(), wxSOLID))
+ dc.Clear()
+ self.DrawBezel(dc, x1, y1, x2, y2)
+ self.DrawLabel(dc, width, height)
+ if self.hasFocus and self.useFocusInd:
+ self.DrawFocusIndicator(dc, width, height)
+
+ def OnEraseBackground(self, event):
+ pass
+
+
+ def OnLeftDown(self, event):
+ if not self.IsEnabled():
+ return
+ self.up = false
+ self.CaptureMouse()
+ self.SetFocus()
+ self.Refresh()
+
+
+ def OnLeftUp(self, event):
+ if not self.IsEnabled():
+ return
+ if not self.up: # if the button was down when the mouse was released...
+ self.Notify()
+ self.up = true
+ self.ReleaseMouse()
+ self.Refresh()
+
+
+ def OnMotion(self, event):
+ if not self.IsEnabled():
+ return
+ if event.LeftIsDown():
+ x,y = event.GetPositionTuple()
+ w,h = self.GetClientSizeTuple()
+ if self.up and x<w and x>=0 and y<h and y>=0:
+ self.up = false
+ self.Refresh()
+ return
+ if not self.up and (x<0 or y<0 or x>=w or y>=h):
+ self.up = true
+ self.Refresh()
+ return
+
+
+ def OnGainFocus(self, event):
+ self.hasFocus = true
+ dc = wxClientDC(self)
+ w, h = self.GetClientSizeTuple()
+ if self.useFocusInd:
+ self.DrawFocusIndicator(dc, w, h)
+
+
+ def OnLoseFocus(self, event):
+ self.hasFocus = false
+ dc = wxClientDC(self)
+ w, h = self.GetClientSizeTuple()
+ if self.useFocusInd:
+ self.DrawFocusIndicator(dc, w, h)
+
+
+ def OnKeyDown(self, event):
+ if self.hasFocus and event.KeyCode() == ord(" "):
+ self.up = false
+ self.Refresh()
+ event.Skip()
+
+ def OnKeyUp(self, event):
+ if self.hasFocus and event.KeyCode() == ord(" "):
+ self.up = true
+ self.Notify()
+ self.Refresh()
+ event.Skip()
+
+
+#----------------------------------------------------------------------
+
+class wxGenBitmapButton(wxGenButton):
+ def __init__(self, parent, ID, bitmap,
+ pos = wxDefaultPosition, size = wxDefaultSize,
+ style = 0, validator = wxDefaultValidator,
+ name = "genbutton"):
+ wxGenButton.__init__(self, parent, ID, "", pos, size, style, validator, name)
+
+ self.bmpLabel = bitmap
+ self.bmpDisabled = None
+ self.bmpFocus = None
+ self.bmpSelected = None
+
+ def GetBitmapLabel(self):
+ return self.bmpLabel
+ def GetBitmapDisabled(self):
+ return self.bmpDisabled
+ def GetBitmapFocus(self):
+ return self.bmpFocus
+ def GetBitmapSelected(self):
+ return self.bmpSelected
+
+ def SetBitmapDisabled(self, bitmap):
+ self.bmpDisabled = bitmap
+ def SetBitmapFocus(self, bitmap):
+ self.bmpFocus = bitmap
+ self.SetUseFocusIndicator(false)
+ def SetBitmapSelected(self, bitmap):
+ self.bmpSelected = bitmap
+ def SetBitmapLabel(self, bitmap):
+ self.bmpLabel = bitmap
+
+
+ def DrawLabel(self, dc, width, height, dw=0, dy=0):
+ bmp = self.bmpLabel
+ if self.bmpDisabled and not self.IsEnabled():
+ bmp = self.bmpDisabled
+ if self.bmpFocus and self.hasFocus:
+ bmp = self.bmpFocus
+ if self.bmpSelected and not self.up:
+ bmp = self.bmpSelected
+ bw,bh = bmp.GetWidth(), bmp.GetHeight()
+ if not self.up:
+ dw = dy = 1
+ dc.DrawBitmap(bmp, (width-bw)/2+dw, (height-bh)/2+dy, true)
+
+
+
+#----------------------------------------------------------------------
+
+
+class __ToggleMixin:
+ def OnLeftDown(self, event):
+ if not self.IsEnabled():
+ return
+ self.up = not self.up
+ self.CaptureMouse()
+ self.SetFocus()
+ self.Refresh()
+
+ def OnLeftUp(self, event):
+ if not self.IsEnabled():
+ return
+ self.Notify()
+ self.ReleaseMouse()
+ self.Refresh()
+
+ def OnKeyDown(self, event):
+ event.Skip()
+
+ def OnKeyUp(self, event):
+ if self.hasFocus and event.KeyCode() == ord(" "):
+ self.up = not self.up
+ self.Notify()
+ self.Refresh()
+ event.Skip()
+
+
+class wxGenToggleButton(__ToggleMixin, wxGenButton):
+ pass
+
+class wxGenBitmapToggleButton(__ToggleMixin, wxGenBitmapButton):
+ pass
+
+#----------------------------------------------------------------------
+
+
#----------------------------------------------------------------------
"""
-
In this module you will find wxGridSizer and wxFlexGridSizer.
wxGridSizer arrainges its items in a grid in which all the widths and
heights are the same. wxFlexgridSizer allows different widths and
heights, and you can also specify rows and/or columns that are
growable. See the demo for a couple examples for how to use them.
-
"""
OTHERSWIGFLAGS = '-I../utils'
# include path for htmlhelp's xpm bitmaps
-OTHERCFLAGS = "-I%s/src/html" % (WXDIR,)
+#OTHERCFLAGS = "-I%s/src/html" % (WXDIR,)
# There are no platform differences so we don't need separate code directories
GENCODEDIR='.'
-ver = '2.1.11'
+ver = '2.1.12'
wxDefaultPosition = wxPyDefaultPosition
wxDefaultSize = wxPyDefaultSize
+# backwards compatibility
+wxNoRefBitmap = wxBitmap
#----------------------------------------------------------------------
# This helper function will take a wxPython object and convert it to
newPtr = ptrcast(obj, typeStr+"_p")
theClass = globals()[typeStr+"Ptr"]
theObj = theClass(newPtr)
- theObj.thisown = obj.thisown
+ if hasattr(obj, "this"):
+ theObj.thisown = obj.thisown
return theObj
if self.stdioWin != None:
self.stdioWin.close()
+#----------------------------------------------------------------------------
+
+class wxPySimpleApp(wxApp):
+ def __init__(self):
+ wxApp.__init__(self, 0)
+ def OnInit(self):
+ return true
#----------------------------------------------------------------------------
};
%{
+ // See below in the init function...
wxClipboard* wxPyTheClipboard;
%}
%readonly
#include <wx/spinbutt.h>
#include <wx/dynarray.h>
#include <wx/statline.h>
+//#include <wx/toggbutt.h>
#ifdef __WXMSW__
#if wxUSE_OWNER_DRAWN
class wxControl : public wxWindow {
public:
+ wxControl();
+
#ifdef __WXMSW__
void Command(wxCommandEvent& event);
#endif
void SetLabel(const wxString& label);
};
+
+// %{
+// class wxPyControl : public wxControl {
+// public:
+// wxPyControl(wxWindow *parent,
+// wxWindowID id,
+// const wxPoint& pos,
+// const wxSize& size,
+// long style,
+// const wxValidator& validator,
+// const wxString& name)
+// : wxControl() {
+// CreateControl(parent, id, pos, size, style, validator, name);
+// }
+// };
+// %}
+
+
+// class wxPyControl : public wxControl {
+// public:
+// wxPyControl(wxWindow* parent, wxWindowID id,
+// const wxPoint& pos = wxPyDefaultPosition,
+// const wxSize& size = wxPyDefaultSize,
+// long style = 0,
+// const wxValidator& validator = wxPyDefaultValidator,
+// char* name = "control");
+// };
+
+
//----------------------------------------------------------------------
class wxButton : public wxControl {
void SetDefault();
};
+
+%inline %{
+ wxSize wxButton_GetDefaultSize() {
+ return wxButton::GetDefaultSize();
+ }
+%}
+
//----------------------------------------------------------------------
class wxBitmapButton : public wxButton {
};
+//----------------------------------------------------------------------
+
+// class wxToggleButton : public wxControl {
+// public:
+// wxToggleButton(wxWindow *parent, wxWindowID id, const wxString& label,
+// const wxPoint& pos = wxPyDefaultPosition,
+// const wxSize& size = wxPyDefaultSize, long style = 0,
+// const wxValidator& validator = wxPyDefaultValidator,
+// const char* name = "toggle");
+// void SetValue(bool value);
+// bool GetValue() const ;
+// void SetLabel(const wxString& label);
+// };
+
+// class wxBitmapToggleButton : public wxToggleButton {
+// public:
+// wxBitmapToggleButton(wxWindow *parent, wxWindowID id, const wxBitmap *label,
+// const wxPoint& pos = wxPyDefaultPosition,
+// const wxSize& size = wxPyDefaultSize, long style = 0,
+// const wxValidator& validator = wxPyDefaultValidator,
+// const char *name = "toggle");
+// void SetLabel(const wxBitmap& bitmap);
+// };
+
+
//----------------------------------------------------------------------
class wxCheckBox : public wxControl {
int GetSelection();
wxString GetString();
bool IsSelection();
+ void SetString(const wxString& s);
+ void SetExtraLong(long extraLong);
+ void SetInt(int i);
+
};
//---------------------------------------------------------------------------
-class wxBitmap {
+class wxGDIImage {
+public:
+ long GetHandle();
+ void SetHandle(long handle);
+
+ bool Ok();
+
+ int GetWidth();
+ int GetHeight();
+ int GetDepth();
+
+ void SetWidth(int w);
+ void SetHeight(int h);
+ void SetDepth(int d);
+
+ void SetSize(const wxSize& size);
+
+};
+
+//---------------------------------------------------------------------------
+
+class wxBitmap : public wxGDIImage {
public:
wxBitmap(const wxString& name, long type);
~wxBitmap();
-#ifdef __WXMSW__
- void Create(int width, int height, int depth = -1);
-#endif
- int GetDepth();
- int GetHeight();
wxPalette* GetPalette();
wxMask* GetMask();
- int GetWidth();
bool LoadFile(const wxString& name, long flags);
- bool Ok();
bool SaveFile(const wxString& name, int type, wxPalette* palette = NULL);
- void SetDepth(int depth);
- void SetHeight(int height);
void SetMask(wxMask* mask);
#ifdef __WXMSW__
void SetPalette(wxPalette& palette);
#endif
- void SetWidth(int width);
};
%new wxBitmap* wxEmptyBitmap(int width, int height, int depth=-1);
-wxBitmap* wxNoRefBitmap(char* name, long flags);
#ifdef __WXMSW__
%new wxBitmap* wxBitmapFromData(char* data, long type,
return new wxBitmap(width, height, depth);
}
- // This one won't own the reference, so Python
- // won't call the dtor, this is good for
- // toolbars and such where the parent will
- // manage the bitmap.
- wxBitmap* wxNoRefBitmap(char* name, long flags) {
- return new wxBitmap(name, flags);
- }
-
#ifdef __WXMSW__
wxBitmap* wxBitmapFromData(char* data, long type,
int width, int height, int depth = 1) {
//---------------------------------------------------------------------------
-class wxIcon : public wxBitmap {
+class wxIcon : public wxGDIImage {
public:
wxIcon(const wxString& name, long flags,
int desiredWidth = -1, int desiredHeight = -1);
~wxIcon();
- int GetDepth();
- int GetHeight();
- int GetWidth();
bool LoadFile(const wxString& name, long flags);
- bool Ok();
- void SetDepth(int depth);
- void SetHeight(int height);
- void SetWidth(int width);
};
//---------------------------------------------------------------------------
-class wxCursor : public wxBitmap {
+class wxCursor : public wxGDIImage {
public:
#ifdef __WXMSW__
wxCursor(const wxString& cursorName, long flags, int hotSpotX=0, int hotSpotY=0);
#endif
~wxCursor();
- bool Ok();
};
%name(wxStockCursor) %new wxCursor* wxPyStockCursor(int id);
//----------------------------------------------------------------------
+#ifdef __WXMSW__
typedef unsigned long wxDash;
+#else
+typedef byte wxDash;
+#endif
+
class wxPen {
public:
void SetStyle(int style);
void SetWidth(int width);
-#ifdef __WXMSW__
// **** This one needs to return a list of ints (wxDash)
int GetDashes(wxDash **dashes);
- wxBitmap* GetStipple();
void SetDashes(int LCOUNT, wxDash* LIST);
+
+#ifdef __WXMSW__
+ wxBitmap* GetStipple();
void SetStipple(wxBitmap& stipple);
#endif
};
int fill_style=wxODDEVEN_RULE);
void DrawPoint(long x, long y);
void DrawRectangle(long x, long y, long width, long height);
+ void DrawRotatedText(const wxString& text, wxCoord x, wxCoord y, double angle);
void DrawRoundedRectangle(long x, long y, long width, long height, long radius=20);
void DrawSpline(int LCOUNT, wxPoint* LIST);
void DrawText(const wxString& text, long x, long y);
class wxImageList {
public:
- wxImageList(int width, int height, const bool mask=TRUE, int initialCount=1);
+ wxImageList(int width, int height, int mask=TRUE, int initialCount=1);
~wxImageList();
#ifdef __WXMSW__
// This one isn't acutally called... See __wxStart()
bool wxPyApp::OnInit(void) {
- return false;
+ return FALSE;
}
int wxPyApp::MainLoop(void) {
wxPySaveThread(doSave);
}
+ // See below in the init function...
wxClipboard* wxPyTheClipboard;
class wxPyDropSource : public wxDropSource {
{ "_EBool","_wxWindowID",0},
{ "_class_wxRegion","_wxRegion",0},
{ "_class_wxDataFormat","_wxDataFormat",0},
+ { "_wxGDIImage","_class_wxGDIImage",0},
{ "_wxFont","_class_wxFont",0},
{ "_class_wxPyDropTarget","_class_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxPyDropTarget},
{ "_class_wxPyDropTarget","_wxPyFileDropTarget",SwigwxPyFileDropTargetTowxPyDropTarget},
{ "_class_wxPyDataObjectSimple","_wxPyDataObjectSimple",0},
{ "_class_wxPyDropSource","_wxPyDropSource",0},
{ "_class_wxImageList","_wxImageList",0},
+ { "_class_wxGDIImage","_wxGDIImage",0},
{ "_wxWindowID","_wxCoord",0},
{ "_wxWindowID","_wxPrintQuality",0},
{ "_wxWindowID","_size_t",0},
#include <wx/spinbutt.h>
#include <wx/dynarray.h>
#include <wx/statline.h>
+//#include <wx/toggbutt.h>
#ifdef __WXMSW__
#if wxUSE_OWNER_DRAWN
static char* wxStringErrorMsg = "string type is required for parameter";
wxValidator wxPyDefaultValidator; // Non-const default because of SWIG
+
+ wxSize wxButton_GetDefaultSize() {
+ return wxButton::GetDefaultSize();
+ }
#ifdef __cplusplus
extern "C" {
#endif
return pyobj;
}
+static PyObject *_wrap_wxButton_GetDefaultSize(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxSize * _result;
+ char *_kwnames[] = { NULL };
+ char _ptemp[128];
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxButton_GetDefaultSize",_kwnames))
+ return NULL;
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = new wxSize (wxButton_GetDefaultSize());
+
+ wxPy_END_ALLOW_THREADS;
+} SWIG_MakePtr(_ptemp, (void *) _result,"_wxSize_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ return _resultobj;
+}
+
static void *SwigwxControlTowxWindow(void *ptr) {
wxControl *src;
wxWindow *dest;
return (void *) dest;
}
+#define new_wxControl() (new wxControl())
+static PyObject *_wrap_new_wxControl(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxControl * _result;
+ char *_kwnames[] = { NULL };
+ char _ptemp[128];
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,":new_wxControl",_kwnames))
+ return NULL;
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (wxControl *)new_wxControl();
+
+ wxPy_END_ALLOW_THREADS;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxControl_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
+ return _resultobj;
+}
+
#define wxControl_Command(_swigobj,_swigarg0) (_swigobj->Command(_swigarg0))
static PyObject *_wrap_wxControl_Command(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
{ "wxControl_SetLabel", (PyCFunction) _wrap_wxControl_SetLabel, METH_VARARGS | METH_KEYWORDS },
{ "wxControl_GetLabel", (PyCFunction) _wrap_wxControl_GetLabel, METH_VARARGS | METH_KEYWORDS },
{ "wxControl_Command", (PyCFunction) _wrap_wxControl_Command, METH_VARARGS | METH_KEYWORDS },
+ { "new_wxControl", (PyCFunction) _wrap_new_wxControl, METH_VARARGS | METH_KEYWORDS },
+ { "wxButton_GetDefaultSize", (PyCFunction) _wrap_wxButton_GetDefaultSize, METH_VARARGS | METH_KEYWORDS },
{ NULL, NULL }
};
#ifdef __cplusplus
{ "_class_wxDataFormat","_wxDataFormat",0},
{ "_class_wxDropFilesEvent","_wxDropFilesEvent",0},
{ "_wxWindowDestroyEvent","_class_wxWindowDestroyEvent",0},
+ { "_wxGDIImage","_class_wxGDIImage",0},
{ "_wxStaticText","_class_wxStaticText",0},
{ "_wxFont","_class_wxFont",0},
{ "_class_wxPyDropTarget","_wxPyDropTarget",0},
{ "_class_wxSlider","_wxSlider",0},
{ "_class_wxImageList","_wxImageList",0},
{ "_class_wxBitmapButton","_wxBitmapButton",0},
+ { "_class_wxGDIImage","_wxGDIImage",0},
{ "_class_wxPaletteChangedEvent","_wxPaletteChangedEvent",0},
{ "_wxWindowID","_wxCoord",0},
{ "_wxWindowID","_wxPrintQuality",0},
def __repr__(self):
return "<C wxControl instance at %s>" % (self.this,)
class wxControl(wxControlPtr):
- def __init__(self,this):
- self.this = this
+ def __init__(self,*_args,**_kwargs):
+ self.this = apply(controlsc.new_wxControl,_args,_kwargs)
+ self.thisown = 1
#-------------- FUNCTION WRAPPERS ------------------
+def wxButton_GetDefaultSize(*_args, **_kwargs):
+ val = apply(controlsc.wxButton_GetDefaultSize,_args,_kwargs)
+ if val: val = wxSizePtr(val); val.thisown = 1
+ return val
+
#-------------- VARIABLE WRAPPERS ------------------
{ "_class_wxDataFormat","_wxDataFormat",0},
{ "_class_wxDropFilesEvent","_wxDropFilesEvent",0},
{ "_wxWindowDestroyEvent","_class_wxWindowDestroyEvent",0},
+ { "_wxGDIImage","_class_wxGDIImage",0},
{ "_wxStaticText","_class_wxStaticText",0},
{ "_wxFont","_class_wxFont",0},
{ "_class_wxPyDropTarget","_wxPyDropTarget",0},
{ "_class_wxSlider","_wxSlider",0},
{ "_class_wxImageList","_wxImageList",0},
{ "_class_wxBitmapButton","_wxBitmapButton",0},
+ { "_class_wxGDIImage","_wxGDIImage",0},
{ "_class_wxPaletteChangedEvent","_wxPaletteChangedEvent",0},
{ "_wxWindowID","_wxCoord",0},
{ "_wxWindowID","_wxPrintQuality",0},
return _resultobj;
}
+#define wxCommandEvent_SetString(_swigobj,_swigarg0) (_swigobj->SetString(_swigarg0))
+static PyObject *_wrap_wxCommandEvent_SetString(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxCommandEvent * _arg0;
+ wxString * _arg1;
+ PyObject * _argo0 = 0;
+ PyObject * _obj1 = 0;
+ char *_kwnames[] = { "self","s", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxCommandEvent_SetString",_kwnames,&_argo0,&_obj1))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxCommandEvent_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxCommandEvent_SetString. Expected _wxCommandEvent_p.");
+ return NULL;
+ }
+ }
+{
+ if (!PyString_Check(_obj1)) {
+ PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ return NULL;
+ }
+ _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
+}
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxCommandEvent_SetString(_arg0,*_arg1);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+{
+ if (_obj1)
+ delete _arg1;
+}
+ return _resultobj;
+}
+
+#define wxCommandEvent_SetExtraLong(_swigobj,_swigarg0) (_swigobj->SetExtraLong(_swigarg0))
+static PyObject *_wrap_wxCommandEvent_SetExtraLong(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxCommandEvent * _arg0;
+ long _arg1;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self","extraLong", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxCommandEvent_SetExtraLong",_kwnames,&_argo0,&_arg1))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxCommandEvent_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxCommandEvent_SetExtraLong. Expected _wxCommandEvent_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxCommandEvent_SetExtraLong(_arg0,_arg1);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ return _resultobj;
+}
+
+#define wxCommandEvent_SetInt(_swigobj,_swigarg0) (_swigobj->SetInt(_swigarg0))
+static PyObject *_wrap_wxCommandEvent_SetInt(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxCommandEvent * _arg0;
+ int _arg1;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self","i", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxCommandEvent_SetInt",_kwnames,&_argo0,&_arg1))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxCommandEvent_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxCommandEvent_SetInt. Expected _wxCommandEvent_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxCommandEvent_SetInt(_arg0,_arg1);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ return _resultobj;
+}
+
static void *SwigwxScrollEventTowxCommandEvent(void *ptr) {
wxScrollEvent *src;
wxCommandEvent *dest;
{ "wxScrollEvent_GetPosition", (PyCFunction) _wrap_wxScrollEvent_GetPosition, METH_VARARGS | METH_KEYWORDS },
{ "wxScrollEvent_GetOrientation", (PyCFunction) _wrap_wxScrollEvent_GetOrientation, METH_VARARGS | METH_KEYWORDS },
{ "new_wxScrollEvent", (PyCFunction) _wrap_new_wxScrollEvent, METH_VARARGS | METH_KEYWORDS },
+ { "wxCommandEvent_SetInt", (PyCFunction) _wrap_wxCommandEvent_SetInt, METH_VARARGS | METH_KEYWORDS },
+ { "wxCommandEvent_SetExtraLong", (PyCFunction) _wrap_wxCommandEvent_SetExtraLong, METH_VARARGS | METH_KEYWORDS },
+ { "wxCommandEvent_SetString", (PyCFunction) _wrap_wxCommandEvent_SetString, METH_VARARGS | METH_KEYWORDS },
{ "wxCommandEvent_IsSelection", (PyCFunction) _wrap_wxCommandEvent_IsSelection, METH_VARARGS | METH_KEYWORDS },
{ "wxCommandEvent_GetString", (PyCFunction) _wrap_wxCommandEvent_GetString, METH_VARARGS | METH_KEYWORDS },
{ "wxCommandEvent_GetSelection", (PyCFunction) _wrap_wxCommandEvent_GetSelection, METH_VARARGS | METH_KEYWORDS },
def IsSelection(self, *_args, **_kwargs):
val = apply(eventsc.wxCommandEvent_IsSelection,(self,) + _args, _kwargs)
return val
+ def SetString(self, *_args, **_kwargs):
+ val = apply(eventsc.wxCommandEvent_SetString,(self,) + _args, _kwargs)
+ return val
+ def SetExtraLong(self, *_args, **_kwargs):
+ val = apply(eventsc.wxCommandEvent_SetExtraLong,(self,) + _args, _kwargs)
+ return val
+ def SetInt(self, *_args, **_kwargs):
+ val = apply(eventsc.wxCommandEvent_SetInt,(self,) + _args, _kwargs)
+ return val
def __repr__(self):
return "<C wxCommandEvent instance at %s>" % (self.this,)
class wxCommandEvent(wxCommandEventPtr):
return new wxBitmap(width, height, depth);
}
- // This one won't own the reference, so Python
- // won't call the dtor, this is good for
- // toolbars and such where the parent will
- // manage the bitmap.
- wxBitmap* wxNoRefBitmap(char* name, long flags) {
- return new wxBitmap(name, flags);
- }
-
#ifdef __WXMSW__
wxBitmap* wxBitmapFromData(char* data, long type,
int width, int height, int depth = 1) {
return _resultobj;
}
-static PyObject *_wrap_wxNoRefBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- wxBitmap * _result;
- char * _arg0;
- long _arg1;
- char *_kwnames[] = { "name","flags", NULL };
- char _ptemp[128];
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"sl:wxNoRefBitmap",_kwnames,&_arg0,&_arg1))
- return NULL;
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxBitmap *)wxNoRefBitmap(_arg0,_arg1);
-
- wxPy_END_ALLOW_THREADS;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmap_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
- return _resultobj;
-}
-
static PyObject *_wrap_wxBitmapFromData(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmap * _result;
return pyobj;
}
-#define new_wxBitmap(_swigarg0,_swigarg1) (new wxBitmap(_swigarg0,_swigarg1))
-static PyObject *_wrap_new_wxBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_GetHandle(_swigobj) (_swigobj->GetHandle())
+static PyObject *_wrap_wxGDIImage_GetHandle(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxBitmap * _result;
- wxString * _arg0;
- long _arg1;
- PyObject * _obj0 = 0;
- char *_kwnames[] = { "name","type", NULL };
- char _ptemp[128];
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:new_wxBitmap",_kwnames,&_obj0,&_arg1))
- return NULL;
-{
- if (!PyString_Check(_obj0)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- _arg0 = new wxString(PyString_AsString(_obj0), PyString_Size(_obj0));
-}
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxBitmap *)new_wxBitmap(*_arg0,_arg1);
-
- wxPy_END_ALLOW_THREADS;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmap_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
-{
- if (_obj0)
- delete _arg0;
-}
- return _resultobj;
-}
-
-#define delete_wxBitmap(_swigobj) (delete _swigobj)
-static PyObject *_wrap_delete_wxBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- wxBitmap * _arg0;
+ long _result;
+ wxGDIImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxBitmap",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGDIImage_GetHandle",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxBitmap. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_GetHandle. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- delete_wxBitmap(_arg0);
+ _result = (long )wxGDIImage_GetHandle(_arg0);
wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
+} _resultobj = Py_BuildValue("l",_result);
return _resultobj;
}
-#define wxBitmap_Create(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->Create(_swigarg0,_swigarg1,_swigarg2))
-static PyObject *_wrap_wxBitmap_Create(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_SetHandle(_swigobj,_swigarg0) (_swigobj->SetHandle(_swigarg0))
+static PyObject *_wrap_wxGDIImage_SetHandle(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxBitmap * _arg0;
- int _arg1;
- int _arg2;
- int _arg3 = (int ) -1;
+ wxGDIImage * _arg0;
+ long _arg1;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","width","height","depth", NULL };
+ char *_kwnames[] = { "self","handle", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii|i:wxBitmap_Create",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:wxGDIImage_SetHandle",_kwnames,&_argo0,&_arg1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_Create. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_SetHandle. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxBitmap_Create(_arg0,_arg1,_arg2,_arg3);
+ wxGDIImage_SetHandle(_arg0,_arg1);
wxPy_END_ALLOW_THREADS;
} Py_INCREF(Py_None);
return _resultobj;
}
-#define wxBitmap_GetDepth(_swigobj) (_swigobj->GetDepth())
-static PyObject *_wrap_wxBitmap_GetDepth(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_Ok(_swigobj) (_swigobj->Ok())
+static PyObject *_wrap_wxGDIImage_Ok(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- int _result;
- wxBitmap * _arg0;
+ bool _result;
+ wxGDIImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetDepth",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGDIImage_Ok",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetDepth. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_Ok. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxBitmap_GetDepth(_arg0);
+ _result = (bool )wxGDIImage_Ok(_arg0);
wxPy_END_ALLOW_THREADS;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
-#define wxBitmap_GetHeight(_swigobj) (_swigobj->GetHeight())
-static PyObject *_wrap_wxBitmap_GetHeight(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_GetWidth(_swigobj) (_swigobj->GetWidth())
+static PyObject *_wrap_wxGDIImage_GetWidth(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
int _result;
- wxBitmap * _arg0;
+ wxGDIImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetHeight",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGDIImage_GetWidth",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetHeight. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_GetWidth. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxBitmap_GetHeight(_arg0);
+ _result = (int )wxGDIImage_GetWidth(_arg0);
wxPy_END_ALLOW_THREADS;
} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
-#define wxBitmap_GetPalette(_swigobj) (_swigobj->GetPalette())
-static PyObject *_wrap_wxBitmap_GetPalette(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_GetHeight(_swigobj) (_swigobj->GetHeight())
+static PyObject *_wrap_wxGDIImage_GetHeight(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxPalette * _result;
- wxBitmap * _arg0;
+ int _result;
+ wxGDIImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
- char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetPalette",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGDIImage_GetHeight",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetPalette. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_GetHeight. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxPalette *)wxBitmap_GetPalette(_arg0);
+ _result = (int )wxGDIImage_GetHeight(_arg0);
wxPy_END_ALLOW_THREADS;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxPalette_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
+} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
-#define wxBitmap_GetMask(_swigobj) (_swigobj->GetMask())
-static PyObject *_wrap_wxBitmap_GetMask(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_GetDepth(_swigobj) (_swigobj->GetDepth())
+static PyObject *_wrap_wxGDIImage_GetDepth(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxMask * _result;
- wxBitmap * _arg0;
+ int _result;
+ wxGDIImage * _arg0;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self", NULL };
- char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetMask",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxGDIImage_GetDepth",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetMask. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_GetDepth. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxMask *)wxBitmap_GetMask(_arg0);
+ _result = (int )wxGDIImage_GetDepth(_arg0);
wxPy_END_ALLOW_THREADS;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxMask_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
+} _resultobj = Py_BuildValue("i",_result);
return _resultobj;
}
-#define wxBitmap_GetWidth(_swigobj) (_swigobj->GetWidth())
-static PyObject *_wrap_wxBitmap_GetWidth(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_SetWidth(_swigobj,_swigarg0) (_swigobj->SetWidth(_swigarg0))
+static PyObject *_wrap_wxGDIImage_SetWidth(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- int _result;
- wxBitmap * _arg0;
+ wxGDIImage * _arg0;
+ int _arg1;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
+ char *_kwnames[] = { "self","w", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetWidth",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxGDIImage_SetWidth",_kwnames,&_argo0,&_arg1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetWidth. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_SetWidth. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxBitmap_GetWidth(_arg0);
+ wxGDIImage_SetWidth(_arg0,_arg1);
wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
return _resultobj;
}
-#define wxBitmap_LoadFile(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadFile(_swigarg0,_swigarg1))
-static PyObject *_wrap_wxBitmap_LoadFile(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_SetHeight(_swigobj,_swigarg0) (_swigobj->SetHeight(_swigarg0))
+static PyObject *_wrap_wxGDIImage_SetHeight(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- bool _result;
- wxBitmap * _arg0;
- wxString * _arg1;
- long _arg2;
+ wxGDIImage * _arg0;
+ int _arg1;
PyObject * _argo0 = 0;
- PyObject * _obj1 = 0;
- char *_kwnames[] = { "self","name","flags", NULL };
+ char *_kwnames[] = { "self","h", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOl:wxBitmap_LoadFile",_kwnames,&_argo0,&_obj1,&_arg2))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxGDIImage_SetHeight",_kwnames,&_argo0,&_arg1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_LoadFile. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_SetHeight. Expected _wxGDIImage_p.");
return NULL;
}
}
-{
- if (!PyString_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
-}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxBitmap_LoadFile(_arg0,*_arg1,_arg2);
+ wxGDIImage_SetHeight(_arg0,_arg1);
wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
-{
- if (_obj1)
- delete _arg1;
-}
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
return _resultobj;
}
-#define wxBitmap_Ok(_swigobj) (_swigobj->Ok())
-static PyObject *_wrap_wxBitmap_Ok(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_SetDepth(_swigobj,_swigarg0) (_swigobj->SetDepth(_swigarg0))
+static PyObject *_wrap_wxGDIImage_SetDepth(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- bool _result;
- wxBitmap * _arg0;
+ wxGDIImage * _arg0;
+ int _arg1;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
+ char *_kwnames[] = { "self","d", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_Ok",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxGDIImage_SetDepth",_kwnames,&_argo0,&_arg1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_Ok. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_SetDepth. Expected _wxGDIImage_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxBitmap_Ok(_arg0);
+ wxGDIImage_SetDepth(_arg0,_arg1);
wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
return _resultobj;
}
-#define wxBitmap_SaveFile(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->SaveFile(_swigarg0,_swigarg1,_swigarg2))
-static PyObject *_wrap_wxBitmap_SaveFile(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxGDIImage_SetSize(_swigobj,_swigarg0) (_swigobj->SetSize(_swigarg0))
+static PyObject *_wrap_wxGDIImage_SetSize(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- bool _result;
- wxBitmap * _arg0;
- wxString * _arg1;
- int _arg2;
- wxPalette * _arg3 = (wxPalette *) NULL;
+ wxGDIImage * _arg0;
+ wxSize * _arg1;
PyObject * _argo0 = 0;
+ wxSize temp;
PyObject * _obj1 = 0;
- PyObject * _argo3 = 0;
- char *_kwnames[] = { "self","name","type","palette", NULL };
+ char *_kwnames[] = { "self","size", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOi|O:wxBitmap_SaveFile",_kwnames,&_argo0,&_obj1,&_arg2,&_argo3))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxGDIImage_SetSize",_kwnames,&_argo0,&_obj1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SaveFile. Expected _wxBitmap_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxGDIImage_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxGDIImage_SetSize. Expected _wxGDIImage_p.");
return NULL;
}
}
{
- if (!PyString_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
- return NULL;
- }
- _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
-}
- if (_argo3) {
- if (_argo3 == Py_None) { _arg3 = NULL; }
- else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxPalette_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxBitmap_SaveFile. Expected _wxPalette_p.");
+ _arg1 = &temp;
+ if (! wxSize_helper(_obj1, &_arg1))
return NULL;
- }
- }
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxBitmap_SaveFile(_arg0,*_arg1,_arg2,_arg3);
-
- wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
-{
- if (_obj1)
- delete _arg1;
}
- return _resultobj;
-}
-
-#define wxBitmap_SetDepth(_swigobj,_swigarg0) (_swigobj->SetDepth(_swigarg0))
-static PyObject *_wrap_wxBitmap_SetDepth(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- wxBitmap * _arg0;
- int _arg1;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","depth", NULL };
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxBitmap_SetDepth",_kwnames,&_argo0,&_arg1))
- return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetDepth. Expected _wxBitmap_p.");
- return NULL;
- }
- }
{
wxPy_BEGIN_ALLOW_THREADS;
- wxBitmap_SetDepth(_arg0,_arg1);
+ wxGDIImage_SetSize(_arg0,*_arg1);
wxPy_END_ALLOW_THREADS;
} Py_INCREF(Py_None);
return _resultobj;
}
-#define wxBitmap_SetHeight(_swigobj,_swigarg0) (_swigobj->SetHeight(_swigarg0))
-static PyObject *_wrap_wxBitmap_SetHeight(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- wxBitmap * _arg0;
- int _arg1;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","height", NULL };
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxBitmap_SetHeight",_kwnames,&_argo0,&_arg1))
- return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetHeight. Expected _wxBitmap_p.");
- return NULL;
- }
- }
-{
- wxPy_BEGIN_ALLOW_THREADS;
- wxBitmap_SetHeight(_arg0,_arg1);
-
- wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
- return _resultobj;
+static void *SwigwxBitmapTowxGDIImage(void *ptr) {
+ wxBitmap *src;
+ wxGDIImage *dest;
+ src = (wxBitmap *) ptr;
+ dest = (wxGDIImage *) src;
+ return (void *) dest;
}
-#define wxBitmap_SetMask(_swigobj,_swigarg0) (_swigobj->SetMask(_swigarg0))
-static PyObject *_wrap_wxBitmap_SetMask(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define new_wxBitmap(_swigarg0,_swigarg1) (new wxBitmap(_swigarg0,_swigarg1))
+static PyObject *_wrap_new_wxBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxBitmap * _arg0;
- wxMask * _arg1;
- PyObject * _argo0 = 0;
- PyObject * _argo1 = 0;
- char *_kwnames[] = { "self","mask", NULL };
+ wxBitmap * _result;
+ wxString * _arg0;
+ long _arg1;
+ PyObject * _obj0 = 0;
+ char *_kwnames[] = { "name","type", NULL };
+ char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmap_SetMask",_kwnames,&_argo0,&_argo1))
- return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetMask. Expected _wxBitmap_p.");
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol:new_wxBitmap",_kwnames,&_obj0,&_arg1))
return NULL;
- }
- }
- if (_argo1) {
- if (_argo1 == Py_None) { _arg1 = NULL; }
- else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxMask_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxBitmap_SetMask. Expected _wxMask_p.");
+{
+ if (!PyString_Check(_obj0)) {
+ PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
return NULL;
- }
}
+ _arg0 = new wxString(PyString_AsString(_obj0), PyString_Size(_obj0));
+}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxBitmap_SetMask(_arg0,_arg1);
+ _result = (wxBitmap *)new_wxBitmap(*_arg0,_arg1);
wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmap_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
+{
+ if (_obj0)
+ delete _arg0;
+}
return _resultobj;
}
-#define wxBitmap_SetPalette(_swigobj,_swigarg0) (_swigobj->SetPalette(_swigarg0))
-static PyObject *_wrap_wxBitmap_SetPalette(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define delete_wxBitmap(_swigobj) (delete _swigobj)
+static PyObject *_wrap_delete_wxBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxBitmap * _arg0;
- wxPalette * _arg1;
PyObject * _argo0 = 0;
- PyObject * _argo1 = 0;
- char *_kwnames[] = { "self","palette", NULL };
+ char *_kwnames[] = { "self", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmap_SetPalette",_kwnames,&_argo0,&_argo1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxBitmap",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetPalette. Expected _wxBitmap_p.");
- return NULL;
- }
- }
- if (_argo1) {
- if (_argo1 == Py_None) { _arg1 = NULL; }
- else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxPalette_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxBitmap_SetPalette. Expected _wxPalette_p.");
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxBitmap. Expected _wxBitmap_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxBitmap_SetPalette(_arg0,*_arg1);
+ delete_wxBitmap(_arg0);
wxPy_END_ALLOW_THREADS;
} Py_INCREF(Py_None);
return _resultobj;
}
-#define wxBitmap_SetWidth(_swigobj,_swigarg0) (_swigobj->SetWidth(_swigarg0))
-static PyObject *_wrap_wxBitmap_SetWidth(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxBitmap_GetPalette(_swigobj) (_swigobj->GetPalette())
+static PyObject *_wrap_wxBitmap_GetPalette(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
+ wxPalette * _result;
wxBitmap * _arg0;
- int _arg1;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","width", NULL };
+ char *_kwnames[] = { "self", NULL };
+ char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxBitmap_SetWidth",_kwnames,&_argo0,&_arg1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetPalette",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetWidth. Expected _wxBitmap_p.");
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetPalette. Expected _wxBitmap_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxBitmap_SetWidth(_arg0,_arg1);
+ _result = (wxPalette *)wxBitmap_GetPalette(_arg0);
wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxPalette_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
return _resultobj;
}
-#define new_wxMask(_swigarg0) (new wxMask(_swigarg0))
-static PyObject *_wrap_new_wxMask(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxBitmap_GetMask(_swigobj) (_swigobj->GetMask())
+static PyObject *_wrap_wxBitmap_GetMask(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxMask * _result;
wxBitmap * _arg0;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "bitmap", NULL };
+ char *_kwnames[] = { "self", NULL };
char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:new_wxMask",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxBitmap_GetMask",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of new_wxMask. Expected _wxBitmap_p.");
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_GetMask. Expected _wxBitmap_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxMask *)new_wxMask(*_arg0);
+ _result = (wxMask *)wxBitmap_GetMask(_arg0);
wxPy_END_ALLOW_THREADS;
} if (_result) {
return _resultobj;
}
-static void *SwigwxIconTowxBitmap(void *ptr) {
- wxIcon *src;
- wxBitmap *dest;
- src = (wxIcon *) ptr;
- dest = (wxBitmap *) src;
- return (void *) dest;
-}
-
-#define new_wxIcon(_swigarg0,_swigarg1,_swigarg2,_swigarg3) (new wxIcon(_swigarg0,_swigarg1,_swigarg2,_swigarg3))
-static PyObject *_wrap_new_wxIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxBitmap_LoadFile(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadFile(_swigarg0,_swigarg1))
+static PyObject *_wrap_wxBitmap_LoadFile(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxIcon * _result;
- wxString * _arg0;
- long _arg1;
- int _arg2 = (int ) -1;
- int _arg3 = (int ) -1;
- PyObject * _obj0 = 0;
- char *_kwnames[] = { "name","flags","desiredWidth","desiredHeight", NULL };
- char _ptemp[128];
+ bool _result;
+ wxBitmap * _arg0;
+ wxString * _arg1;
+ long _arg2;
+ PyObject * _argo0 = 0;
+ PyObject * _obj1 = 0;
+ char *_kwnames[] = { "self","name","flags", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol|ii:new_wxIcon",_kwnames,&_obj0,&_arg1,&_arg2,&_arg3))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOl:wxBitmap_LoadFile",_kwnames,&_argo0,&_obj1,&_arg2))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_LoadFile. Expected _wxBitmap_p.");
return NULL;
+ }
+ }
{
- if (!PyString_Check(_obj0)) {
+ if (!PyString_Check(_obj1)) {
PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
return NULL;
}
- _arg0 = new wxString(PyString_AsString(_obj0), PyString_Size(_obj0));
+ _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxIcon *)new_wxIcon(*_arg0,_arg1,_arg2,_arg3);
+ _result = (bool )wxBitmap_LoadFile(_arg0,*_arg1,_arg2);
wxPy_END_ALLOW_THREADS;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxIcon_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
+} _resultobj = Py_BuildValue("i",_result);
{
- if (_obj0)
- delete _arg0;
+ if (_obj1)
+ delete _arg1;
}
return _resultobj;
}
-#define delete_wxIcon(_swigobj) (delete _swigobj)
-static PyObject *_wrap_delete_wxIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxBitmap_SaveFile(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->SaveFile(_swigarg0,_swigarg1,_swigarg2))
+static PyObject *_wrap_wxBitmap_SaveFile(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxIcon * _arg0;
+ bool _result;
+ wxBitmap * _arg0;
+ wxString * _arg1;
+ int _arg2;
+ wxPalette * _arg3 = (wxPalette *) NULL;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
+ PyObject * _obj1 = 0;
+ PyObject * _argo3 = 0;
+ char *_kwnames[] = { "self","name","type","palette", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxIcon",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOi|O:wxBitmap_SaveFile",_kwnames,&_argo0,&_obj1,&_arg2,&_argo3))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxIcon. Expected _wxIcon_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SaveFile. Expected _wxBitmap_p.");
return NULL;
}
}
{
- wxPy_BEGIN_ALLOW_THREADS;
- delete_wxIcon(_arg0);
-
- wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
- return _resultobj;
-}
-
-#define wxIcon_GetDepth(_swigobj) (_swigobj->GetDepth())
-static PyObject *_wrap_wxIcon_GetDepth(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- int _result;
- wxIcon * _arg0;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxIcon_GetDepth",_kwnames,&_argo0))
+ if (!PyString_Check(_obj1)) {
+ PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_GetDepth. Expected _wxIcon_p.");
+ }
+ _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
+}
+ if (_argo3) {
+ if (_argo3 == Py_None) { _arg3 = NULL; }
+ else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxPalette_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxBitmap_SaveFile. Expected _wxPalette_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxIcon_GetDepth(_arg0);
+ _result = (bool )wxBitmap_SaveFile(_arg0,*_arg1,_arg2,_arg3);
wxPy_END_ALLOW_THREADS;
} _resultobj = Py_BuildValue("i",_result);
+{
+ if (_obj1)
+ delete _arg1;
+}
return _resultobj;
}
-#define wxIcon_GetHeight(_swigobj) (_swigobj->GetHeight())
-static PyObject *_wrap_wxIcon_GetHeight(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxBitmap_SetMask(_swigobj,_swigarg0) (_swigobj->SetMask(_swigarg0))
+static PyObject *_wrap_wxBitmap_SetMask(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- int _result;
- wxIcon * _arg0;
+ wxBitmap * _arg0;
+ wxMask * _arg1;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
+ PyObject * _argo1 = 0;
+ char *_kwnames[] = { "self","mask", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxIcon_GetHeight",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmap_SetMask",_kwnames,&_argo0,&_argo1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_GetHeight. Expected _wxIcon_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetMask. Expected _wxBitmap_p.");
return NULL;
}
}
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxIcon_GetHeight(_arg0);
-
- wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
- return _resultobj;
-}
-
-#define wxIcon_GetWidth(_swigobj) (_swigobj->GetWidth())
-static PyObject *_wrap_wxIcon_GetWidth(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- int _result;
- wxIcon * _arg0;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxIcon_GetWidth",_kwnames,&_argo0))
- return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_GetWidth. Expected _wxIcon_p.");
+ if (_argo1) {
+ if (_argo1 == Py_None) { _arg1 = NULL; }
+ else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxMask_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxBitmap_SetMask. Expected _wxMask_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (int )wxIcon_GetWidth(_arg0);
+ wxBitmap_SetMask(_arg0,_arg1);
wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
return _resultobj;
}
-#define wxIcon_LoadFile(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadFile(_swigarg0,_swigarg1))
-static PyObject *_wrap_wxIcon_LoadFile(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- bool _result;
- wxIcon * _arg0;
- wxString * _arg1;
- long _arg2;
+#define wxBitmap_SetPalette(_swigobj,_swigarg0) (_swigobj->SetPalette(_swigarg0))
+static PyObject *_wrap_wxBitmap_SetPalette(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxBitmap * _arg0;
+ wxPalette * _arg1;
PyObject * _argo0 = 0;
- PyObject * _obj1 = 0;
- char *_kwnames[] = { "self","name","flags", NULL };
+ PyObject * _argo1 = 0;
+ char *_kwnames[] = { "self","palette", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOl:wxIcon_LoadFile",_kwnames,&_argo0,&_obj1,&_arg2))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxBitmap_SetPalette",_kwnames,&_argo0,&_argo1))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_LoadFile. Expected _wxIcon_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxBitmap_SetPalette. Expected _wxBitmap_p.");
return NULL;
}
}
-{
- if (!PyString_Check(_obj1)) {
- PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ if (_argo1) {
+ if (_argo1 == Py_None) { _arg1 = NULL; }
+ else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxPalette_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxBitmap_SetPalette. Expected _wxPalette_p.");
return NULL;
+ }
}
- _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
-}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxIcon_LoadFile(_arg0,*_arg1,_arg2);
+ wxBitmap_SetPalette(_arg0,*_arg1);
wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
-{
- if (_obj1)
- delete _arg1;
-}
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
return _resultobj;
}
-#define wxIcon_Ok(_swigobj) (_swigobj->Ok())
-static PyObject *_wrap_wxIcon_Ok(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define new_wxMask(_swigarg0) (new wxMask(_swigarg0))
+static PyObject *_wrap_new_wxMask(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- bool _result;
- wxIcon * _arg0;
+ wxMask * _result;
+ wxBitmap * _arg0;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
+ char *_kwnames[] = { "bitmap", NULL };
+ char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxIcon_Ok",_kwnames,&_argo0))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:new_wxMask",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_Ok. Expected _wxIcon_p.");
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxBitmap_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of new_wxMask. Expected _wxBitmap_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxIcon_Ok(_arg0);
+ _result = (wxMask *)new_wxMask(*_arg0);
wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxMask_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
return _resultobj;
}
-#define wxIcon_SetDepth(_swigobj,_swigarg0) (_swigobj->SetDepth(_swigarg0))
-static PyObject *_wrap_wxIcon_SetDepth(PyObject *self, PyObject *args, PyObject *kwargs) {
+static void *SwigwxIconTowxGDIImage(void *ptr) {
+ wxIcon *src;
+ wxGDIImage *dest;
+ src = (wxIcon *) ptr;
+ dest = (wxGDIImage *) src;
+ return (void *) dest;
+}
+
+#define new_wxIcon(_swigarg0,_swigarg1,_swigarg2,_swigarg3) (new wxIcon(_swigarg0,_swigarg1,_swigarg2,_swigarg3))
+static PyObject *_wrap_new_wxIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
- wxIcon * _arg0;
- int _arg1;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","depth", NULL };
+ wxIcon * _result;
+ wxString * _arg0;
+ long _arg1;
+ int _arg2 = (int ) -1;
+ int _arg3 = (int ) -1;
+ PyObject * _obj0 = 0;
+ char *_kwnames[] = { "name","flags","desiredWidth","desiredHeight", NULL };
+ char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxIcon_SetDepth",_kwnames,&_argo0,&_arg1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Ol|ii:new_wxIcon",_kwnames,&_obj0,&_arg1,&_arg2,&_arg3))
return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_SetDepth. Expected _wxIcon_p.");
+{
+ if (!PyString_Check(_obj0)) {
+ PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
return NULL;
- }
}
+ _arg0 = new wxString(PyString_AsString(_obj0), PyString_Size(_obj0));
+}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxIcon_SetDepth(_arg0,_arg1);
+ _result = (wxIcon *)new_wxIcon(*_arg0,_arg1,_arg2,_arg3);
wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxIcon_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
+{
+ if (_obj0)
+ delete _arg0;
+}
return _resultobj;
}
-#define wxIcon_SetHeight(_swigobj,_swigarg0) (_swigobj->SetHeight(_swigarg0))
-static PyObject *_wrap_wxIcon_SetHeight(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define delete_wxIcon(_swigobj) (delete _swigobj)
+static PyObject *_wrap_delete_wxIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxIcon * _arg0;
- int _arg1;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","height", NULL };
+ char *_kwnames[] = { "self", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxIcon_SetHeight",_kwnames,&_argo0,&_arg1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxIcon",_kwnames,&_argo0))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_SetHeight. Expected _wxIcon_p.");
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxIcon. Expected _wxIcon_p.");
return NULL;
}
}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxIcon_SetHeight(_arg0,_arg1);
+ delete_wxIcon(_arg0);
wxPy_END_ALLOW_THREADS;
} Py_INCREF(Py_None);
return _resultobj;
}
-#define wxIcon_SetWidth(_swigobj,_swigarg0) (_swigobj->SetWidth(_swigarg0))
-static PyObject *_wrap_wxIcon_SetWidth(PyObject *self, PyObject *args, PyObject *kwargs) {
+#define wxIcon_LoadFile(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadFile(_swigarg0,_swigarg1))
+static PyObject *_wrap_wxIcon_LoadFile(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
+ bool _result;
wxIcon * _arg0;
- int _arg1;
+ wxString * _arg1;
+ long _arg2;
PyObject * _argo0 = 0;
- char *_kwnames[] = { "self","width", NULL };
+ PyObject * _obj1 = 0;
+ char *_kwnames[] = { "self","name","flags", NULL };
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi:wxIcon_SetWidth",_kwnames,&_argo0,&_arg1))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOl:wxIcon_LoadFile",_kwnames,&_argo0,&_obj1,&_arg2))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxIcon_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_SetWidth. Expected _wxIcon_p.");
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxIcon_LoadFile. Expected _wxIcon_p.");
return NULL;
}
}
+{
+ if (!PyString_Check(_obj1)) {
+ PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ return NULL;
+ }
+ _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
+}
{
wxPy_BEGIN_ALLOW_THREADS;
- wxIcon_SetWidth(_arg0,_arg1);
+ _result = (bool )wxIcon_LoadFile(_arg0,*_arg1,_arg2);
wxPy_END_ALLOW_THREADS;
-} Py_INCREF(Py_None);
- _resultobj = Py_None;
+} _resultobj = Py_BuildValue("i",_result);
+{
+ if (_obj1)
+ delete _arg1;
+}
return _resultobj;
}
-static void *SwigwxCursorTowxBitmap(void *ptr) {
+static void *SwigwxCursorTowxGDIImage(void *ptr) {
wxCursor *src;
- wxBitmap *dest;
+ wxGDIImage *dest;
src = (wxCursor *) ptr;
- dest = (wxBitmap *) src;
+ dest = (wxGDIImage *) src;
return (void *) dest;
}
return _resultobj;
}
-#define wxCursor_Ok(_swigobj) (_swigobj->Ok())
-static PyObject *_wrap_wxCursor_Ok(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- bool _result;
- wxCursor * _arg0;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxCursor_Ok",_kwnames,&_argo0))
- return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxCursor_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxCursor_Ok. Expected _wxCursor_p.");
- return NULL;
- }
- }
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (bool )wxCursor_Ok(_arg0);
-
- wxPy_END_ALLOW_THREADS;
-} _resultobj = Py_BuildValue("i",_result);
- return _resultobj;
-}
-
static wxFont *new_wxFont(int pointSize,int family,int style,int weight,int underline,char *faceName,wxFontEncoding encoding) {
return wxTheFontList->FindOrCreateFont(pointSize, family, style, weight,
return _resultobj;
}
-#define wxPen_GetStipple(_swigobj) (_swigobj->GetStipple())
-static PyObject *_wrap_wxPen_GetStipple(PyObject *self, PyObject *args, PyObject *kwargs) {
- PyObject * _resultobj;
- wxBitmap * _result;
- wxPen * _arg0;
- PyObject * _argo0 = 0;
- char *_kwnames[] = { "self", NULL };
- char _ptemp[128];
-
- self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPen_GetStipple",_kwnames,&_argo0))
- return NULL;
- if (_argo0) {
- if (_argo0 == Py_None) { _arg0 = NULL; }
- else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPen_p")) {
- PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPen_GetStipple. Expected _wxPen_p.");
- return NULL;
- }
- }
-{
- wxPy_BEGIN_ALLOW_THREADS;
- _result = (wxBitmap *)wxPen_GetStipple(_arg0);
-
- wxPy_END_ALLOW_THREADS;
-} if (_result) {
- SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmap_p");
- _resultobj = Py_BuildValue("s",_ptemp);
- } else {
- Py_INCREF(Py_None);
- _resultobj = Py_None;
- }
- return _resultobj;
-}
-
#define wxPen_SetDashes(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetDashes(_swigarg0,_swigarg1))
static PyObject *_wrap_wxPen_SetDashes(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
return _resultobj;
}
+#define wxPen_GetStipple(_swigobj) (_swigobj->GetStipple())
+static PyObject *_wrap_wxPen_GetStipple(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxBitmap * _result;
+ wxPen * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+ char _ptemp[128];
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxPen_GetStipple",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxPen_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxPen_GetStipple. Expected _wxPen_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (wxBitmap *)wxPen_GetStipple(_arg0);
+
+ wxPy_END_ALLOW_THREADS;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxBitmap_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
+ return _resultobj;
+}
+
#define wxPen_SetStipple(_swigobj,_swigarg0) (_swigobj->SetStipple(_swigarg0))
static PyObject *_wrap_wxPen_SetStipple(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
return _resultobj;
}
+#define wxDC_DrawRotatedText(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3) (_swigobj->DrawRotatedText(_swigarg0,_swigarg1,_swigarg2,_swigarg3))
+static PyObject *_wrap_wxDC_DrawRotatedText(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxDC * _arg0;
+ wxString * _arg1;
+ wxCoord _arg2;
+ wxCoord _arg3;
+ double _arg4;
+ PyObject * _argo0 = 0;
+ PyObject * _obj1 = 0;
+ char *_kwnames[] = { "self","text","x","y","angle", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOiid:wxDC_DrawRotatedText",_kwnames,&_argo0,&_obj1,&_arg2,&_arg3,&_arg4))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxDC_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxDC_DrawRotatedText. Expected _wxDC_p.");
+ return NULL;
+ }
+ }
+{
+ if (!PyString_Check(_obj1)) {
+ PyErr_SetString(PyExc_TypeError, wxStringErrorMsg);
+ return NULL;
+ }
+ _arg1 = new wxString(PyString_AsString(_obj1), PyString_Size(_obj1));
+}
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxDC_DrawRotatedText(_arg0,*_arg1,_arg2,_arg3,_arg4);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+{
+ if (_obj1)
+ delete _arg1;
+}
+ return _resultobj;
+}
+
#define wxDC_DrawRoundedRectangle(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4) (_swigobj->DrawRoundedRectangle(_swigarg0,_swigarg1,_swigarg2,_swigarg3,_swigarg4))
static PyObject *_wrap_wxDC_DrawRoundedRectangle(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
wxImageList * _result;
int _arg0;
int _arg1;
- bool _arg2 = (bool ) TRUE;
+ int _arg2 = (int ) TRUE;
int _arg3 = (int ) 1;
- int tempbool2 = (int) TRUE;
char *_kwnames[] = { "width","height","mask","initialCount", NULL };
char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"ii|ii:new_wxImageList",_kwnames,&_arg0,&_arg1,&tempbool2,&_arg3))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"ii|ii:new_wxImageList",_kwnames,&_arg0,&_arg1,&_arg2,&_arg3))
return NULL;
- _arg2 = (bool ) tempbool2;
{
wxPy_BEGIN_ALLOW_THREADS;
_result = (wxImageList *)new_wxImageList(_arg0,_arg1,_arg2,_arg3);
{ "wxDC_DrawText", (PyCFunction) _wrap_wxDC_DrawText, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_DrawSpline", (PyCFunction) _wrap_wxDC_DrawSpline, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_DrawRoundedRectangle", (PyCFunction) _wrap_wxDC_DrawRoundedRectangle, METH_VARARGS | METH_KEYWORDS },
+ { "wxDC_DrawRotatedText", (PyCFunction) _wrap_wxDC_DrawRotatedText, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_DrawRectangle", (PyCFunction) _wrap_wxDC_DrawRectangle, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_DrawPoint", (PyCFunction) _wrap_wxDC_DrawPoint, METH_VARARGS | METH_KEYWORDS },
{ "wxDC_DrawPolygon", (PyCFunction) _wrap_wxDC_DrawPolygon, METH_VARARGS | METH_KEYWORDS },
{ "wxBrush_GetColour", (PyCFunction) _wrap_wxBrush_GetColour, METH_VARARGS | METH_KEYWORDS },
{ "new_wxBrush", (PyCFunction) _wrap_new_wxBrush, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetStipple", (PyCFunction) _wrap_wxPen_SetStipple, METH_VARARGS | METH_KEYWORDS },
- { "wxPen_SetDashes", (PyCFunction) _wrap_wxPen_SetDashes, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_GetStipple", (PyCFunction) _wrap_wxPen_GetStipple, METH_VARARGS | METH_KEYWORDS },
+ { "wxPen_SetDashes", (PyCFunction) _wrap_wxPen_SetDashes, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_GetDashes", (PyCFunction) _wrap_wxPen_GetDashes, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetWidth", (PyCFunction) _wrap_wxPen_SetWidth, METH_VARARGS | METH_KEYWORDS },
{ "wxPen_SetStyle", (PyCFunction) _wrap_wxPen_SetStyle, METH_VARARGS | METH_KEYWORDS },
{ "wxFont_GetFaceName", (PyCFunction) _wrap_wxFont_GetFaceName, METH_VARARGS | METH_KEYWORDS },
{ "wxFont_Ok", (PyCFunction) _wrap_wxFont_Ok, METH_VARARGS | METH_KEYWORDS },
{ "new_wxFont", (PyCFunction) _wrap_new_wxFont, METH_VARARGS | METH_KEYWORDS },
- { "wxCursor_Ok", (PyCFunction) _wrap_wxCursor_Ok, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxCursor", (PyCFunction) _wrap_delete_wxCursor, METH_VARARGS | METH_KEYWORDS },
{ "new_wxCursor", (PyCFunction) _wrap_new_wxCursor, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_SetWidth", (PyCFunction) _wrap_wxIcon_SetWidth, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_SetHeight", (PyCFunction) _wrap_wxIcon_SetHeight, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_SetDepth", (PyCFunction) _wrap_wxIcon_SetDepth, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_Ok", (PyCFunction) _wrap_wxIcon_Ok, METH_VARARGS | METH_KEYWORDS },
{ "wxIcon_LoadFile", (PyCFunction) _wrap_wxIcon_LoadFile, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_GetWidth", (PyCFunction) _wrap_wxIcon_GetWidth, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_GetHeight", (PyCFunction) _wrap_wxIcon_GetHeight, METH_VARARGS | METH_KEYWORDS },
- { "wxIcon_GetDepth", (PyCFunction) _wrap_wxIcon_GetDepth, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxIcon", (PyCFunction) _wrap_delete_wxIcon, METH_VARARGS | METH_KEYWORDS },
{ "new_wxIcon", (PyCFunction) _wrap_new_wxIcon, METH_VARARGS | METH_KEYWORDS },
{ "new_wxMask", (PyCFunction) _wrap_new_wxMask, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_SetWidth", (PyCFunction) _wrap_wxBitmap_SetWidth, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_SetPalette", (PyCFunction) _wrap_wxBitmap_SetPalette, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_SetMask", (PyCFunction) _wrap_wxBitmap_SetMask, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_SetHeight", (PyCFunction) _wrap_wxBitmap_SetHeight, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_SetDepth", (PyCFunction) _wrap_wxBitmap_SetDepth, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_SaveFile", (PyCFunction) _wrap_wxBitmap_SaveFile, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_Ok", (PyCFunction) _wrap_wxBitmap_Ok, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_LoadFile", (PyCFunction) _wrap_wxBitmap_LoadFile, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_GetWidth", (PyCFunction) _wrap_wxBitmap_GetWidth, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_GetMask", (PyCFunction) _wrap_wxBitmap_GetMask, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmap_GetPalette", (PyCFunction) _wrap_wxBitmap_GetPalette, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_GetHeight", (PyCFunction) _wrap_wxBitmap_GetHeight, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_GetDepth", (PyCFunction) _wrap_wxBitmap_GetDepth, METH_VARARGS | METH_KEYWORDS },
- { "wxBitmap_Create", (PyCFunction) _wrap_wxBitmap_Create, METH_VARARGS | METH_KEYWORDS },
{ "delete_wxBitmap", (PyCFunction) _wrap_delete_wxBitmap, METH_VARARGS | METH_KEYWORDS },
{ "new_wxBitmap", (PyCFunction) _wrap_new_wxBitmap, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_SetSize", (PyCFunction) _wrap_wxGDIImage_SetSize, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_SetDepth", (PyCFunction) _wrap_wxGDIImage_SetDepth, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_SetHeight", (PyCFunction) _wrap_wxGDIImage_SetHeight, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_SetWidth", (PyCFunction) _wrap_wxGDIImage_SetWidth, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_GetDepth", (PyCFunction) _wrap_wxGDIImage_GetDepth, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_GetHeight", (PyCFunction) _wrap_wxGDIImage_GetHeight, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_GetWidth", (PyCFunction) _wrap_wxGDIImage_GetWidth, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_Ok", (PyCFunction) _wrap_wxGDIImage_Ok, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_SetHandle", (PyCFunction) _wrap_wxGDIImage_SetHandle, METH_VARARGS | METH_KEYWORDS },
+ { "wxGDIImage_GetHandle", (PyCFunction) _wrap_wxGDIImage_GetHandle, METH_VARARGS | METH_KEYWORDS },
{ "wxMemoryDCFromDC", (PyCFunction) _wrap_wxMemoryDCFromDC, METH_VARARGS | METH_KEYWORDS },
{ "wxNamedColour", (PyCFunction) _wrap_wxNamedColour, METH_VARARGS | METH_KEYWORDS },
{ "wxFont_SetDefaultEncoding", (PyCFunction) _wrap_wxFont_SetDefaultEncoding, METH_VARARGS | METH_KEYWORDS },
{ "wxStockCursor", (PyCFunction) _wrap_wxStockCursor, METH_VARARGS | METH_KEYWORDS },
{ "wxMaskColour", (PyCFunction) _wrap_wxMaskColour, METH_VARARGS | METH_KEYWORDS },
{ "wxBitmapFromData", (PyCFunction) _wrap_wxBitmapFromData, METH_VARARGS | METH_KEYWORDS },
- { "wxNoRefBitmap", (PyCFunction) _wrap_wxNoRefBitmap, METH_VARARGS | METH_KEYWORDS },
{ "wxEmptyBitmap", (PyCFunction) _wrap_wxEmptyBitmap, METH_VARARGS | METH_KEYWORDS },
{ NULL, NULL }
};
{ "_uint","_wxWindowID",0},
{ "_wxRect","_class_wxRect",0},
{ "_wxPoint","_class_wxPoint",0},
- { "_wxBitmap","_class_wxCursor",SwigwxCursorTowxBitmap},
- { "_wxBitmap","_wxCursor",SwigwxCursorTowxBitmap},
- { "_wxBitmap","_class_wxIcon",SwigwxIconTowxBitmap},
- { "_wxBitmap","_wxIcon",SwigwxIconTowxBitmap},
{ "_wxBitmap","_class_wxBitmap",0},
{ "_wxPyTimer","_class_wxPyTimer",0},
{ "_wxWindowDC","_class_wxWindowDC",0},
{ "_EBool","_int",0},
{ "_EBool","_wxWindowID",0},
{ "_class_wxRegion","_wxRegion",0},
+ { "_wxGDIImage","_class_wxCursor",SwigwxCursorTowxGDIImage},
+ { "_wxGDIImage","_wxCursor",SwigwxCursorTowxGDIImage},
+ { "_wxGDIImage","_class_wxIcon",SwigwxIconTowxGDIImage},
+ { "_wxGDIImage","_wxIcon",SwigwxIconTowxGDIImage},
+ { "_wxGDIImage","_class_wxBitmap",SwigwxBitmapTowxGDIImage},
+ { "_wxGDIImage","_wxBitmap",SwigwxBitmapTowxGDIImage},
+ { "_wxGDIImage","_class_wxGDIImage",0},
{ "_wxFont","_class_wxFont",0},
{ "_unsigned_long","_wxDash",0},
{ "_unsigned_long","_long",0},
{ "_short","_unsigned_short",0},
{ "_short","_signed_short",0},
{ "_class_wxImageList","_wxImageList",0},
+ { "_class_wxGDIImage","_class_wxCursor",SwigwxCursorTowxGDIImage},
+ { "_class_wxGDIImage","_wxCursor",SwigwxCursorTowxGDIImage},
+ { "_class_wxGDIImage","_class_wxIcon",SwigwxIconTowxGDIImage},
+ { "_class_wxGDIImage","_wxIcon",SwigwxIconTowxGDIImage},
+ { "_class_wxGDIImage","_class_wxBitmap",SwigwxBitmapTowxGDIImage},
+ { "_class_wxGDIImage","_wxBitmap",SwigwxBitmapTowxGDIImage},
+ { "_class_wxGDIImage","_wxGDIImage",0},
{ "_wxWindowID","_wxCoord",0},
{ "_wxWindowID","_wxPrintQuality",0},
{ "_wxWindowID","_size_t",0},
{ "_class_wxBusyInfo","_wxBusyInfo",0},
{ "_class_wxClientDC","_wxClientDC",0},
{ "_class_wxSize","_wxSize",0},
- { "_class_wxBitmap","_class_wxCursor",SwigwxCursorTowxBitmap},
- { "_class_wxBitmap","_wxCursor",SwigwxCursorTowxBitmap},
- { "_class_wxBitmap","_class_wxIcon",SwigwxIconTowxBitmap},
- { "_class_wxBitmap","_wxIcon",SwigwxIconTowxBitmap},
{ "_class_wxBitmap","_wxBitmap",0},
{ "_class_wxMemoryDC","_wxMemoryDC",0},
{ "_wxDash","_unsigned_long",0},
import gdic
from misc import *
-class wxBitmapPtr :
+class wxGDIImagePtr :
def __init__(self,this):
self.this = this
self.thisown = 0
- def __del__(self,gdic=gdic):
- if self.thisown == 1 :
- gdic.delete_wxBitmap(self)
- def Create(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_Create,(self,) + _args, _kwargs)
+ def GetHandle(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_GetHandle,(self,) + _args, _kwargs)
return val
- def GetDepth(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_GetDepth,(self,) + _args, _kwargs)
+ def SetHandle(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_SetHandle,(self,) + _args, _kwargs)
+ return val
+ def Ok(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_Ok,(self,) + _args, _kwargs)
+ return val
+ def GetWidth(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_GetWidth,(self,) + _args, _kwargs)
return val
def GetHeight(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_GetHeight,(self,) + _args, _kwargs)
+ val = apply(gdic.wxGDIImage_GetHeight,(self,) + _args, _kwargs)
+ return val
+ def GetDepth(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_GetDepth,(self,) + _args, _kwargs)
+ return val
+ def SetWidth(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_SetWidth,(self,) + _args, _kwargs)
+ return val
+ def SetHeight(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_SetHeight,(self,) + _args, _kwargs)
+ return val
+ def SetDepth(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_SetDepth,(self,) + _args, _kwargs)
+ return val
+ def SetSize(self, *_args, **_kwargs):
+ val = apply(gdic.wxGDIImage_SetSize,(self,) + _args, _kwargs)
return val
+ def __repr__(self):
+ return "<C wxGDIImage instance at %s>" % (self.this,)
+class wxGDIImage(wxGDIImagePtr):
+ def __init__(self,this):
+ self.this = this
+
+
+
+
+class wxBitmapPtr(wxGDIImagePtr):
+ def __init__(self,this):
+ self.this = this
+ self.thisown = 0
+ def __del__(self,gdic=gdic):
+ if self.thisown == 1 :
+ gdic.delete_wxBitmap(self)
def GetPalette(self, *_args, **_kwargs):
val = apply(gdic.wxBitmap_GetPalette,(self,) + _args, _kwargs)
if val: val = wxPalettePtr(val)
val = apply(gdic.wxBitmap_GetMask,(self,) + _args, _kwargs)
if val: val = wxMaskPtr(val)
return val
- def GetWidth(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_GetWidth,(self,) + _args, _kwargs)
- return val
def LoadFile(self, *_args, **_kwargs):
val = apply(gdic.wxBitmap_LoadFile,(self,) + _args, _kwargs)
return val
- def Ok(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_Ok,(self,) + _args, _kwargs)
- return val
def SaveFile(self, *_args, **_kwargs):
val = apply(gdic.wxBitmap_SaveFile,(self,) + _args, _kwargs)
return val
- def SetDepth(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_SetDepth,(self,) + _args, _kwargs)
- return val
- def SetHeight(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_SetHeight,(self,) + _args, _kwargs)
- return val
def SetMask(self, *_args, **_kwargs):
val = apply(gdic.wxBitmap_SetMask,(self,) + _args, _kwargs)
return val
def SetPalette(self, *_args, **_kwargs):
val = apply(gdic.wxBitmap_SetPalette,(self,) + _args, _kwargs)
return val
- def SetWidth(self, *_args, **_kwargs):
- val = apply(gdic.wxBitmap_SetWidth,(self,) + _args, _kwargs)
- return val
def __repr__(self):
return "<C wxBitmap instance at %s>" % (self.this,)
class wxBitmap(wxBitmapPtr):
-class wxIconPtr(wxBitmapPtr):
+class wxIconPtr(wxGDIImagePtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def __del__(self,gdic=gdic):
if self.thisown == 1 :
gdic.delete_wxIcon(self)
- def GetDepth(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_GetDepth,(self,) + _args, _kwargs)
- return val
- def GetHeight(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_GetHeight,(self,) + _args, _kwargs)
- return val
- def GetWidth(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_GetWidth,(self,) + _args, _kwargs)
- return val
def LoadFile(self, *_args, **_kwargs):
val = apply(gdic.wxIcon_LoadFile,(self,) + _args, _kwargs)
return val
- def Ok(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_Ok,(self,) + _args, _kwargs)
- return val
- def SetDepth(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_SetDepth,(self,) + _args, _kwargs)
- return val
- def SetHeight(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_SetHeight,(self,) + _args, _kwargs)
- return val
- def SetWidth(self, *_args, **_kwargs):
- val = apply(gdic.wxIcon_SetWidth,(self,) + _args, _kwargs)
- return val
def __repr__(self):
return "<C wxIcon instance at %s>" % (self.this,)
class wxIcon(wxIconPtr):
-class wxCursorPtr(wxBitmapPtr):
+class wxCursorPtr(wxGDIImagePtr):
def __init__(self,this):
self.this = this
self.thisown = 0
def __del__(self,gdic=gdic):
if self.thisown == 1 :
gdic.delete_wxCursor(self)
- def Ok(self, *_args, **_kwargs):
- val = apply(gdic.wxCursor_Ok,(self,) + _args, _kwargs)
- return val
def __repr__(self):
return "<C wxCursor instance at %s>" % (self.this,)
class wxCursor(wxCursorPtr):
def GetDashes(self, *_args, **_kwargs):
val = apply(gdic.wxPen_GetDashes,(self,) + _args, _kwargs)
return val
+ def SetDashes(self, *_args, **_kwargs):
+ val = apply(gdic.wxPen_SetDashes,(self,) + _args, _kwargs)
+ return val
def GetStipple(self, *_args, **_kwargs):
val = apply(gdic.wxPen_GetStipple,(self,) + _args, _kwargs)
if val: val = wxBitmapPtr(val)
return val
- def SetDashes(self, *_args, **_kwargs):
- val = apply(gdic.wxPen_SetDashes,(self,) + _args, _kwargs)
- return val
def SetStipple(self, *_args, **_kwargs):
val = apply(gdic.wxPen_SetStipple,(self,) + _args, _kwargs)
return val
def DrawRectangle(self, *_args, **_kwargs):
val = apply(gdic.wxDC_DrawRectangle,(self,) + _args, _kwargs)
return val
+ def DrawRotatedText(self, *_args, **_kwargs):
+ val = apply(gdic.wxDC_DrawRotatedText,(self,) + _args, _kwargs)
+ return val
def DrawRoundedRectangle(self, *_args, **_kwargs):
val = apply(gdic.wxDC_DrawRoundedRectangle,(self,) + _args, _kwargs)
return val
if val: val = wxBitmapPtr(val); val.thisown = 1
return val
-def wxNoRefBitmap(*_args, **_kwargs):
- val = apply(gdic.wxNoRefBitmap,_args,_kwargs)
- if val: val = wxBitmapPtr(val)
- return val
-
def wxBitmapFromData(*_args, **_kwargs):
val = apply(gdic.wxBitmapFromData,_args,_kwargs)
if val: val = wxBitmapPtr(val); val.thisown = 1
return _resultobj;
}
+#define wxToolBarTool_GetControl(_swigobj) (_swigobj->GetControl())
+static PyObject *_wrap_wxToolBarTool_GetControl(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxControl * _result;
+ wxToolBarTool * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+ char _ptemp[128];
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxToolBarTool_GetControl",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBarTool_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBarTool_GetControl. Expected _wxToolBarTool_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (wxControl *)wxToolBarTool_GetControl(_arg0);
+
+ wxPy_END_ALLOW_THREADS;
+} if (_result) {
+ SWIG_MakePtr(_ptemp, (char *) _result,"_wxControl_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ } else {
+ Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ }
+ return _resultobj;
+}
+
#define wxToolBarTool_m_toolStyle_set(_swigobj,_swigval) (_swigobj->m_toolStyle = _swigval,_swigval)
static PyObject *_wrap_wxToolBarTool_m_toolStyle_set(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
return _resultobj;
}
+#define wxToolBar_AddControl(_swigobj,_swigarg0) (_swigobj->AddControl(_swigarg0))
+static PyObject *_wrap_wxToolBar_AddControl(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ bool _result;
+ wxToolBar * _arg0;
+ wxControl * _arg1;
+ PyObject * _argo0 = 0;
+ PyObject * _argo1 = 0;
+ char *_kwnames[] = { "self","control", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxToolBar_AddControl",_kwnames,&_argo0,&_argo1))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_AddControl. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+ if (_argo1) {
+ if (_argo1 == Py_None) { _arg1 = NULL; }
+ else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxControl_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxToolBar_AddControl. Expected _wxControl_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (bool )wxToolBar_AddControl(_arg0,_arg1);
+
+ wxPy_END_ALLOW_THREADS;
+} _resultobj = Py_BuildValue("i",_result);
+ return _resultobj;
+}
+
#define wxToolBar_AddSeparator(_swigobj) (_swigobj->AddSeparator())
static PyObject *_wrap_wxToolBar_AddSeparator(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
return _resultobj;
}
+#define wxToolBar_ClearTools(_swigobj) (_swigobj->ClearTools())
+static PyObject *_wrap_wxToolBar_ClearTools(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxToolBar * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxToolBar_ClearTools",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_ClearTools. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxToolBar_ClearTools(_arg0);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ return _resultobj;
+}
+
static wxToolBarTool * wxToolBar_AddTool(wxToolBar *self,int toolIndex,const wxBitmap & bitmap1,const wxBitmap & bitmap2,int isToggle,long xPos,long yPos,const wxString & shortHelpString,const wxString & longHelpString) {
return self->AddTool(toolIndex, bitmap1, bitmap2,
isToggle, xPos, yPos, NULL,
PyObject * _resultobj;
wxToolBarTool * _result;
wxToolBar * _arg0;
- float _arg1;
- float _arg2;
+ long _arg1;
+ long _arg2;
PyObject * _argo0 = 0;
char *_kwnames[] = { "self","x","y", NULL };
char _ptemp[128];
self = self;
- if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Off:wxToolBar_FindToolForPosition",_kwnames,&_argo0,&_arg1,&_arg2))
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oll:wxToolBar_FindToolForPosition",_kwnames,&_argo0,&_arg1,&_arg2))
return NULL;
if (_argo0) {
if (_argo0 == Py_None) { _arg0 = NULL; }
return _resultobj;
}
+#define wxToolBar_GetToolMargins(_swigobj) (_swigobj->GetToolMargins())
+static PyObject *_wrap_wxToolBar_GetToolMargins(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxSize * _result;
+ wxToolBar * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+ char _ptemp[128];
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxToolBar_GetToolMargins",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_GetToolMargins. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = new wxSize (wxToolBar_GetToolMargins(_arg0));
+
+ wxPy_END_ALLOW_THREADS;
+} SWIG_MakePtr(_ptemp, (void *) _result,"_wxSize_p");
+ _resultobj = Py_BuildValue("s",_ptemp);
+ return _resultobj;
+}
+
#define wxToolBar_GetMaxSize(_swigobj) (_swigobj->GetMaxSize())
static PyObject *_wrap_wxToolBar_GetMaxSize(PyObject *self, PyObject *args, PyObject *kwargs) {
PyObject * _resultobj;
return _resultobj;
}
+#define wxToolBar_SetToggle(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetToggle(_swigarg0,_swigarg1))
+static PyObject *_wrap_wxToolBar_SetToggle(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxToolBar * _arg0;
+ int _arg1;
+ bool _arg2;
+ PyObject * _argo0 = 0;
+ int tempbool2;
+ char *_kwnames[] = { "self","toolIndex","toggle", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxToolBar_SetToggle",_kwnames,&_argo0,&_arg1,&tempbool2))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_SetToggle. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+ _arg2 = (bool ) tempbool2;
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxToolBar_SetToggle(_arg0,_arg1,_arg2);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ return _resultobj;
+}
+
+#define wxToolBar_SetMaxRowsCols(_swigobj,_swigarg0,_swigarg1) (_swigobj->SetMaxRowsCols(_swigarg0,_swigarg1))
+static PyObject *_wrap_wxToolBar_SetMaxRowsCols(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ wxToolBar * _arg0;
+ int _arg1;
+ int _arg2;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self","rows","cols", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oii:wxToolBar_SetMaxRowsCols",_kwnames,&_argo0,&_arg1,&_arg2))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_SetMaxRowsCols. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ wxToolBar_SetMaxRowsCols(_arg0,_arg1,_arg2);
+
+ wxPy_END_ALLOW_THREADS;
+} Py_INCREF(Py_None);
+ _resultobj = Py_None;
+ return _resultobj;
+}
+
+#define wxToolBar_GetMaxRows(_swigobj) (_swigobj->GetMaxRows())
+static PyObject *_wrap_wxToolBar_GetMaxRows(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ int _result;
+ wxToolBar * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxToolBar_GetMaxRows",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_GetMaxRows. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (int )wxToolBar_GetMaxRows(_arg0);
+
+ wxPy_END_ALLOW_THREADS;
+} _resultobj = Py_BuildValue("i",_result);
+ return _resultobj;
+}
+
+#define wxToolBar_GetMaxCols(_swigobj) (_swigobj->GetMaxCols())
+static PyObject *_wrap_wxToolBar_GetMaxCols(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ int _result;
+ wxToolBar * _arg0;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxToolBar_GetMaxCols",_kwnames,&_argo0))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxToolBar_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxToolBar_GetMaxCols. Expected _wxToolBar_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (int )wxToolBar_GetMaxCols(_arg0);
+
+ wxPy_END_ALLOW_THREADS;
+} _resultobj = Py_BuildValue("i",_result);
+ return _resultobj;
+}
+
static PyMethodDef stattoolcMethods[] = {
+ { "wxToolBar_GetMaxCols", (PyCFunction) _wrap_wxToolBar_GetMaxCols, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBar_GetMaxRows", (PyCFunction) _wrap_wxToolBar_GetMaxRows, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBar_SetMaxRowsCols", (PyCFunction) _wrap_wxToolBar_SetMaxRowsCols, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBar_SetToggle", (PyCFunction) _wrap_wxToolBar_SetToggle, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_ToggleTool", (PyCFunction) _wrap_wxToolBar_ToggleTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_SetToolSeparation", (PyCFunction) _wrap_wxToolBar_SetToolSeparation, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_SetToolPacking", (PyCFunction) _wrap_wxToolBar_SetToolPacking, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_GetToolLongHelp", (PyCFunction) _wrap_wxToolBar_GetToolLongHelp, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_GetToolEnabled", (PyCFunction) _wrap_wxToolBar_GetToolEnabled, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_GetMaxSize", (PyCFunction) _wrap_wxToolBar_GetMaxSize, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBar_GetToolMargins", (PyCFunction) _wrap_wxToolBar_GetToolMargins, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_SetToolBitmapSize", (PyCFunction) _wrap_wxToolBar_SetToolBitmapSize, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_GetToolBitmapSize", (PyCFunction) _wrap_wxToolBar_GetToolBitmapSize, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_GetToolSize", (PyCFunction) _wrap_wxToolBar_GetToolSize, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_EnableTool", (PyCFunction) _wrap_wxToolBar_EnableTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_AddSimpleTool", (PyCFunction) _wrap_wxToolBar_AddSimpleTool, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_AddTool", (PyCFunction) _wrap_wxToolBar_AddTool, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBar_ClearTools", (PyCFunction) _wrap_wxToolBar_ClearTools, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBar_AddSeparator", (PyCFunction) _wrap_wxToolBar_AddSeparator, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBar_AddControl", (PyCFunction) _wrap_wxToolBar_AddControl, METH_VARARGS | METH_KEYWORDS },
{ "new_wxToolBar", (PyCFunction) _wrap_new_wxToolBar, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_m_longHelpString_get", (PyCFunction) _wrap_wxToolBarTool_m_longHelpString_get, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_m_longHelpString_set", (PyCFunction) _wrap_wxToolBarTool_m_longHelpString_set, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_m_clientData_set", (PyCFunction) _wrap_wxToolBarTool_m_clientData_set, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_m_toolStyle_get", (PyCFunction) _wrap_wxToolBarTool_m_toolStyle_get, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_m_toolStyle_set", (PyCFunction) _wrap_wxToolBarTool_m_toolStyle_set, METH_VARARGS | METH_KEYWORDS },
+ { "wxToolBarTool_GetControl", (PyCFunction) _wrap_wxToolBarTool_GetControl, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_GetHeight", (PyCFunction) _wrap_wxToolBarTool_GetHeight, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_GetWidth", (PyCFunction) _wrap_wxToolBarTool_GetWidth, METH_VARARGS | METH_KEYWORDS },
{ "wxToolBarTool_SetSize", (PyCFunction) _wrap_wxToolBarTool_SetSize, METH_VARARGS | METH_KEYWORDS },
{ "_class_wxDataFormat","_wxDataFormat",0},
{ "_class_wxDropFilesEvent","_wxDropFilesEvent",0},
{ "_wxWindowDestroyEvent","_class_wxWindowDestroyEvent",0},
+ { "_wxGDIImage","_class_wxGDIImage",0},
{ "_wxStaticText","_class_wxStaticText",0},
{ "_wxFont","_class_wxFont",0},
{ "_class_wxPyDropTarget","_wxPyDropTarget",0},
{ "_class_wxSlider","_wxSlider",0},
{ "_class_wxImageList","_wxImageList",0},
{ "_class_wxBitmapButton","_wxBitmapButton",0},
+ { "_class_wxGDIImage","_wxGDIImage",0},
{ "_class_wxPaletteChangedEvent","_wxPaletteChangedEvent",0},
{ "_wxWindowID","_wxCoord",0},
{ "_wxWindowID","_wxPrintQuality",0},
def GetHeight(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBarTool_GetHeight,(self,) + _args, _kwargs)
return val
+ def GetControl(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBarTool_GetControl,(self,) + _args, _kwargs)
+ if val: val = wxControlPtr(val)
+ return val
def __setattr__(self,name,value):
if name == "m_toolStyle" :
stattoolc.wxToolBarTool_m_toolStyle_set(self,value)
def __init__(self,this):
self.this = this
self.thisown = 0
+ def AddControl(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_AddControl,(self,) + _args, _kwargs)
+ return val
def AddSeparator(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBar_AddSeparator,(self,) + _args, _kwargs)
return val
+ def ClearTools(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_ClearTools,(self,) + _args, _kwargs)
+ return val
def AddTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBar_AddTool,(self,) + _args, _kwargs)
if val: val = wxToolBarToolPtr(val)
def SetToolBitmapSize(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBar_SetToolBitmapSize,(self,) + _args, _kwargs)
return val
+ def GetToolMargins(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_GetToolMargins,(self,) + _args, _kwargs)
+ if val: val = wxSizePtr(val) ; val.thisown = 1
+ return val
def GetMaxSize(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBar_GetMaxSize,(self,) + _args, _kwargs)
if val: val = wxSizePtr(val) ; val.thisown = 1
def ToggleTool(self, *_args, **_kwargs):
val = apply(stattoolc.wxToolBar_ToggleTool,(self,) + _args, _kwargs)
return val
+ def SetToggle(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_SetToggle,(self,) + _args, _kwargs)
+ return val
+ def SetMaxRowsCols(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_SetMaxRowsCols,(self,) + _args, _kwargs)
+ return val
+ def GetMaxRows(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_GetMaxRows,(self,) + _args, _kwargs)
+ return val
+ def GetMaxCols(self, *_args, **_kwargs):
+ val = apply(stattoolc.wxToolBar_GetMaxCols,(self,) + _args, _kwargs)
+ return val
def __repr__(self):
return "<C wxToolBar instance at %s>" % (self.this,)
class wxToolBar(wxToolBarPtr):
return _resultobj;
}
+static bool wxEvtHandler_Disconnect(wxEvtHandler *self,int id,int lastId,wxEventType eventType) {
+ return self->Disconnect(id, lastId, eventType,
+ (wxObjectEventFunction)
+ &wxPyCallback::EventThunker);
+ }
+static PyObject *_wrap_wxEvtHandler_Disconnect(PyObject *self, PyObject *args, PyObject *kwargs) {
+ PyObject * _resultobj;
+ bool _result;
+ wxEvtHandler * _arg0;
+ int _arg1;
+ int _arg2 = (int ) -1;
+ wxEventType _arg3 = (wxEventType ) wxEVT_NULL;
+ PyObject * _argo0 = 0;
+ char *_kwnames[] = { "self","id","lastId","eventType", NULL };
+
+ self = self;
+ if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oi|ii:wxEvtHandler_Disconnect",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3))
+ return NULL;
+ if (_argo0) {
+ if (_argo0 == Py_None) { _arg0 = NULL; }
+ else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxEvtHandler_p")) {
+ PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxEvtHandler_Disconnect. Expected _wxEvtHandler_p.");
+ return NULL;
+ }
+ }
+{
+ wxPy_BEGIN_ALLOW_THREADS;
+ _result = (bool )wxEvtHandler_Disconnect(_arg0,_arg1,_arg2,_arg3);
+
+ wxPy_END_ALLOW_THREADS;
+} _resultobj = Py_BuildValue("i",_result);
+ return _resultobj;
+}
+
static void *SwigwxValidatorTowxEvtHandler(void *ptr) {
wxValidator *src;
wxEvtHandler *dest;
{ "wxValidator_GetWindow", (PyCFunction) _wrap_wxValidator_GetWindow, METH_VARARGS | METH_KEYWORDS },
{ "wxValidator_Clone", (PyCFunction) _wrap_wxValidator_Clone, METH_VARARGS | METH_KEYWORDS },
{ "new_wxValidator", (PyCFunction) _wrap_new_wxValidator, METH_VARARGS | METH_KEYWORDS },
+ { "wxEvtHandler_Disconnect", (PyCFunction) _wrap_wxEvtHandler_Disconnect, METH_VARARGS | METH_KEYWORDS },
{ "wxEvtHandler_Connect", (PyCFunction) _wrap_wxEvtHandler_Connect, METH_VARARGS | METH_KEYWORDS },
{ "wxEvtHandler_SetPreviousHandler", (PyCFunction) _wrap_wxEvtHandler_SetPreviousHandler, METH_VARARGS | METH_KEYWORDS },
{ "wxEvtHandler_SetNextHandler", (PyCFunction) _wrap_wxEvtHandler_SetNextHandler, METH_VARARGS | METH_KEYWORDS },
{ "_EBool","_wxWindowID",0},
{ "_class_wxRegion","_wxRegion",0},
{ "_class_wxDataFormat","_wxDataFormat",0},
+ { "_wxGDIImage","_class_wxGDIImage",0},
{ "_wxFont","_class_wxFont",0},
{ "_class_wxPyDropTarget","_wxPyDropTarget",0},
{ "_unsigned_long","_wxDash",0},
{ "_class_wxPyDataObjectSimple","_wxPyDataObjectSimple",0},
{ "_class_wxPyDropSource","_wxPyDropSource",0},
{ "_class_wxImageList","_wxImageList",0},
+ { "_class_wxGDIImage","_wxGDIImage",0},
{ "_wxWindowID","_wxCoord",0},
{ "_wxWindowID","_wxPrintQuality",0},
{ "_wxWindowID","_size_t",0},
def Connect(self, *_args, **_kwargs):
val = apply(windowsc.wxEvtHandler_Connect,(self,) + _args, _kwargs)
return val
+ def Disconnect(self, *_args, **_kwargs):
+ val = apply(windowsc.wxEvtHandler_Disconnect,(self,) + _args, _kwargs)
+ return val
def __repr__(self):
return "<C wxEvtHandler instance at %s>" % (self.this,)
class wxEvtHandler(wxEvtHandlerPtr):
void DrawFieldText(wxDC& dc, int i);
void InitColours(void);
- // OnSysColourChanged(wxSysColourChangedEvent& event);
-
void SetFieldsCount(int number = 1);
void SetStatusText(const wxString& text, int i = 0);
void SetStatusWidths(int LCOUNT, int* LIST);
public:
wxToolBarTool();
~wxToolBarTool();
-#ifdef __WXMSW__
void SetSize( long w, long h ) { m_width = w; m_height = h; }
long GetWidth () const { return m_width; }
long GetHeight () const { return m_height; }
-#endif
+ wxControl *GetControl();
public:
int m_toolStyle;
wxObject * m_clientData;
int m_index;
-#ifdef __WXMSW__
long m_x;
long m_y;
long m_width;
long m_height;
-#endif
bool m_toggleState;
bool m_isToggle;
bool m_deleteSecondBitmap;
%pragma(python) addtomethod = "__init__:wx._StdWindowCallbacks(self)"
+ bool AddControl(wxControl * control);
void AddSeparator();
+ void ClearTools();
// Ignoge the clientData for now...
%addmethods {
}
-// void DrawTool(wxMemoryDC& memDC, wxToolBarTool* tool);
- void EnableTool(int toolIndex, const bool enable);
-#ifdef __WXMSW__
- wxToolBarTool* FindToolForPosition(const float x, const float y);
+ void EnableTool(int toolIndex, bool enable);
+ wxToolBarTool* FindToolForPosition(long x, long y);
wxSize GetToolSize();
wxSize GetToolBitmapSize();
void SetToolBitmapSize(const wxSize& size);
-// wxSize GetMargins();
+ wxSize GetToolMargins();
wxSize GetMaxSize();
// wxObject* GetToolClientData(int toolIndex);
-#endif
bool GetToolEnabled(int toolIndex);
wxString GetToolLongHelp(int toolIndex);
int GetToolPacking();
wxString GetToolShortHelp(int toolIndex);
bool GetToolState(int toolIndex);
- // TODO: figure out how to handle these
- //bool OnLeftClick(int toolIndex, bool toggleDown);
- //void OnMouseEnter(int toolIndex);
- //void OnRightClick(int toolIndex, float x, float y);
bool Realize();
void SetToolPacking(int packing);
void SetToolSeparation(int separation);
void ToggleTool(int toolIndex, const bool toggle);
+ void SetToggle(int toolIndex, bool toggle);
+
+ void SetMaxRowsCols(int rows, int cols);
+ int GetMaxRows();
+ int GetMaxCols();
+
};
new wxPyCallback(func));
}
}
+
+ bool Disconnect(int id, int lastId = -1,
+ wxEventType eventType = wxEVT_NULL) {
+ return self->Disconnect(id, lastId, eventType,
+ (wxObjectEventFunction)
+ &wxPyCallback::EventThunker);
+ }
+
}
};