From 322913cef36b156a4a9722ce6a68845e3219e615 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Thu, 20 Nov 2003 20:41:31 +0000 Subject: [PATCH] More docstring updates for OUTPUT parameters git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@24615 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- wxPython/src/_core_ex.py | 9 +- wxPython/src/_datetime.i | 9 +- wxPython/src/_dc.i | 79 ++++++-- wxPython/src/_dirctrl.i | 12 +- wxPython/src/_functions.i | 24 ++- wxPython/src/_imaglist.i | 6 +- wxPython/src/_listctrl.i | 9 +- wxPython/src/_misc.i | 16 +- wxPython/src/_notebook.i | 5 +- wxPython/src/_palette.i | 8 +- wxPython/src/_panel.i | 33 ++-- wxPython/src/_printfw.i | 20 +- wxPython/src/_pycontrol.i | 12 +- wxPython/src/_pywindows.i | 24 ++- wxPython/src/_textctrl.i | 11 +- wxPython/src/_treectrl.i | 13 +- wxPython/src/_window.i | 3 +- wxPython/src/grid.i | 45 ++++- wxPython/src/gtk/controls.py | 36 +++- wxPython/src/gtk/core.py | 9 +- wxPython/src/gtk/gdi.py | 74 +++++--- wxPython/src/gtk/gdi_wrap.cpp | 168 ++++++++-------- wxPython/src/gtk/grid.py | 16 +- wxPython/src/gtk/misc.py | 95 +++++----- wxPython/src/gtk/misc_wrap.cpp | 305 ++++++++++-------------------- wxPython/src/gtk/windows.py | 54 +++--- wxPython/src/gtk/windows_wrap.cpp | 232 +++++++++++------------ wxPython/src/gtk/wizard.py | 6 +- wxPython/src/wizard.i | 12 +- 29 files changed, 716 insertions(+), 629 deletions(-) diff --git a/wxPython/src/_core_ex.py b/wxPython/src/_core_ex.py index b26ed2113f..8bf9c34ef6 100644 --- a/wxPython/src/_core_ex.py +++ b/wxPython/src/_core_ex.py @@ -1,15 +1,12 @@ #---------------------------------------------------------------------------- -# Use Python's bool constants if available, make aliases if not +# Use Python's bool constants if available, make some if not try: True except NameError: - True = 1==1 - False = 1==0 + __builtins__.True = 1==1 + __builtins__.False = 1==0 -# Backwards compaatibility -TRUE = true = True -FALSE = false = False # workarounds for bad wxRTTI names diff --git a/wxPython/src/_datetime.i b/wxPython/src/_datetime.i index 04ef881b0e..1142cb30fb 100644 --- a/wxPython/src/_datetime.i +++ b/wxPython/src/_datetime.i @@ -58,11 +58,12 @@ //--------------------------------------------------------------------------- +//typedef unsigned short wxDateTime_t; +#define wxDateTime_t int // wxDateTime represents an absolute moment in the time class wxDateTime { public: - typedef unsigned short wxDateTime_t; enum TZ { @@ -362,8 +363,10 @@ public: static wxString GetWeekDayName(WeekDay weekday, NameFlags flags = Name_Full); - // get the AM and PM strings in the current locale (may be empty) - static void GetAmPmStrings(wxString *OUTPUT, wxString *OUTPUT); + DocDeclAStr( + static void, GetAmPmStrings(wxString *OUTPUT, wxString *OUTPUT), + "GetAmPmStrings() -> (am, pm)", + "Get the AM and PM strings in the current locale (may be empty)"); // return True if the given country uses DST for this year static bool IsDSTApplicable(int year = Inv_Year, diff --git a/wxPython/src/_dc.i b/wxPython/src/_dc.i index e465437631..b2ddce26ea 100644 --- a/wxPython/src/_dc.i +++ b/wxPython/src/_dc.i @@ -226,7 +226,10 @@ public: virtual void DestroyClippingRegion(); - void GetClippingBox(wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT) const; + DocDeclA( + void, GetClippingBox(wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT) const, + "GetClippingBox() -> (x, y, width, height)"); + %extend { wxRect GetClippingRect() { wxRect rect; @@ -243,27 +246,50 @@ public: virtual wxCoord GetCharHeight() const; virtual wxCoord GetCharWidth() const; - // only works for single line strings - void GetTextExtent(const wxString& string, wxCoord *OUTPUT, wxCoord *OUTPUT); - %name(GetFullTextExtent)void GetTextExtent(const wxString& string, - wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord* OUTPUT, - wxFont* font = NULL); - // works for single as well as multi-line strings - void GetMultiLineTextExtent(const wxString& text, wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT, - wxFont *font = NULL); + DocDeclAStr( + void, GetTextExtent(const wxString& string, wxCoord *OUTPUT, wxCoord *OUTPUT), + "GetTextExtent(wxString string) -> (width, height)", + "Get the width and height of the text using the current font.\n" + "Only works for single line strings."); + DocDeclAStrName( + void, GetTextExtent(const wxString& string, + wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord* OUTPUT, + wxFont* font = NULL), + "GetFullTextExtent(wxString string, Font font=None) ->\n (width, height, descent, externalLeading)", + "Get the width, height, decent and leading of the text using the current or specified font.\n" + "Only works for single line strings.", + GetFullTextExtent); + + // works for single as well as multi-line strings + DocDeclAStr( + void, GetMultiLineTextExtent(const wxString& text, + wxCoord *OUTPUT, wxCoord *OUTPUT, wxCoord *OUTPUT, + wxFont *font = NULL), + "GetMultiLineTextExtent(wxString string, Font font=None) ->\n (width, height, descent, externalLeading)", + "Get the width, height, decent and leading of the text using the current or specified font.\n" + "Works for single as well as multi-line strings."); + // size and resolution // ------------------- - // in device units - %name(GetSizeTuple)void GetSize(int* OUTPUT, int* OUTPUT); + DocStr(GetSize, "Get the DC size in device units."); wxSize GetSize(); + DocDeclAName( + void, GetSize( int *OUTPUT, int *OUTPUT ), + "GetSizeTuple() -> (width, height)", + GetSizeTuple); + - // in mm - %name(GetSizeMMWH)void GetSizeMM(int* OUTPUT, int* OUTPUT) const; + DocStr(GetSizeMM, "Get the DC size in milimeters."); wxSize GetSizeMM() const; + DocDeclAName( + void, GetSizeMM( int *OUTPUT, int *OUTPUT ) const, + "GetSizeMMTuple() -> (width, height)", + GetSizeMMTuple); + // coordinates conversions @@ -310,19 +336,36 @@ public: int GetMapMode() const; virtual void SetMapMode(int mode); - virtual void GetUserScale(double *OUTPUT, double *OUTPUT) const; + + DocDeclA( + virtual void, GetUserScale(double *OUTPUT, double *OUTPUT) const, + "GetUserScale() -> (xScale, yScale)"); + virtual void SetUserScale(double x, double y); - virtual void GetLogicalScale(double *OUTPUT, double *OUTPUT); + + DocDeclA( + virtual void, GetLogicalScale(double *OUTPUT, double *OUTPUT), + "GetLogicalScale() -> (xScale, yScale)"); + virtual void SetLogicalScale(double x, double y); - %name(GetLogicalOriginTuple) void GetLogicalOrigin(wxCoord *OUTPUT, wxCoord *OUTPUT) const; + wxPoint GetLogicalOrigin() const; + DocDeclAName( + void, GetLogicalOrigin(wxCoord *OUTPUT, wxCoord *OUTPUT) const, + "GetLogicalOriginTuple() -> (x,y)", + GetLogicalOriginTuple); + virtual void SetLogicalOrigin(wxCoord x, wxCoord y); - %name(GetDeviceOriginTuple) void GetDeviceOrigin(wxCoord *OUTPUT, wxCoord *OUTPUT) const; wxPoint GetDeviceOrigin() const; + DocDeclAName( + void, GetDeviceOrigin(wxCoord *OUTPUT, wxCoord *OUTPUT) const, + "GetDeviceOriginTuple() -> (x,y)", + GetDeviceOriginTuple); + virtual void SetDeviceOrigin(wxCoord x, wxCoord y); virtual void SetAxisOrientation(bool xLeftRight, bool yBottomUp); @@ -347,6 +390,8 @@ public: wxCoord MaxY() const; + DocA(GetBoundingBox, + "GetBoundingBox() -> (x1,y1, x2,y2)"); %extend { void GetBoundingBox(int* OUTPUT, int* OUTPUT, int* OUTPUT, int* OUTPUT); // See below for implementation diff --git a/wxPython/src/_dirctrl.i b/wxPython/src/_dirctrl.i index 5703f1cff0..98549692b9 100644 --- a/wxPython/src/_dirctrl.i +++ b/wxPython/src/_dirctrl.i @@ -117,11 +117,13 @@ public: // Parse the filter into an array of filters and an array of descriptions // virtual int ParseFilter(const wxString& filterStr, wxArrayString& filters, wxArrayString& descriptions); - // Find the child that matches the first part of 'path'. - // E.g. if a child path is "/usr" and 'path' is "/usr/include" - // then the child for /usr is returned. - // If the path string has been used (we're at the leaf), done is set to True - virtual wxTreeItemId FindChild(wxTreeItemId parentId, const wxString& path, bool& OUTPUT); + DocDeclAStr( + virtual wxTreeItemId, FindChild(wxTreeItemId parentId, const wxString& path, bool& OUTPUT), + "FindChild(wxTreeItemId parentId, wxString path) -> (item, done)", + "Find the child that matches the first part of 'path'. E.g. if a child path is\n" + "\"/usr\" and 'path' is \"/usr/include\" then the child for /usr is returned.\n" + "If the path string has been used (we're at the leaf), done is set to True\n"); + // Resize the components of the control virtual void DoResize(); diff --git a/wxPython/src/_functions.i b/wxPython/src/_functions.i index c4395b6a74..1d85f1a864 100644 --- a/wxPython/src/_functions.i +++ b/wxPython/src/_functions.i @@ -33,12 +33,20 @@ void wxBell(); void wxEndBusyCursor(); long wxGetElapsedTime(bool resetTimer = True); -void wxGetMousePosition(int* OUTPUT, int* OUTPUT); + +DocDeclA( + void, wxGetMousePosition(int* OUTPUT, int* OUTPUT), + "GetMousePosition() -> (x,y)"); + bool wxIsBusy(); wxString wxNow(); bool wxShell(const wxString& command = wxPyEmptyString); void wxStartTimer(); -int wxGetOsVersion(int *OUTPUT, int *OUTPUT); + +DocDeclA( + int, wxGetOsVersion(int *OUTPUT, int *OUTPUT), + "GetOsVersion() -> (platform, major, minor)"); + wxString wxGetOsDescription(); #if defined(__WXMSW__) || defined(__WXMAC__) @@ -170,13 +178,19 @@ bool wxColourDisplay(); int wxDisplayDepth(); int wxGetDisplayDepth(); -void wxDisplaySize(int* OUTPUT, int* OUTPUT); +DocDeclA( + void, wxDisplaySize(int* OUTPUT, int* OUTPUT), + "DisplaySize() -> (width, height)"); wxSize wxGetDisplaySize(); -void wxDisplaySizeMM(int* OUTPUT, int* OUTPUT); +DocDeclA( + void, wxDisplaySizeMM(int* OUTPUT, int* OUTPUT), + "DisplaySizeMM() -> (width, height)"); wxSize wxGetDisplaySizeMM(); -void wxClientDisplayRect(int *OUTPUT, int *OUTPUT, int *OUTPUT, int *OUTPUT); +DocDeclA( + void, wxClientDisplayRect(int *OUTPUT, int *OUTPUT, int *OUTPUT, int *OUTPUT), + "ClientDisplayRect() -> (x, y, width, height)"); wxRect wxGetClientDisplayRect(); void wxSetCursor(wxCursor& cursor); diff --git a/wxPython/src/_imaglist.i b/wxPython/src/_imaglist.i index a5a37f08ff..87962cdbab 100644 --- a/wxPython/src/_imaglist.i +++ b/wxPython/src/_imaglist.i @@ -61,7 +61,11 @@ public: int GetImageCount(); bool Remove(int index); bool RemoveAll(); - void GetSize(int index, int& OUTPUT, int& OUTPUT); + + DocDeclA( + void, GetSize(int index, int& OUTPUT, int& OUTPUT), + "GetSize() -> (width,height)"); + }; //--------------------------------------------------------------------------- diff --git a/wxPython/src/_listctrl.i b/wxPython/src/_listctrl.i index 600cc79758..3c6eba561c 100644 --- a/wxPython/src/_listctrl.i +++ b/wxPython/src/_listctrl.i @@ -632,9 +632,12 @@ public: // the item after 'start' or the beginning if 'start' is -1. %name(FindItemAtPos) long FindItem(long start, const wxPoint& pt, int direction); - // Determines which item (if any) is at the specified point, - // giving details in the second return value (see wxLIST_HITTEST_... flags above) - long HitTest(const wxPoint& point, int& OUTPUT); + + DocDeclAStr( + long, HitTest(const wxPoint& point, int& OUTPUT), + "HitTest(Point point) -> (item, where)", + "Determines which item (if any) is at the specified point,\n" + "giving details in the second return value (see wxLIST_HITTEST_... flags.)"); // Inserts an item, returning the index of the new item if successful, // -1 otherwise. diff --git a/wxPython/src/_misc.i b/wxPython/src/_misc.i index 46a8589bcd..54a6812e35 100644 --- a/wxPython/src/_misc.i +++ b/wxPython/src/_misc.i @@ -40,10 +40,20 @@ public: bool IsOk(); bool IsVisible(); - %name(GetPositionTuple)void GetPosition(int *OUTPUT, int *OUTPUT); + wxPoint GetPosition(); - %name(GetSizeTuple)void GetSize(int *OUTPUT, int *OUTPUT); + DocDeclAName( + void, GetPosition(int *OUTPUT, int *OUTPUT), + "GetPositionTuple() -> (x,y)", + GetPositionTuple); + wxSize GetSize(); + DocDeclAName( + void, GetSize( int *OUTPUT, int *OUTPUT ), + "GetSizeTuple() -> (width, height)", + GetSizeTuple); + + wxWindow *GetWindow(); %name(MoveXY)void Move(int x, int y); void Move(const wxPoint& pt); @@ -52,7 +62,7 @@ public: void Show(int show = True); void Hide(); - %pragma(python) addtoclass = "def __nonzero__(self): return self.IsOk()" + %pythoncode { def __nonzero__(self): return self.IsOk() } }; %inline %{ diff --git a/wxPython/src/_notebook.i b/wxPython/src/_notebook.i index 9f3274e835..305a3103a4 100644 --- a/wxPython/src/_notebook.i +++ b/wxPython/src/_notebook.i @@ -191,7 +191,10 @@ public: // hit test, returns which tab is hit and, optionally, where (icon, label) // (not implemented on all platforms) - virtual int HitTest(const wxPoint& pt, long* OUTPUT) const; + DocDeclAStr( + virtual int, HitTest(const wxPoint& pt, long* OUTPUT) const, + "HitTest(Point pt) -> (tab, where)", + "Returns the tab which is hit, and flags indicating where using wxNB_HITTEST_ flags."); // implement some base class functions virtual wxSize CalcSizeFromPage(const wxSize& sizePage) const; diff --git a/wxPython/src/_palette.i b/wxPython/src/_palette.i index 6dafe16272..e2fdbe4b69 100644 --- a/wxPython/src/_palette.i +++ b/wxPython/src/_palette.i @@ -25,10 +25,14 @@ public: ~wxPalette(); int GetPixel(byte red, byte green, byte blue); - bool GetRGB(int pixel, byte* OUTPUT, byte* OUTPUT, byte* OUTPUT); + + DocDeclA( + bool, GetRGB(int pixel, byte* OUTPUT, byte* OUTPUT, byte* OUTPUT), + "GetRGB(int pixel) -> (R,G,B)"); + bool Ok(); - %pragma(python) addtoclass = "def __nonzero__(self): return self.Ok()" + %pythoncode { def __nonzero__(self): return self.Ok() } }; diff --git a/wxPython/src/_panel.i b/wxPython/src/_panel.i index 0fb5d8fa1c..f318d26caf 100644 --- a/wxPython/src/_panel.i +++ b/wxPython/src/_panel.i @@ -93,13 +93,10 @@ public: // Set the x, y scrolling increments. void SetScrollRate( int xstep, int ystep ); - %feature("autodoc") GetScrollPixelsPerUnit - "GetScrollPixelsPerUnit() -> (xUnit, yUnit)"; - %feature("docstring") GetScrollPixelsPerUnit " - get the size of one logical unit in physical ones - " - virtual void GetScrollPixelsPerUnit(int *OUTPUT, - int *OUTPUT) const; + DocDeclAStr( + virtual void, GetScrollPixelsPerUnit(int *OUTPUT, int *OUTPUT) const, + "GetScrollPixelsPerUnit() -> (xUnit, yUnit)", + "Get the size of one logical unit in physical units."); // Enable/disable Windows scrolling in either direction. If True, wxWindows // scrolls the canvas and only a bit of the canvas is invalidated; no @@ -108,9 +105,12 @@ public: // actually scroll a non-constant distance virtual void EnableScrolling(bool x_scrolling, bool y_scrolling); - // Get the view start - virtual void GetViewStart(int *OUTPUT, int *OUTPUT) const; + DocDeclAStr( + virtual void, GetViewStart(int *OUTPUT, int *OUTPUT) const, + "GetViewStart() -> (x,y)", + "Get the view start"); + // Set the scale factor, used in PrepareDC void SetScale(double xs, double ys); double GetScaleX() const; @@ -120,12 +120,21 @@ public: %nokwargs CalcScrolledPosition; %nokwargs CalcUnscrolledPosition; - // translate between scrolled and unscrolled coordinates - void CalcScrolledPosition(int x, int y, int *OUTPUT, int *OUTPUT) const; + DocStr(CalcScrolledPosition, "Translate between scrolled and unscrolled coordinates."); wxPoint CalcScrolledPosition(const wxPoint& pt) const; - void CalcUnscrolledPosition(int x, int y, int *OUTPUT, int *OUTPUT) const; + DocDeclA( + void, CalcScrolledPosition(int x, int y, int *OUTPUT, int *OUTPUT) const, + "CalcScrolledPosition(int x, int y) -> (sx, sy)"); + + + DocStr(CalcUnscrolledPosition, "Translate between scrolled and unscrolled coordinates."); wxPoint CalcUnscrolledPosition(const wxPoint& pt) const; + DocDeclA( + void, CalcUnscrolledPosition(int x, int y, int *OUTPUT, int *OUTPUT) const, + "CalcUnscrolledPosition(int x, int y) -> (ux, uy)"); + + // TODO: use directors? // virtual void DoCalcScrolledPosition(int x, int y, int *xx, int *yy) const; // virtual void DoCalcUnscrolledPosition(int x, int y, int *xx, int *yy) const; diff --git a/wxPython/src/_printfw.i b/wxPython/src/_printfw.i index 615cd9e629..f91b876a0b 100644 --- a/wxPython/src/_printfw.i +++ b/wxPython/src/_printfw.i @@ -334,17 +334,25 @@ public: wxDC* GetDC(); void SetDC(wxDC *dc); - void GetPageSizePixels(int *OUTPUT, int *OUTPUT); void SetPageSizePixels(int w, int h); + DocDeclA( + void, GetPageSizePixels(int *OUTPUT, int *OUTPUT), + "GetPageSizePixels() -> (w, h)"); void SetPageSizeMM(int w, int h); - void GetPageSizeMM(int *OUTPUT, int *OUTPUT); + DocDeclA( + void, GetPageSizeMM(int *OUTPUT, int *OUTPUT), + "GetPageSizeMM() -> (w, h)"); void SetPPIScreen(int x, int y); - void GetPPIScreen(int *OUTPUT, int *OUTPUT); + DocDeclA( + void, GetPPIScreen(int *OUTPUT, int *OUTPUT), + "GetPPIScreen() -> (x,y)"); void SetPPIPrinter(int x, int y); - void GetPPIPrinter(int *OUTPUT, int *OUTPUT); + DocDeclA( + void, GetPPIPrinter(int *OUTPUT, int *OUTPUT), + "GetPPIPrinter() -> (x,y)"); bool IsPreview(); void SetIsPreview(bool p); @@ -355,8 +363,10 @@ public: void base_OnBeginPrinting(); void base_OnEndPrinting(); void base_OnPreparePrinting(); - void base_GetPageInfo(int *OUTPUT, int *OUTPUT, int *OUTPUT, int *OUTPUT); bool base_HasPage(int page); + DocDeclA( + void, base_GetPageInfo(int *OUTPUT, int *OUTPUT, int *OUTPUT, int *OUTPUT), + "base_GetPageInfo() -> (minPage, maxPage, pageFrom, pageTo)"); }; //--------------------------------------------------------------------------- diff --git a/wxPython/src/_pycontrol.i b/wxPython/src/_pycontrol.i index cc792bd968..868e9b5143 100644 --- a/wxPython/src/_pycontrol.i +++ b/wxPython/src/_pycontrol.i @@ -115,9 +115,15 @@ public: void base_DoSetClientSize(int width, int height); void base_DoSetVirtualSize( int x, int y ); - void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const; + DocDeclA( + void, base_DoGetSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetSize() -> (width, height)"); + DocDeclA( + void, base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetClientSize() -> (width, height)"); + DocDeclA( + void, base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetPosition() -> (x,y)"); wxSize base_DoGetVirtualSize() const; wxSize base_DoGetBestSize() const; diff --git a/wxPython/src/_pywindows.i b/wxPython/src/_pywindows.i index bad01f5dda..74d5be5e30 100644 --- a/wxPython/src/_pywindows.i +++ b/wxPython/src/_pywindows.i @@ -142,9 +142,15 @@ public: void base_DoSetClientSize(int width, int height); void base_DoSetVirtualSize( int x, int y ); - void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const; + DocDeclA( + void, base_DoGetSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetSize() -> (width, height)"); + DocDeclA( + void, base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetClientSize() -> (width, height)"); + DocDeclA( + void, base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetPosition() -> (x,y)"); wxSize base_DoGetVirtualSize() const; wxSize base_DoGetBestSize() const; @@ -263,9 +269,15 @@ public: void base_DoSetClientSize(int width, int height); void base_DoSetVirtualSize( int x, int y ); - void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const; + DocDeclA( + void, base_DoGetSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetSize() -> (width, height)"); + DocDeclA( + void, base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetClientSize() -> (width, height)"); + DocDeclA( + void, base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetPosition() -> (x,y)"); wxSize base_DoGetVirtualSize() const; wxSize base_DoGetBestSize() const; diff --git a/wxPython/src/_textctrl.i b/wxPython/src/_textctrl.i index c43785aaa3..b83c30dacf 100644 --- a/wxPython/src/_textctrl.i +++ b/wxPython/src/_textctrl.i @@ -192,8 +192,11 @@ public: bool IsSingleLine() const; bool IsMultiLine() const; - // If the return values from and to are the same, there is no selection. - virtual void GetSelection(long* OUTPUT, long* OUTPUT) const; + + DocDeclAStr( + virtual void, GetSelection(long* OUTPUT, long* OUTPUT) const, + "GetSelection() -> (from, to)", + "If the return values from and to are the same, there is no selection."); virtual wxString GetStringSelection() const; @@ -236,7 +239,9 @@ public: // considering all its contents as a single strings) and (x, y) coordinates // which represent column and line. virtual long XYToPosition(long x, long y) const; - virtual /*bool*/ void PositionToXY(long pos, long *OUTPUT, long *OUTPUT) const; + DocDeclA( + virtual /*bool*/ void, PositionToXY(long pos, long *OUTPUT, long *OUTPUT) const, + "PositionToXY(long pos) -> (x, y)"); virtual void ShowPosition(long pos); diff --git a/wxPython/src/_treectrl.i b/wxPython/src/_treectrl.i index 52112b1a91..bbcfb4090b 100644 --- a/wxPython/src/_treectrl.i +++ b/wxPython/src/_treectrl.i @@ -682,12 +682,13 @@ public: - // determine to which item (if any) belongs the given point (the - // coordinates specified are relative to the client area of tree ctrl) - // and fill the flags parameter with a bitmask of wxTREE_HITTEST_xxx - // constants. - // - wxTreeItemId HitTest(const wxPoint& point, int& OUTPUT); + DocDeclAStr( + wxTreeItemId, HitTest(const wxPoint& point, int& OUTPUT), + "HitTest(Point point) -> (item, where)", + "Determine which item (if any) belongs the given point. The\n" + "coordinates specified are relative to the client area of tree ctrl\n" + "and the where return value is set to a bitmask of wxTREE_HITTEST_xxx\n" + "constants.\n"); %extend { diff --git a/wxPython/src/_window.i b/wxPython/src/_window.i index 0ef9decfe6..e0f5229c7d 100644 --- a/wxPython/src/_window.i +++ b/wxPython/src/_window.i @@ -138,8 +138,7 @@ public: "GetPositionTuple() -> (x,y)", GetPositionTuple); - - + DocStr(GetSize, "Get the window size."); wxSize GetSize() const; DocDeclAName( diff --git a/wxPython/src/grid.i b/wxPython/src/grid.i index ea4dbbafdb..dd116ffd2f 100644 --- a/wxPython/src/grid.i +++ b/wxPython/src/grid.i @@ -1032,8 +1032,15 @@ public: wxColour GetTextColour() const; wxColour GetBackgroundColour() const; wxFont GetFont() const; - void GetAlignment(int *OUTPUT, int *OUTPUT) const; - void GetSize(int *OUTPUT, int *OUTPUT) const; + + DocDeclA( + void, GetAlignment(int *OUTPUT, int *OUTPUT) const, + "GetAlignment() -> (hAlign, vAlign)"); + + DocDeclA( + void, GetSize(int *OUTPUT, int *OUTPUT) const, + "GetSize() -> (num_rows, num_cols)"); + bool GetOverflow() const; wxGridCellRenderer *GetRenderer(wxGrid* grid, int row, int col) const; wxGridCellEditor *GetEditor(wxGrid* grid, int row, int col) const; @@ -1583,9 +1590,10 @@ public: // // // void StringToLines( const wxString& value, wxArrayString& lines ); - void GetTextBoxSize( wxDC& dc, - wxArrayString& lines, - long *OUTPUT, long *OUTPUT ); + DocDeclA( + void, GetTextBoxSize( wxDC& dc, wxArrayString& lines, + long *OUTPUT, long *OUTPUT ), + "GetTextBoxSize(DC dc, list lines) -> (width, height)"); // ------ @@ -1679,8 +1687,15 @@ public: wxColour GetLabelBackgroundColour(); wxColour GetLabelTextColour(); wxFont GetLabelFont(); - void GetRowLabelAlignment( int *OUTPUT, int *OUTPUT ); - void GetColLabelAlignment( int *OUTPUT, int *OUTPUT ); + + DocDeclA( + void, GetRowLabelAlignment( int *OUTPUT, int *OUTPUT ), + "GetRowLabelAlignment() -> (horiz, vert)"); + + DocDeclA( + void, GetColLabelAlignment( int *OUTPUT, int *OUTPUT ), + "GetColLabelAlignment() -> (horiz, vert)"); + int GetColLabelTextOrientation(); wxString GetRowLabelValue( int row ); wxString GetColLabelValue( int col ); @@ -1742,11 +1757,21 @@ public: wxColour GetCellTextColour( int row, int col ); wxFont GetDefaultCellFont(); wxFont GetCellFont( int row, int col ); - void GetDefaultCellAlignment( int *OUTPUT, int *OUTPUT ); - void GetCellAlignment( int row, int col, int *OUTPUT, int *OUTPUT ); + + DocDeclA( + void, GetDefaultCellAlignment( int *OUTPUT, int *OUTPUT ), + "GetDefaultCellAlignment() -> (horiz, vert)"); + + DocDeclA( + void, GetCellAlignment( int row, int col, int *OUTPUT, int *OUTPUT ), + "GetCellAlignment() -> (horiz, vert)"); + bool GetDefaultCellOverflow(); bool GetCellOverflow( int row, int col ); - void GetCellSize( int row, int col, int *OUTPUT, int *OUTPUT ); + + DocDeclA( + void, GetCellSize( int row, int col, int *OUTPUT, int *OUTPUT ), + "GetCellSize(int row, int col) -> (num_rows, num_cols)"); void SetDefaultRowSize( int height, bool resizeExistingRows = False ); void SetRowSize( int row, int height ); diff --git a/wxPython/src/gtk/controls.py b/wxPython/src/gtk/controls.py index 674264bbf5..179008b47c 100644 --- a/wxPython/src/gtk/controls.py +++ b/wxPython/src/gtk/controls.py @@ -997,7 +997,9 @@ class TextCtrl(core.Control): return _controls.TextCtrl_IsMultiLine(*args, **kwargs) def GetSelection(*args, **kwargs): - """GetSelection(long OUTPUT, long OUTPUT)""" + """GetSelection() -> (from, to) + +If the return values from and to are the same, there is no selection.""" return _controls.TextCtrl_GetSelection(*args, **kwargs) def GetStringSelection(*args, **kwargs): @@ -1069,7 +1071,7 @@ class TextCtrl(core.Control): return _controls.TextCtrl_XYToPosition(*args, **kwargs) def PositionToXY(*args, **kwargs): - """PositionToXY(long pos, long OUTPUT, long OUTPUT)""" + """PositionToXY(long pos) -> (x, y)""" return _controls.TextCtrl_PositionToXY(*args, **kwargs) def ShowPosition(*args, **kwargs): @@ -1897,7 +1899,9 @@ class Notebook(BookCtrl): return _controls.Notebook_SetTabSize(*args, **kwargs) def HitTest(*args, **kwargs): - """HitTest(Point pt, long OUTPUT) -> int""" + """HitTest(Point pt) -> (tab, where) + +Returns the tab which is hit, and flags indicating where using wxNB_HITTEST_ flags.""" return _controls.Notebook_HitTest(*args, **kwargs) def CalcSizeFromPage(*args, **kwargs): @@ -3243,7 +3247,10 @@ class ListCtrl(core.Control): return _controls.ListCtrl_FindItemAtPos(*args, **kwargs) def HitTest(*args, **kwargs): - """HitTest(Point point, int OUTPUT) -> long""" + """HitTest(Point point) -> (item, where) + +Determines which item (if any) is at the specified point, +giving details in the second return value (see wxLIST_HITTEST_... flags.)""" return _controls.ListCtrl_HitTest(*args, **kwargs) def InsertItem(*args, **kwargs): @@ -3972,7 +3979,13 @@ class TreeCtrl(core.Control): return _controls.TreeCtrl_SortChildren(*args, **kwargs) def HitTest(*args, **kwargs): - """HitTest(Point point, int OUTPUT) -> TreeItemId""" + """HitTest(Point point) -> (item, where) + +Determine which item (if any) belongs the given point. The +coordinates specified are relative to the client area of tree ctrl +and the where return value is set to a bitmask of wxTREE_HITTEST_xxx +constants. +""" return _controls.TreeCtrl_HitTest(*args, **kwargs) def GetBoundingRect(*args, **kwargs): @@ -4085,7 +4098,12 @@ class GenericDirCtrl(core.Control): return _controls.GenericDirCtrl_GetFilterListCtrl(*args, **kwargs) def FindChild(*args, **kwargs): - """FindChild(TreeItemId parentId, wxString path, bool OUTPUT) -> TreeItemId""" + """FindChild(wxTreeItemId parentId, wxString path) -> (item, done) + +Find the child that matches the first part of 'path'. E.g. if a child path is +"/usr" and 'path' is "/usr/include" then the child for /usr is returned. +If the path string has been used (we're at the leaf), done is set to True +""" return _controls.GenericDirCtrl_FindChild(*args, **kwargs) def DoResize(*args, **kwargs): @@ -4183,15 +4201,15 @@ class PyControl(core.Control): return _controls.PyControl_base_DoSetVirtualSize(*args, **kwargs) def base_DoGetSize(*args, **kwargs): - """base_DoGetSize(int OUTPUT, int OUTPUT)""" + """base_DoGetSize() -> (width, height)""" return _controls.PyControl_base_DoGetSize(*args, **kwargs) def base_DoGetClientSize(*args, **kwargs): - """base_DoGetClientSize(int OUTPUT, int OUTPUT)""" + """base_DoGetClientSize() -> (width, height)""" return _controls.PyControl_base_DoGetClientSize(*args, **kwargs) def base_DoGetPosition(*args, **kwargs): - """base_DoGetPosition(int OUTPUT, int OUTPUT)""" + """base_DoGetPosition() -> (x,y)""" return _controls.PyControl_base_DoGetPosition(*args, **kwargs) def base_DoGetVirtualSize(*args, **kwargs): diff --git a/wxPython/src/gtk/core.py b/wxPython/src/gtk/core.py index 13171a3b9e..20a8174624 100644 --- a/wxPython/src/gtk/core.py +++ b/wxPython/src/gtk/core.py @@ -7611,16 +7611,13 @@ _core.LayoutConstraints_swigregister(LayoutConstraintsPtr) #---------------------------------------------------------------------------- -# Use Python's bool constants if available, make aliases if not +# Use Python's bool constants if available, make some if not try: True except NameError: - True = 1==1 - False = 1==0 + __builtins__.True = 1==1 + __builtins__.False = 1==0 -# Backwards compaatibility -TRUE = true = True -FALSE = false = False # workarounds for bad wxRTTI names diff --git a/wxPython/src/gtk/gdi.py b/wxPython/src/gtk/gdi.py index aad2e7559a..12c7400274 100644 --- a/wxPython/src/gtk/gdi.py +++ b/wxPython/src/gtk/gdi.py @@ -146,13 +146,14 @@ class Palette(GDIObject): return _gdi.Palette_GetPixel(*args, **kwargs) def GetRGB(*args, **kwargs): - """GetRGB(int pixel, byte OUTPUT, byte OUTPUT, byte OUTPUT) -> bool""" + """GetRGB(int pixel) -> (R,G,B)""" return _gdi.Palette_GetRGB(*args, **kwargs) def Ok(*args, **kwargs): """Ok() -> bool""" return _gdi.Palette_Ok(*args, **kwargs) + def __nonzero__(self): return self.Ok() class PalettePtr(Palette): def __init__(self, this): @@ -2231,7 +2232,7 @@ class DC(core.Object): return _gdi.DC_DestroyClippingRegion(*args, **kwargs) def GetClippingBox(*args, **kwargs): - """GetClippingBox(int OUTPUT, int OUTPUT, int OUTPUT, int OUTPUT)""" + """GetClippingBox() -> (x, y, width, height)""" return _gdi.DC_GetClippingBox(*args, **kwargs) def GetClippingRect(*args, **kwargs): @@ -2247,35 +2248,52 @@ class DC(core.Object): return _gdi.DC_GetCharWidth(*args, **kwargs) def GetTextExtent(*args, **kwargs): - """GetTextExtent(wxString string, int OUTPUT, int OUTPUT)""" + """GetTextExtent(wxString string) -> (width, height) + +Get the width and height of the text using the current font. +Only works for single line strings.""" return _gdi.DC_GetTextExtent(*args, **kwargs) def GetFullTextExtent(*args, **kwargs): - """GetFullTextExtent(wxString string, int OUTPUT, int OUTPUT, int OUTPUT, - int OUTPUT, Font font=None)""" + """GetFullTextExtent(wxString string, Font font=None) -> + (width, height, descent, externalLeading) + +Get the width, height, decent and leading of the text using the current or specified font. +Only works for single line strings.""" return _gdi.DC_GetFullTextExtent(*args, **kwargs) def GetMultiLineTextExtent(*args, **kwargs): - """GetMultiLineTextExtent(wxString text, int OUTPUT, int OUTPUT, int OUTPUT, - Font font=None)""" - return _gdi.DC_GetMultiLineTextExtent(*args, **kwargs) + """GetMultiLineTextExtent(wxString string, Font font=None) -> + (width, height, descent, externalLeading) - def GetSizeTuple(*args, **kwargs): - """GetSizeTuple(int OUTPUT, int OUTPUT)""" - return _gdi.DC_GetSizeTuple(*args, **kwargs) +Get the width, height, decent and leading of the text using the current or specified font. +Works for single as well as multi-line strings.""" + return _gdi.DC_GetMultiLineTextExtent(*args, **kwargs) def GetSize(*args, **kwargs): - """GetSize() -> Size""" + """GetSize() -> Size + +Get the DC size in device units.""" return _gdi.DC_GetSize(*args, **kwargs) - def GetSizeMMWH(*args, **kwargs): - """GetSizeMMWH(int OUTPUT, int OUTPUT)""" - return _gdi.DC_GetSizeMMWH(*args, **kwargs) + def GetSizeTuple(*args, **kwargs): + """GetSizeTuple() -> (width, height) + +Get the DC size in device units.""" + return _gdi.DC_GetSizeTuple(*args, **kwargs) def GetSizeMM(*args, **kwargs): - """GetSizeMM() -> Size""" + """GetSizeMM() -> Size + +Get the DC size in milimeters.""" return _gdi.DC_GetSizeMM(*args, **kwargs) + def GetSizeMMTuple(*args, **kwargs): + """GetSizeMMTuple() -> (width, height) + +Get the DC size in milimeters.""" + return _gdi.DC_GetSizeMMTuple(*args, **kwargs) + def DeviceToLogicalX(*args, **kwargs): """DeviceToLogicalX(int x) -> int""" return _gdi.DC_DeviceToLogicalX(*args, **kwargs) @@ -2373,7 +2391,7 @@ class DC(core.Object): return _gdi.DC_SetMapMode(*args, **kwargs) def GetUserScale(*args, **kwargs): - """GetUserScale(double OUTPUT, double OUTPUT)""" + """GetUserScale() -> (xScale, yScale)""" return _gdi.DC_GetUserScale(*args, **kwargs) def SetUserScale(*args, **kwargs): @@ -2381,33 +2399,33 @@ class DC(core.Object): return _gdi.DC_SetUserScale(*args, **kwargs) def GetLogicalScale(*args, **kwargs): - """GetLogicalScale(double OUTPUT, double OUTPUT)""" + """GetLogicalScale() -> (xScale, yScale)""" return _gdi.DC_GetLogicalScale(*args, **kwargs) def SetLogicalScale(*args, **kwargs): """SetLogicalScale(double x, double y)""" return _gdi.DC_SetLogicalScale(*args, **kwargs) - def GetLogicalOriginTuple(*args, **kwargs): - """GetLogicalOriginTuple(int OUTPUT, int OUTPUT)""" - return _gdi.DC_GetLogicalOriginTuple(*args, **kwargs) - def GetLogicalOrigin(*args, **kwargs): """GetLogicalOrigin() -> Point""" return _gdi.DC_GetLogicalOrigin(*args, **kwargs) + def GetLogicalOriginTuple(*args, **kwargs): + """GetLogicalOriginTuple() -> (x,y)""" + return _gdi.DC_GetLogicalOriginTuple(*args, **kwargs) + def SetLogicalOrigin(*args, **kwargs): """SetLogicalOrigin(int x, int y)""" return _gdi.DC_SetLogicalOrigin(*args, **kwargs) - def GetDeviceOriginTuple(*args, **kwargs): - """GetDeviceOriginTuple(int OUTPUT, int OUTPUT)""" - return _gdi.DC_GetDeviceOriginTuple(*args, **kwargs) - def GetDeviceOrigin(*args, **kwargs): """GetDeviceOrigin() -> Point""" return _gdi.DC_GetDeviceOrigin(*args, **kwargs) + def GetDeviceOriginTuple(*args, **kwargs): + """GetDeviceOriginTuple() -> (x,y)""" + return _gdi.DC_GetDeviceOriginTuple(*args, **kwargs) + def SetDeviceOrigin(*args, **kwargs): """SetDeviceOrigin(int x, int y)""" return _gdi.DC_SetDeviceOrigin(*args, **kwargs) @@ -2457,7 +2475,7 @@ class DC(core.Object): return _gdi.DC_MaxY(*args, **kwargs) def GetBoundingBox(*args, **kwargs): - """GetBoundingBox(int OUTPUT, int OUTPUT, int OUTPUT, int OUTPUT)""" + """GetBoundingBox() -> (x1,y1, x2,y2)""" return _gdi.DC_GetBoundingBox(*args, **kwargs) def __nonzero__(self): return self.Ok() @@ -2941,7 +2959,7 @@ class ImageList(core.Object): return _gdi.ImageList_RemoveAll(*args, **kwargs) def GetSize(*args, **kwargs): - """GetSize(int index, int OUTPUT, int OUTPUT)""" + """GetSize() -> (width,height)""" return _gdi.ImageList_GetSize(*args, **kwargs) diff --git a/wxPython/src/gtk/gdi_wrap.cpp b/wxPython/src/gtk/gdi_wrap.cpp index fcb628f61b..6919c62253 100644 --- a/wxPython/src/gtk/gdi_wrap.cpp +++ b/wxPython/src/gtk/gdi_wrap.cpp @@ -11276,6 +11276,35 @@ static PyObject *_wrap_DC_GetMultiLineTextExtent(PyObject *self, PyObject *args, } +static PyObject *_wrap_DC_GetSize(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject *resultobj; + wxDC *arg1 = (wxDC *) 0 ; + wxSize result; + PyObject * obj0 = 0 ; + char *kwnames[] = { + (char *) "self", NULL + }; + + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetSize",kwnames,&obj0)) goto fail; + if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; + { + PyThreadState* __tstate = wxPyBeginAllowThreads(); + result = (arg1)->GetSize(); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) SWIG_fail; + } + { + wxSize * resultptr; + resultptr = new wxSize((wxSize &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxSize, 1); + } + return resultobj; + fail: + return NULL; +} + + static PyObject *_wrap_DC_GetSizeTuple(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; @@ -11314,7 +11343,7 @@ static PyObject *_wrap_DC_GetSizeTuple(PyObject *self, PyObject *args, PyObject } -static PyObject *_wrap_DC_GetSize(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_DC_GetSizeMM(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; wxSize result; @@ -11323,11 +11352,11 @@ static PyObject *_wrap_DC_GetSize(PyObject *self, PyObject *args, PyObject *kwar (char *) "self", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetSize",kwnames,&obj0)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetSizeMM",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (arg1)->GetSize(); + result = ((wxDC const *)arg1)->GetSizeMM(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -11343,7 +11372,7 @@ static PyObject *_wrap_DC_GetSize(PyObject *self, PyObject *args, PyObject *kwar } -static PyObject *_wrap_DC_GetSizeMMWH(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_DC_GetSizeMMTuple(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; int *arg2 = (int *) 0 ; @@ -11357,7 +11386,7 @@ static PyObject *_wrap_DC_GetSizeMMWH(PyObject *self, PyObject *args, PyObject * arg2 = &temp2; arg3 = &temp3; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetSizeMMWH",kwnames,&obj0)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetSizeMMTuple",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); @@ -11381,35 +11410,6 @@ static PyObject *_wrap_DC_GetSizeMMWH(PyObject *self, PyObject *args, PyObject * } -static PyObject *_wrap_DC_GetSizeMM(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject *resultobj; - wxDC *arg1 = (wxDC *) 0 ; - wxSize result; - PyObject * obj0 = 0 ; - char *kwnames[] = { - (char *) "self", NULL - }; - - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetSizeMM",kwnames,&obj0)) goto fail; - if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - { - PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = ((wxDC const *)arg1)->GetSizeMM(); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) SWIG_fail; - } - { - wxSize * resultptr; - resultptr = new wxSize((wxSize &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxSize, 1); - } - return resultobj; - fail: - return NULL; -} - - static PyObject *_wrap_DC_DeviceToLogicalX(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; @@ -12180,37 +12180,28 @@ static PyObject *_wrap_DC_SetLogicalScale(PyObject *self, PyObject *args, PyObje } -static PyObject *_wrap_DC_GetLogicalOriginTuple(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_DC_GetLogicalOrigin(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; - int *arg2 = (int *) 0 ; - int *arg3 = (int *) 0 ; - int temp2 ; - int temp3 ; + wxPoint result; PyObject * obj0 = 0 ; char *kwnames[] = { (char *) "self", NULL }; - arg2 = &temp2; - arg3 = &temp3; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetLogicalOriginTuple",kwnames,&obj0)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetLogicalOrigin",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - ((wxDC const *)arg1)->GetLogicalOrigin(arg2,arg3); + result = ((wxDC const *)arg1)->GetLogicalOrigin(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } - Py_INCREF(Py_None); resultobj = Py_None; - { - PyObject *o = PyInt_FromLong((long) (*arg2)); - resultobj = t_output_helper(resultobj,o); - } { - PyObject *o = PyInt_FromLong((long) (*arg3)); - resultobj = t_output_helper(resultobj,o); + wxPoint * resultptr; + resultptr = new wxPoint((wxPoint &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); } return resultobj; fail: @@ -12218,28 +12209,37 @@ static PyObject *_wrap_DC_GetLogicalOriginTuple(PyObject *self, PyObject *args, } -static PyObject *_wrap_DC_GetLogicalOrigin(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_DC_GetLogicalOriginTuple(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; - wxPoint result; + int *arg2 = (int *) 0 ; + int *arg3 = (int *) 0 ; + int temp2 ; + int temp3 ; PyObject * obj0 = 0 ; char *kwnames[] = { (char *) "self", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetLogicalOrigin",kwnames,&obj0)) goto fail; + arg2 = &temp2; + arg3 = &temp3; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetLogicalOriginTuple",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = ((wxDC const *)arg1)->GetLogicalOrigin(); + ((wxDC const *)arg1)->GetLogicalOrigin(arg2,arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } + Py_INCREF(Py_None); resultobj = Py_None; { - wxPoint * resultptr; - resultptr = new wxPoint((wxPoint &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); + PyObject *o = PyInt_FromLong((long) (*arg2)); + resultobj = t_output_helper(resultobj,o); + } + { + PyObject *o = PyInt_FromLong((long) (*arg3)); + resultobj = t_output_helper(resultobj,o); } return resultobj; fail: @@ -12273,37 +12273,28 @@ static PyObject *_wrap_DC_SetLogicalOrigin(PyObject *self, PyObject *args, PyObj } -static PyObject *_wrap_DC_GetDeviceOriginTuple(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_DC_GetDeviceOrigin(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; - int *arg2 = (int *) 0 ; - int *arg3 = (int *) 0 ; - int temp2 ; - int temp3 ; + wxPoint result; PyObject * obj0 = 0 ; char *kwnames[] = { (char *) "self", NULL }; - arg2 = &temp2; - arg3 = &temp3; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetDeviceOriginTuple",kwnames,&obj0)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetDeviceOrigin",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - ((wxDC const *)arg1)->GetDeviceOrigin(arg2,arg3); + result = ((wxDC const *)arg1)->GetDeviceOrigin(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } - Py_INCREF(Py_None); resultobj = Py_None; - { - PyObject *o = PyInt_FromLong((long) (*arg2)); - resultobj = t_output_helper(resultobj,o); - } { - PyObject *o = PyInt_FromLong((long) (*arg3)); - resultobj = t_output_helper(resultobj,o); + wxPoint * resultptr; + resultptr = new wxPoint((wxPoint &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); } return resultobj; fail: @@ -12311,28 +12302,37 @@ static PyObject *_wrap_DC_GetDeviceOriginTuple(PyObject *self, PyObject *args, P } -static PyObject *_wrap_DC_GetDeviceOrigin(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_DC_GetDeviceOriginTuple(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDC *arg1 = (wxDC *) 0 ; - wxPoint result; + int *arg2 = (int *) 0 ; + int *arg3 = (int *) 0 ; + int temp2 ; + int temp3 ; PyObject * obj0 = 0 ; char *kwnames[] = { (char *) "self", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetDeviceOrigin",kwnames,&obj0)) goto fail; + arg2 = &temp2; + arg3 = &temp3; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:DC_GetDeviceOriginTuple",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDC,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = ((wxDC const *)arg1)->GetDeviceOrigin(); + ((wxDC const *)arg1)->GetDeviceOrigin(arg2,arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } + Py_INCREF(Py_None); resultobj = Py_None; { - wxPoint * resultptr; - resultptr = new wxPoint((wxPoint &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); + PyObject *o = PyInt_FromLong((long) (*arg2)); + resultobj = t_output_helper(resultobj,o); + } + { + PyObject *o = PyInt_FromLong((long) (*arg3)); + resultobj = t_output_helper(resultobj,o); } return resultobj; fail: @@ -16114,10 +16114,10 @@ static PyMethodDef SwigMethods[] = { { (char *)"DC_GetTextExtent", (PyCFunction) _wrap_DC_GetTextExtent, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetFullTextExtent", (PyCFunction) _wrap_DC_GetFullTextExtent, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetMultiLineTextExtent", (PyCFunction) _wrap_DC_GetMultiLineTextExtent, METH_VARARGS | METH_KEYWORDS }, - { (char *)"DC_GetSizeTuple", (PyCFunction) _wrap_DC_GetSizeTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetSize", (PyCFunction) _wrap_DC_GetSize, METH_VARARGS | METH_KEYWORDS }, - { (char *)"DC_GetSizeMMWH", (PyCFunction) _wrap_DC_GetSizeMMWH, METH_VARARGS | METH_KEYWORDS }, + { (char *)"DC_GetSizeTuple", (PyCFunction) _wrap_DC_GetSizeTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetSizeMM", (PyCFunction) _wrap_DC_GetSizeMM, METH_VARARGS | METH_KEYWORDS }, + { (char *)"DC_GetSizeMMTuple", (PyCFunction) _wrap_DC_GetSizeMMTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_DeviceToLogicalX", (PyCFunction) _wrap_DC_DeviceToLogicalX, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_DeviceToLogicalY", (PyCFunction) _wrap_DC_DeviceToLogicalY, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_DeviceToLogicalXRel", (PyCFunction) _wrap_DC_DeviceToLogicalXRel, METH_VARARGS | METH_KEYWORDS }, @@ -16146,11 +16146,11 @@ static PyMethodDef SwigMethods[] = { { (char *)"DC_SetUserScale", (PyCFunction) _wrap_DC_SetUserScale, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetLogicalScale", (PyCFunction) _wrap_DC_GetLogicalScale, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_SetLogicalScale", (PyCFunction) _wrap_DC_SetLogicalScale, METH_VARARGS | METH_KEYWORDS }, - { (char *)"DC_GetLogicalOriginTuple", (PyCFunction) _wrap_DC_GetLogicalOriginTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetLogicalOrigin", (PyCFunction) _wrap_DC_GetLogicalOrigin, METH_VARARGS | METH_KEYWORDS }, + { (char *)"DC_GetLogicalOriginTuple", (PyCFunction) _wrap_DC_GetLogicalOriginTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_SetLogicalOrigin", (PyCFunction) _wrap_DC_SetLogicalOrigin, METH_VARARGS | METH_KEYWORDS }, - { (char *)"DC_GetDeviceOriginTuple", (PyCFunction) _wrap_DC_GetDeviceOriginTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetDeviceOrigin", (PyCFunction) _wrap_DC_GetDeviceOrigin, METH_VARARGS | METH_KEYWORDS }, + { (char *)"DC_GetDeviceOriginTuple", (PyCFunction) _wrap_DC_GetDeviceOriginTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_SetDeviceOrigin", (PyCFunction) _wrap_DC_SetDeviceOrigin, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_SetAxisOrientation", (PyCFunction) _wrap_DC_SetAxisOrientation, METH_VARARGS | METH_KEYWORDS }, { (char *)"DC_GetLogicalFunction", (PyCFunction) _wrap_DC_GetLogicalFunction, METH_VARARGS | METH_KEYWORDS }, diff --git a/wxPython/src/gtk/grid.py b/wxPython/src/gtk/grid.py index 87fe1a39d6..0044eaea6f 100644 --- a/wxPython/src/gtk/grid.py +++ b/wxPython/src/gtk/grid.py @@ -696,11 +696,11 @@ class GridCellAttr(object): return _grid.GridCellAttr_GetFont(*args, **kwargs) def GetAlignment(*args, **kwargs): - """GetAlignment(int OUTPUT, int OUTPUT)""" + """GetAlignment() -> (hAlign, vAlign)""" return _grid.GridCellAttr_GetAlignment(*args, **kwargs) def GetSize(*args, **kwargs): - """GetSize(int OUTPUT, int OUTPUT)""" + """GetSize() -> (num_rows, num_cols)""" return _grid.GridCellAttr_GetSize(*args, **kwargs) def GetOverflow(*args, **kwargs): @@ -1314,7 +1314,7 @@ class Grid(windows.ScrolledWindow): return _grid.Grid_DrawTextRectangle(*args, **kwargs) def GetTextBoxSize(*args, **kwargs): - """GetTextBoxSize(wxDC dc, wxArrayString lines, long OUTPUT, long OUTPUT)""" + """GetTextBoxSize(DC dc, list lines) -> (width, height)""" return _grid.Grid_GetTextBoxSize(*args, **kwargs) def BeginBatch(*args, **kwargs): @@ -1494,11 +1494,11 @@ class Grid(windows.ScrolledWindow): return _grid.Grid_GetLabelFont(*args, **kwargs) def GetRowLabelAlignment(*args, **kwargs): - """GetRowLabelAlignment(int OUTPUT, int OUTPUT)""" + """GetRowLabelAlignment() -> (horiz, vert)""" return _grid.Grid_GetRowLabelAlignment(*args, **kwargs) def GetColLabelAlignment(*args, **kwargs): - """GetColLabelAlignment(int OUTPUT, int OUTPUT)""" + """GetColLabelAlignment() -> (horiz, vert)""" return _grid.Grid_GetColLabelAlignment(*args, **kwargs) def GetColLabelTextOrientation(*args, **kwargs): @@ -1698,11 +1698,11 @@ class Grid(windows.ScrolledWindow): return _grid.Grid_GetCellFont(*args, **kwargs) def GetDefaultCellAlignment(*args, **kwargs): - """GetDefaultCellAlignment(int OUTPUT, int OUTPUT)""" + """GetDefaultCellAlignment() -> (horiz, vert)""" return _grid.Grid_GetDefaultCellAlignment(*args, **kwargs) def GetCellAlignment(*args, **kwargs): - """GetCellAlignment(int row, int col, int OUTPUT, int OUTPUT)""" + """GetCellAlignment() -> (horiz, vert)""" return _grid.Grid_GetCellAlignment(*args, **kwargs) def GetDefaultCellOverflow(*args, **kwargs): @@ -1714,7 +1714,7 @@ class Grid(windows.ScrolledWindow): return _grid.Grid_GetCellOverflow(*args, **kwargs) def GetCellSize(*args, **kwargs): - """GetCellSize(int row, int col, int OUTPUT, int OUTPUT)""" + """GetCellSize(int row, int col) -> (num_rows, num_cols)""" return _grid.Grid_GetCellSize(*args, **kwargs) def SetDefaultRowSize(*args, **kwargs): diff --git a/wxPython/src/gtk/misc.py b/wxPython/src/gtk/misc.py index 0a4320709c..4248ed8d01 100644 --- a/wxPython/src/gtk/misc.py +++ b/wxPython/src/gtk/misc.py @@ -256,7 +256,7 @@ def GetElapsedTime(*args, **kwargs): return _misc.GetElapsedTime(*args, **kwargs) def GetMousePosition(*args, **kwargs): - """GetMousePosition(int OUTPUT, int OUTPUT)""" + """GetMousePosition() -> (x,y)""" return _misc.GetMousePosition(*args, **kwargs) def IsBusy(*args, **kwargs): @@ -276,7 +276,7 @@ def StartTimer(*args, **kwargs): return _misc.StartTimer(*args, **kwargs) def GetOsVersion(*args, **kwargs): - """GetOsVersion(int OUTPUT, int OUTPUT) -> int""" + """GetOsVersion() -> (platform, major, minor)""" return _misc.GetOsVersion(*args, **kwargs) def GetOsDescription(*args, **kwargs): @@ -420,7 +420,7 @@ def GetDisplayDepth(*args, **kwargs): return _misc.GetDisplayDepth(*args, **kwargs) def DisplaySize(*args, **kwargs): - """DisplaySize(int OUTPUT, int OUTPUT)""" + """DisplaySize() -> (width, height)""" return _misc.DisplaySize(*args, **kwargs) def GetDisplaySize(*args, **kwargs): @@ -428,7 +428,7 @@ def GetDisplaySize(*args, **kwargs): return _misc.GetDisplaySize(*args, **kwargs) def DisplaySizeMM(*args, **kwargs): - """DisplaySizeMM(int OUTPUT, int OUTPUT)""" + """DisplaySizeMM() -> (width, height)""" return _misc.DisplaySizeMM(*args, **kwargs) def GetDisplaySizeMM(*args, **kwargs): @@ -436,7 +436,7 @@ def GetDisplaySizeMM(*args, **kwargs): return _misc.GetDisplaySizeMM(*args, **kwargs) def ClientDisplayRect(*args, **kwargs): - """ClientDisplayRect(int OUTPUT, int OUTPUT, int OUTPUT, int OUTPUT)""" + """ClientDisplayRect() -> (x, y, width, height)""" return _misc.ClientDisplayRect(*args, **kwargs) def GetClientDisplayRect(*args, **kwargs): @@ -580,22 +580,22 @@ class Caret(object): """IsVisible() -> bool""" return _misc.Caret_IsVisible(*args, **kwargs) - def GetPositionTuple(*args, **kwargs): - """GetPositionTuple(int OUTPUT, int OUTPUT)""" - return _misc.Caret_GetPositionTuple(*args, **kwargs) - def GetPosition(*args, **kwargs): """GetPosition() -> Point""" return _misc.Caret_GetPosition(*args, **kwargs) - def GetSizeTuple(*args, **kwargs): - """GetSizeTuple(int OUTPUT, int OUTPUT)""" - return _misc.Caret_GetSizeTuple(*args, **kwargs) + def GetPositionTuple(*args, **kwargs): + """GetPositionTuple() -> (x,y)""" + return _misc.Caret_GetPositionTuple(*args, **kwargs) def GetSize(*args, **kwargs): """GetSize() -> Size""" return _misc.Caret_GetSize(*args, **kwargs) + def GetSizeTuple(*args, **kwargs): + """GetSizeTuple() -> (width, height)""" + return _misc.Caret_GetSizeTuple(*args, **kwargs) + def GetWindow(*args, **kwargs): """GetWindow() -> Window""" return _misc.Caret_GetWindow(*args, **kwargs) @@ -624,6 +624,7 @@ class Caret(object): """Hide()""" return _misc.Caret_Hide(*args, **kwargs) + def __nonzero__(self): return self.IsOk() class CaretPtr(Caret): def __init__(self, this): @@ -2902,12 +2903,12 @@ class DateTime(object): GetCentury = staticmethod(GetCentury) def GetNumberOfDaysinYear(*args, **kwargs): - """DateTime.GetNumberOfDaysinYear(int year, wxDateTime::Calendar cal=Gregorian) -> wxDateTime_t""" + """DateTime.GetNumberOfDaysinYear(int year, wxDateTime::Calendar cal=Gregorian) -> int""" return _misc.DateTime_GetNumberOfDaysinYear(*args, **kwargs) GetNumberOfDaysinYear = staticmethod(GetNumberOfDaysinYear) def GetNumberOfDaysInMonth(*args, **kwargs): - """DateTime.GetNumberOfDaysInMonth(wxDateTime::Month month, int year=Inv_Year, wxDateTime::Calendar cal=Gregorian) -> wxDateTime_t""" + """DateTime.GetNumberOfDaysInMonth(wxDateTime::Month month, int year=Inv_Year, wxDateTime::Calendar cal=Gregorian) -> int""" return _misc.DateTime_GetNumberOfDaysInMonth(*args, **kwargs) GetNumberOfDaysInMonth = staticmethod(GetNumberOfDaysInMonth) @@ -2922,7 +2923,9 @@ class DateTime(object): GetWeekDayName = staticmethod(GetWeekDayName) def GetAmPmStrings(*args, **kwargs): - """DateTime.GetAmPmStrings(wxString OUTPUT, wxString OUTPUT)""" + """GetAmPmStrings() -> (am, pm) + +Get the AM and PM strings in the current locale (may be empty)""" return _misc.DateTime_GetAmPmStrings(*args, **kwargs) GetAmPmStrings = staticmethod(GetAmPmStrings) @@ -2981,14 +2984,13 @@ class DateTime(object): return _misc.DateTime_SetJDN(*args, **kwargs) def SetHMS(*args, **kwargs): - """SetHMS(wxDateTime_t hour, wxDateTime_t minute=0, wxDateTime_t second=0, - wxDateTime_t millisec=0) -> DateTime""" + """SetHMS(int hour, int minute=0, int second=0, int millisec=0) -> DateTime""" return _misc.DateTime_SetHMS(*args, **kwargs) def Set(*args, **kwargs): - """Set(wxDateTime_t day, wxDateTime::Month month=Inv_Month, - int year=Inv_Year, wxDateTime_t hour=0, wxDateTime_t minute=0, - wxDateTime_t second=0, wxDateTime_t millisec=0) -> DateTime""" + """Set(int day, wxDateTime::Month month=Inv_Month, int year=Inv_Year, + int hour=0, int minute=0, int second=0, + int millisec=0) -> DateTime""" return _misc.DateTime_Set(*args, **kwargs) def ResetTime(*args, **kwargs): @@ -3004,23 +3006,23 @@ class DateTime(object): return _misc.DateTime_SetMonth(*args, **kwargs) def SetDay(*args, **kwargs): - """SetDay(wxDateTime_t day) -> DateTime""" + """SetDay(int day) -> DateTime""" return _misc.DateTime_SetDay(*args, **kwargs) def SetHour(*args, **kwargs): - """SetHour(wxDateTime_t hour) -> DateTime""" + """SetHour(int hour) -> DateTime""" return _misc.DateTime_SetHour(*args, **kwargs) def SetMinute(*args, **kwargs): - """SetMinute(wxDateTime_t minute) -> DateTime""" + """SetMinute(int minute) -> DateTime""" return _misc.DateTime_SetMinute(*args, **kwargs) def SetSecond(*args, **kwargs): - """SetSecond(wxDateTime_t second) -> DateTime""" + """SetSecond(int second) -> DateTime""" return _misc.DateTime_SetSecond(*args, **kwargs) def SetMillisecond(*args, **kwargs): - """SetMillisecond(wxDateTime_t millisecond) -> DateTime""" + """SetMillisecond(int millisecond) -> DateTime""" return _misc.DateTime_SetMillisecond(*args, **kwargs) def SetToWeekDayInSameWeek(*args, **kwargs): @@ -3063,13 +3065,11 @@ class DateTime(object): return _misc.DateTime_GetLastWeekDay(*args, **kwargs) def SetToTheWeek(*args, **kwargs): - """SetToTheWeek(wxDateTime_t numWeek, wxDateTime::WeekDay weekday=Mon, - wxDateTime::WeekFlags flags=Monday_First) -> bool""" + """SetToTheWeek(int numWeek, wxDateTime::WeekDay weekday=Mon, wxDateTime::WeekFlags flags=Monday_First) -> bool""" return _misc.DateTime_SetToTheWeek(*args, **kwargs) def GetWeek(*args, **kwargs): - """GetWeek(wxDateTime_t numWeek, wxDateTime::WeekDay weekday=Mon, - wxDateTime::WeekFlags flags=Monday_First) -> DateTime""" + """GetWeek(int numWeek, wxDateTime::WeekDay weekday=Mon, wxDateTime::WeekFlags flags=Monday_First) -> DateTime""" return _misc.DateTime_GetWeek(*args, **kwargs) def SetToLastMonthDay(*args, **kwargs): @@ -3081,11 +3081,11 @@ class DateTime(object): return _misc.DateTime_GetLastMonthDay(*args, **kwargs) def SetToYearDay(*args, **kwargs): - """SetToYearDay(wxDateTime_t yday) -> DateTime""" + """SetToYearDay(int yday) -> DateTime""" return _misc.DateTime_SetToYearDay(*args, **kwargs) def GetYearDay(*args, **kwargs): - """GetYearDay(wxDateTime_t yday) -> DateTime""" + """GetYearDay(int yday) -> DateTime""" return _misc.DateTime_GetYearDay(*args, **kwargs) def GetJulianDayNumber(*args, **kwargs): @@ -3145,7 +3145,7 @@ class DateTime(object): return _misc.DateTime_GetMonth(*args, **kwargs) def GetDay(*args, **kwargs): - """GetDay(wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetDay(wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetDay(*args, **kwargs) def GetWeekDay(*args, **kwargs): @@ -3153,31 +3153,31 @@ class DateTime(object): return _misc.DateTime_GetWeekDay(*args, **kwargs) def GetHour(*args, **kwargs): - """GetHour(wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetHour(wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetHour(*args, **kwargs) def GetMinute(*args, **kwargs): - """GetMinute(wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetMinute(wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetMinute(*args, **kwargs) def GetSecond(*args, **kwargs): - """GetSecond(wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetSecond(wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetSecond(*args, **kwargs) def GetMillisecond(*args, **kwargs): - """GetMillisecond(wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetMillisecond(wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetMillisecond(*args, **kwargs) def GetDayOfYear(*args, **kwargs): - """GetDayOfYear(wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetDayOfYear(wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetDayOfYear(*args, **kwargs) def GetWeekOfYear(*args, **kwargs): - """GetWeekOfYear(wxDateTime::WeekFlags flags=Monday_First, wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetWeekOfYear(wxDateTime::WeekFlags flags=Monday_First, wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetWeekOfYear(*args, **kwargs) def GetWeekOfMonth(*args, **kwargs): - """GetWeekOfMonth(wxDateTime::WeekFlags flags=Monday_First, wxDateTime::TimeZone tz=LOCAL_TZ) -> wxDateTime_t""" + """GetWeekOfMonth(wxDateTime::WeekFlags flags=Monday_First, wxDateTime::TimeZone tz=LOCAL_TZ) -> int""" return _misc.DateTime_GetWeekOfMonth(*args, **kwargs) def IsWorkDay(*args, **kwargs): @@ -3367,11 +3367,11 @@ def DateTime_GetCentury(*args, **kwargs): return _misc.DateTime_GetCentury(*args, **kwargs) def DateTime_GetNumberOfDaysinYear(*args, **kwargs): - """DateTime_GetNumberOfDaysinYear(int year, wxDateTime::Calendar cal=Gregorian) -> wxDateTime_t""" + """DateTime_GetNumberOfDaysinYear(int year, wxDateTime::Calendar cal=Gregorian) -> int""" return _misc.DateTime_GetNumberOfDaysinYear(*args, **kwargs) def DateTime_GetNumberOfDaysInMonth(*args, **kwargs): - """DateTime_GetNumberOfDaysInMonth(wxDateTime::Month month, int year=Inv_Year, wxDateTime::Calendar cal=Gregorian) -> wxDateTime_t""" + """DateTime_GetNumberOfDaysInMonth(wxDateTime::Month month, int year=Inv_Year, wxDateTime::Calendar cal=Gregorian) -> int""" return _misc.DateTime_GetNumberOfDaysInMonth(*args, **kwargs) def DateTime_GetMonthName(*args, **kwargs): @@ -3383,7 +3383,9 @@ def DateTime_GetWeekDayName(*args, **kwargs): return _misc.DateTime_GetWeekDayName(*args, **kwargs) def DateTime_GetAmPmStrings(*args, **kwargs): - """DateTime_GetAmPmStrings(wxString OUTPUT, wxString OUTPUT)""" + """GetAmPmStrings() -> (am, pm) + +Get the AM and PM strings in the current locale (may be empty)""" return _misc.DateTime_GetAmPmStrings(*args, **kwargs) def DateTime_IsDSTApplicable(*args, **kwargs): @@ -3423,16 +3425,15 @@ def DateTimeFromJDN(*args, **kwargs): return val def DateTimeFromHMS(*args, **kwargs): - """DateTimeFromHMS(wxDateTime_t hour, wxDateTime_t minute=0, wxDateTime_t second=0, - wxDateTime_t millisec=0) -> DateTime""" + """DateTimeFromHMS(int hour, int minute=0, int second=0, int millisec=0) -> DateTime""" val = _misc.new_DateTimeFromHMS(*args, **kwargs) val.thisown = 1 return val def DateTimeFromDMY(*args, **kwargs): - """DateTimeFromDMY(wxDateTime_t day, wxDateTime::Month month=Inv_Month, - int year=Inv_Year, wxDateTime_t hour=0, wxDateTime_t minute=0, - wxDateTime_t second=0, wxDateTime_t millisec=0) -> DateTime""" + """DateTimeFromDMY(int day, wxDateTime::Month month=Inv_Month, int year=Inv_Year, + int hour=0, int minute=0, int second=0, + int millisec=0) -> DateTime""" val = _misc.new_DateTimeFromDMY(*args, **kwargs) val.thisown = 1 return val diff --git a/wxPython/src/gtk/misc_wrap.cpp b/wxPython/src/gtk/misc_wrap.cpp index 59421939e1..accb86b78f 100644 --- a/wxPython/src/gtk/misc_wrap.cpp +++ b/wxPython/src/gtk/misc_wrap.cpp @@ -4102,6 +4102,35 @@ static PyObject *_wrap_Caret_IsVisible(PyObject *self, PyObject *args, PyObject } +static PyObject *_wrap_Caret_GetPosition(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject *resultobj; + wxCaret *arg1 = (wxCaret *) 0 ; + wxPoint result; + PyObject * obj0 = 0 ; + char *kwnames[] = { + (char *) "self", NULL + }; + + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Caret_GetPosition",kwnames,&obj0)) goto fail; + if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxCaret,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; + { + PyThreadState* __tstate = wxPyBeginAllowThreads(); + result = (arg1)->GetPosition(); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) SWIG_fail; + } + { + wxPoint * resultptr; + resultptr = new wxPoint((wxPoint &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); + } + return resultobj; + fail: + return NULL; +} + + static PyObject *_wrap_Caret_GetPositionTuple(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxCaret *arg1 = (wxCaret *) 0 ; @@ -4140,28 +4169,28 @@ static PyObject *_wrap_Caret_GetPositionTuple(PyObject *self, PyObject *args, Py } -static PyObject *_wrap_Caret_GetPosition(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_Caret_GetSize(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxCaret *arg1 = (wxCaret *) 0 ; - wxPoint result; + wxSize result; PyObject * obj0 = 0 ; char *kwnames[] = { (char *) "self", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Caret_GetPosition",kwnames,&obj0)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Caret_GetSize",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxCaret,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (arg1)->GetPosition(); + result = (arg1)->GetSize(); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } { - wxPoint * resultptr; - resultptr = new wxPoint((wxPoint &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); + wxSize * resultptr; + resultptr = new wxSize((wxSize &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxSize, 1); } return resultobj; fail: @@ -4207,35 +4236,6 @@ static PyObject *_wrap_Caret_GetSizeTuple(PyObject *self, PyObject *args, PyObje } -static PyObject *_wrap_Caret_GetSize(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject *resultobj; - wxCaret *arg1 = (wxCaret *) 0 ; - wxSize result; - PyObject * obj0 = 0 ; - char *kwnames[] = { - (char *) "self", NULL - }; - - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Caret_GetSize",kwnames,&obj0)) goto fail; - if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxCaret,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - { - PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (arg1)->GetSize(); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) SWIG_fail; - } - { - wxSize * resultptr; - resultptr = new wxSize((wxSize &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxSize, 1); - } - return resultobj; - fail: - return NULL; -} - - static PyObject *_wrap_Caret_GetWindow(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxCaret *arg1 = (wxCaret *) 0 ; @@ -15267,7 +15267,7 @@ static PyObject *_wrap_DateTime_GetNumberOfDaysinYear(PyObject *self, PyObject * PyObject *resultobj; int arg1 ; int arg2 = (int) wxDateTime::Gregorian ; - wxDateTime::wxDateTime_t result; + int result; char *kwnames[] = { (char *) "year",(char *) "cal", NULL }; @@ -15275,7 +15275,7 @@ static PyObject *_wrap_DateTime_GetNumberOfDaysinYear(PyObject *self, PyObject * if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"i|i:DateTime_GetNumberOfDaysinYear",kwnames,&arg1,&arg2)) goto fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)wxDateTime::GetNumberOfDays(arg1,(wxDateTime::Calendar )arg2); + result = (int)wxDateTime::GetNumberOfDays(arg1,(wxDateTime::Calendar )arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -15292,7 +15292,7 @@ static PyObject *_wrap_DateTime_GetNumberOfDaysInMonth(PyObject *self, PyObject int arg1 ; int arg2 = (int) wxDateTime::Inv_Year ; int arg3 = (int) wxDateTime::Gregorian ; - wxDateTime::wxDateTime_t result; + int result; char *kwnames[] = { (char *) "month",(char *) "year",(char *) "cal", NULL }; @@ -15300,7 +15300,7 @@ static PyObject *_wrap_DateTime_GetNumberOfDaysInMonth(PyObject *self, PyObject if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"i|ii:DateTime_GetNumberOfDaysInMonth",kwnames,&arg1,&arg2,&arg3)) goto fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)wxDateTime::GetNumberOfDays((wxDateTime::Month )arg1,arg2,(wxDateTime::Calendar )arg3); + result = (int)wxDateTime::GetNumberOfDays((wxDateTime::Month )arg1,arg2,(wxDateTime::Calendar )arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -15630,34 +15630,16 @@ static PyObject *_wrap_new_DateTimeFromJDN(PyObject *self, PyObject *args, PyObj static PyObject *_wrap_new_DateTimeFromHMS(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; - wxDateTime::wxDateTime_t arg1 ; - wxDateTime::wxDateTime_t arg2 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg3 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg4 = (wxDateTime::wxDateTime_t) 0 ; + int arg1 ; + int arg2 = (int) 0 ; + int arg3 = (int) 0 ; + int arg4 = (int) 0 ; wxDateTime *result; - PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; - PyObject * obj2 = 0 ; - PyObject * obj3 = 0 ; char *kwnames[] = { (char *) "hour",(char *) "minute",(char *) "second",(char *) "millisec", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|OOO:new_DateTimeFromHMS",kwnames,&obj0,&obj1,&obj2,&obj3)) goto fail; - arg1 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj0); - if (PyErr_Occurred()) SWIG_fail; - if (obj1) { - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj2) { - arg3 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj2); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj3) { - arg4 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj3); - if (PyErr_Occurred()) SWIG_fail; - } + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"i|iii:new_DateTimeFromHMS",kwnames,&arg1,&arg2,&arg3,&arg4)) goto fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); result = (wxDateTime *)new wxDateTime(arg1,arg2,arg3,arg4); @@ -15674,42 +15656,19 @@ static PyObject *_wrap_new_DateTimeFromHMS(PyObject *self, PyObject *args, PyObj static PyObject *_wrap_new_DateTimeFromDMY(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; - wxDateTime::wxDateTime_t arg1 ; + int arg1 ; int arg2 = (int) wxDateTime::Inv_Month ; int arg3 = (int) wxDateTime::Inv_Year ; - wxDateTime::wxDateTime_t arg4 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg5 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg6 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg7 = (wxDateTime::wxDateTime_t) 0 ; + int arg4 = (int) 0 ; + int arg5 = (int) 0 ; + int arg6 = (int) 0 ; + int arg7 = (int) 0 ; wxDateTime *result; - PyObject * obj0 = 0 ; - PyObject * obj3 = 0 ; - PyObject * obj4 = 0 ; - PyObject * obj5 = 0 ; - PyObject * obj6 = 0 ; char *kwnames[] = { (char *) "day",(char *) "month",(char *) "year",(char *) "hour",(char *) "minute",(char *) "second",(char *) "millisec", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O|iiOOOO:new_DateTimeFromDMY",kwnames,&obj0,&arg2,&arg3,&obj3,&obj4,&obj5,&obj6)) goto fail; - arg1 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj0); - if (PyErr_Occurred()) SWIG_fail; - if (obj3) { - arg4 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj3); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj4) { - arg5 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj4); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj5) { - arg6 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj5); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj6) { - arg7 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj6); - if (PyErr_Occurred()) SWIG_fail; - } + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"i|iiiiii:new_DateTimeFromDMY",kwnames,&arg1,&arg2,&arg3,&arg4,&arg5,&arg6,&arg7)) goto fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); result = (wxDateTime *)new wxDateTime(arg1,(wxDateTime::Month )arg2,arg3,arg4,arg5,arg6,arg7); @@ -15840,36 +15799,18 @@ static PyObject *_wrap_DateTime_SetJDN(PyObject *self, PyObject *args, PyObject static PyObject *_wrap_DateTime_SetHMS(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; - wxDateTime::wxDateTime_t arg3 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg4 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg5 = (wxDateTime::wxDateTime_t) 0 ; + int arg2 ; + int arg3 = (int) 0 ; + int arg4 = (int) 0 ; + int arg5 = (int) 0 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; - PyObject * obj2 = 0 ; - PyObject * obj3 = 0 ; - PyObject * obj4 = 0 ; char *kwnames[] = { (char *) "self",(char *) "hour",(char *) "minute",(char *) "second",(char *) "millisec", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|OOO:DateTime_SetHMS",kwnames,&obj0,&obj1,&obj2,&obj3,&obj4)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi|iii:DateTime_SetHMS",kwnames,&obj0,&arg2,&arg3,&arg4,&arg5)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; - if (obj2) { - arg3 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj2); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj3) { - arg4 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj3); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj4) { - arg5 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj4); - if (PyErr_Occurred()) SWIG_fail; - } { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -15890,44 +15831,21 @@ static PyObject *_wrap_DateTime_SetHMS(PyObject *self, PyObject *args, PyObject static PyObject *_wrap_DateTime_Set(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; int arg3 = (int) wxDateTime::Inv_Month ; int arg4 = (int) wxDateTime::Inv_Year ; - wxDateTime::wxDateTime_t arg5 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg6 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg7 = (wxDateTime::wxDateTime_t) 0 ; - wxDateTime::wxDateTime_t arg8 = (wxDateTime::wxDateTime_t) 0 ; + int arg5 = (int) 0 ; + int arg6 = (int) 0 ; + int arg7 = (int) 0 ; + int arg8 = (int) 0 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; - PyObject * obj4 = 0 ; - PyObject * obj5 = 0 ; - PyObject * obj6 = 0 ; - PyObject * obj7 = 0 ; char *kwnames[] = { (char *) "self",(char *) "day",(char *) "month",(char *) "year",(char *) "hour",(char *) "minute",(char *) "second",(char *) "millisec", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|iiOOOO:DateTime_Set",kwnames,&obj0,&obj1,&arg3,&arg4,&obj4,&obj5,&obj6,&obj7)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi|iiiiii:DateTime_Set",kwnames,&obj0,&arg2,&arg3,&arg4,&arg5,&arg6,&arg7,&arg8)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; - if (obj4) { - arg5 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj4); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj5) { - arg6 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj5); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj6) { - arg7 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj6); - if (PyErr_Occurred()) SWIG_fail; - } - if (obj7) { - arg8 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj7); - if (PyErr_Occurred()) SWIG_fail; - } { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16034,18 +15952,15 @@ static PyObject *_wrap_DateTime_SetMonth(PyObject *self, PyObject *args, PyObjec static PyObject *_wrap_DateTime_SetDay(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "day", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_SetDay",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_SetDay",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16066,18 +15981,15 @@ static PyObject *_wrap_DateTime_SetDay(PyObject *self, PyObject *args, PyObject static PyObject *_wrap_DateTime_SetHour(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "hour", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_SetHour",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_SetHour",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16098,18 +16010,15 @@ static PyObject *_wrap_DateTime_SetHour(PyObject *self, PyObject *args, PyObject static PyObject *_wrap_DateTime_SetMinute(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "minute", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_SetMinute",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_SetMinute",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16130,18 +16039,15 @@ static PyObject *_wrap_DateTime_SetMinute(PyObject *self, PyObject *args, PyObje static PyObject *_wrap_DateTime_SetSecond(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "second", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_SetSecond",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_SetSecond",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16162,18 +16068,15 @@ static PyObject *_wrap_DateTime_SetSecond(PyObject *self, PyObject *args, PyObje static PyObject *_wrap_DateTime_SetMillisecond(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "millisecond", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_SetMillisecond",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_SetMillisecond",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16462,20 +16365,17 @@ static PyObject *_wrap_DateTime_GetLastWeekDay(PyObject *self, PyObject *args, P static PyObject *_wrap_DateTime_SetToTheWeek(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; int arg3 = (int) wxDateTime::Mon ; int arg4 = (int) wxDateTime::Monday_First ; bool result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "numWeek",(char *) "weekday",(char *) "flags", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|ii:DateTime_SetToTheWeek",kwnames,&obj0,&obj1,&arg3,&arg4)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi|ii:DateTime_SetToTheWeek",kwnames,&obj0,&arg2,&arg3,&arg4)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); result = (bool)(arg1)->SetToTheWeek(arg2,(wxDateTime::WeekDay )arg3,(wxDateTime::WeekFlags )arg4); @@ -16493,20 +16393,17 @@ static PyObject *_wrap_DateTime_SetToTheWeek(PyObject *self, PyObject *args, PyO static PyObject *_wrap_DateTime_GetWeek(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; int arg3 = (int) wxDateTime::Mon ; int arg4 = (int) wxDateTime::Monday_First ; wxDateTime result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "numWeek",(char *) "weekday",(char *) "flags", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO|ii:DateTime_GetWeek",kwnames,&obj0,&obj1,&arg3,&arg4)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi|ii:DateTime_GetWeek",kwnames,&obj0,&arg2,&arg3,&arg4)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); result = (arg1)->GetWeek(arg2,(wxDateTime::WeekDay )arg3,(wxDateTime::WeekFlags )arg4); @@ -16589,18 +16486,15 @@ static PyObject *_wrap_DateTime_GetLastMonthDay(PyObject *self, PyObject *args, static PyObject *_wrap_DateTime_SetToYearDay(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime *result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "yday", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_SetToYearDay",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_SetToYearDay",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); { @@ -16621,18 +16515,15 @@ static PyObject *_wrap_DateTime_SetToYearDay(PyObject *self, PyObject *args, PyO static PyObject *_wrap_DateTime_GetYearDay(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxDateTime *arg1 = (wxDateTime *) 0 ; - wxDateTime::wxDateTime_t arg2 ; + int arg2 ; wxDateTime result; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; char *kwnames[] = { (char *) "self",(char *) "yday", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:DateTime_GetYearDay",kwnames,&obj0,&obj1)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:DateTime_GetYearDay",kwnames,&obj0,&arg2)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxDateTime,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - arg2 = (wxDateTime::wxDateTime_t) PyInt_AsLong(obj1); - if (PyErr_Occurred()) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); result = (arg1)->GetYearDay(arg2); @@ -17095,7 +16986,7 @@ static PyObject *_wrap_DateTime_GetDay(PyObject *self, PyObject *args, PyObject wxDateTime *arg1 = (wxDateTime *) 0 ; wxDateTime::TimeZone const &arg2_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg2 = (wxDateTime::TimeZone *) &arg2_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; char *kwnames[] = { @@ -17111,7 +17002,7 @@ static PyObject *_wrap_DateTime_GetDay(PyObject *self, PyObject *args, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetDay((wxDateTime::TimeZone const &)*arg2); + result = (int)((wxDateTime const *)arg1)->GetDay((wxDateTime::TimeZone const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17173,7 +17064,7 @@ static PyObject *_wrap_DateTime_GetHour(PyObject *self, PyObject *args, PyObject wxDateTime *arg1 = (wxDateTime *) 0 ; wxDateTime::TimeZone const &arg2_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg2 = (wxDateTime::TimeZone *) &arg2_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; char *kwnames[] = { @@ -17189,7 +17080,7 @@ static PyObject *_wrap_DateTime_GetHour(PyObject *self, PyObject *args, PyObject } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetHour((wxDateTime::TimeZone const &)*arg2); + result = (int)((wxDateTime const *)arg1)->GetHour((wxDateTime::TimeZone const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17212,7 +17103,7 @@ static PyObject *_wrap_DateTime_GetMinute(PyObject *self, PyObject *args, PyObje wxDateTime *arg1 = (wxDateTime *) 0 ; wxDateTime::TimeZone const &arg2_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg2 = (wxDateTime::TimeZone *) &arg2_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; char *kwnames[] = { @@ -17228,7 +17119,7 @@ static PyObject *_wrap_DateTime_GetMinute(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetMinute((wxDateTime::TimeZone const &)*arg2); + result = (int)((wxDateTime const *)arg1)->GetMinute((wxDateTime::TimeZone const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17251,7 +17142,7 @@ static PyObject *_wrap_DateTime_GetSecond(PyObject *self, PyObject *args, PyObje wxDateTime *arg1 = (wxDateTime *) 0 ; wxDateTime::TimeZone const &arg2_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg2 = (wxDateTime::TimeZone *) &arg2_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; char *kwnames[] = { @@ -17267,7 +17158,7 @@ static PyObject *_wrap_DateTime_GetSecond(PyObject *self, PyObject *args, PyObje } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetSecond((wxDateTime::TimeZone const &)*arg2); + result = (int)((wxDateTime const *)arg1)->GetSecond((wxDateTime::TimeZone const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17290,7 +17181,7 @@ static PyObject *_wrap_DateTime_GetMillisecond(PyObject *self, PyObject *args, P wxDateTime *arg1 = (wxDateTime *) 0 ; wxDateTime::TimeZone const &arg2_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg2 = (wxDateTime::TimeZone *) &arg2_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; char *kwnames[] = { @@ -17306,7 +17197,7 @@ static PyObject *_wrap_DateTime_GetMillisecond(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetMillisecond((wxDateTime::TimeZone const &)*arg2); + result = (int)((wxDateTime const *)arg1)->GetMillisecond((wxDateTime::TimeZone const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17329,7 +17220,7 @@ static PyObject *_wrap_DateTime_GetDayOfYear(PyObject *self, PyObject *args, PyO wxDateTime *arg1 = (wxDateTime *) 0 ; wxDateTime::TimeZone const &arg2_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg2 = (wxDateTime::TimeZone *) &arg2_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj1 = 0 ; char *kwnames[] = { @@ -17345,7 +17236,7 @@ static PyObject *_wrap_DateTime_GetDayOfYear(PyObject *self, PyObject *args, PyO } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetDayOfYear((wxDateTime::TimeZone const &)*arg2); + result = (int)((wxDateTime const *)arg1)->GetDayOfYear((wxDateTime::TimeZone const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17369,7 +17260,7 @@ static PyObject *_wrap_DateTime_GetWeekOfYear(PyObject *self, PyObject *args, Py int arg2 = (int) wxDateTime::Monday_First ; wxDateTime::TimeZone const &arg3_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg3 = (wxDateTime::TimeZone *) &arg3_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj2 = 0 ; char *kwnames[] = { @@ -17385,7 +17276,7 @@ static PyObject *_wrap_DateTime_GetWeekOfYear(PyObject *self, PyObject *args, Py } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetWeekOfYear((wxDateTime::WeekFlags )arg2,(wxDateTime::TimeZone const &)*arg3); + result = (int)((wxDateTime const *)arg1)->GetWeekOfYear((wxDateTime::WeekFlags )arg2,(wxDateTime::TimeZone const &)*arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -17409,7 +17300,7 @@ static PyObject *_wrap_DateTime_GetWeekOfMonth(PyObject *self, PyObject *args, P int arg2 = (int) wxDateTime::Monday_First ; wxDateTime::TimeZone const &arg3_defvalue = LOCAL_TZ ; wxDateTime::TimeZone *arg3 = (wxDateTime::TimeZone *) &arg3_defvalue ; - wxDateTime::wxDateTime_t result; + int result; PyObject * obj0 = 0 ; PyObject * obj2 = 0 ; char *kwnames[] = { @@ -17425,7 +17316,7 @@ static PyObject *_wrap_DateTime_GetWeekOfMonth(PyObject *self, PyObject *args, P } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (wxDateTime::wxDateTime_t)((wxDateTime const *)arg1)->GetWeekOfMonth((wxDateTime::WeekFlags )arg2,(wxDateTime::TimeZone const &)*arg3); + result = (int)((wxDateTime const *)arg1)->GetWeekOfMonth((wxDateTime::WeekFlags )arg2,(wxDateTime::TimeZone const &)*arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; @@ -24522,10 +24413,10 @@ static PyMethodDef SwigMethods[] = { { (char *)"delete_Caret", (PyCFunction) _wrap_delete_Caret, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_IsOk", (PyCFunction) _wrap_Caret_IsOk, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_IsVisible", (PyCFunction) _wrap_Caret_IsVisible, METH_VARARGS | METH_KEYWORDS }, - { (char *)"Caret_GetPositionTuple", (PyCFunction) _wrap_Caret_GetPositionTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_GetPosition", (PyCFunction) _wrap_Caret_GetPosition, METH_VARARGS | METH_KEYWORDS }, - { (char *)"Caret_GetSizeTuple", (PyCFunction) _wrap_Caret_GetSizeTuple, METH_VARARGS | METH_KEYWORDS }, + { (char *)"Caret_GetPositionTuple", (PyCFunction) _wrap_Caret_GetPositionTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_GetSize", (PyCFunction) _wrap_Caret_GetSize, METH_VARARGS | METH_KEYWORDS }, + { (char *)"Caret_GetSizeTuple", (PyCFunction) _wrap_Caret_GetSizeTuple, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_GetWindow", (PyCFunction) _wrap_Caret_GetWindow, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_MoveXY", (PyCFunction) _wrap_Caret_MoveXY, METH_VARARGS | METH_KEYWORDS }, { (char *)"Caret_Move", (PyCFunction) _wrap_Caret_Move, METH_VARARGS | METH_KEYWORDS }, diff --git a/wxPython/src/gtk/windows.py b/wxPython/src/gtk/windows.py index 52db762c1d..2237dbefc0 100644 --- a/wxPython/src/gtk/windows.py +++ b/wxPython/src/gtk/windows.py @@ -91,9 +91,7 @@ class ScrolledWindow(Panel): def GetScrollPixelsPerUnit(*args, **kwargs): """GetScrollPixelsPerUnit() -> (xUnit, yUnit) - - get the size of one logical unit in physical ones - """ +Get the size of one logical unit in physical units.""" return _windows.ScrolledWindow_GetScrollPixelsPerUnit(*args, **kwargs) def EnableScrolling(*args, **kwargs): @@ -101,7 +99,9 @@ class ScrolledWindow(Panel): return _windows.ScrolledWindow_EnableScrolling(*args, **kwargs) def GetViewStart(*args, **kwargs): - """GetViewStart(int OUTPUT, int OUTPUT)""" + """GetViewStart() -> (x,y) + +Get the view start""" return _windows.ScrolledWindow_GetViewStart(*args, **kwargs) def SetScale(*args, **kwargs): @@ -117,13 +117,17 @@ class ScrolledWindow(Panel): return _windows.ScrolledWindow_GetScaleY(*args, **kwargs) def CalcScrolledPosition(*args): - """CalcScrolledPosition(int x, int y, int OUTPUT, int OUTPUT) -CalcScrolledPosition(Point pt) -> Point""" + """CalcScrolledPosition(Point pt) -> Point +CalcScrolledPosition(int x, int y) -> (sx, sy) + +Translate between scrolled and unscrolled coordinates.""" return _windows.ScrolledWindow_CalcScrolledPosition(*args) def CalcUnscrolledPosition(*args): - """CalcUnscrolledPosition(int x, int y, int OUTPUT, int OUTPUT) -CalcUnscrolledPosition(Point pt) -> Point""" + """CalcUnscrolledPosition(Point pt) -> Point +CalcUnscrolledPosition(int x, int y) -> (ux, uy) + +Translate between scrolled and unscrolled coordinates.""" return _windows.ScrolledWindow_CalcUnscrolledPosition(*args) def AdjustScrollbars(*args, **kwargs): @@ -2499,15 +2503,15 @@ class PyWindow(core.Window): return _windows.PyWindow_base_DoSetVirtualSize(*args, **kwargs) def base_DoGetSize(*args, **kwargs): - """base_DoGetSize(int OUTPUT, int OUTPUT)""" + """base_DoGetSize() -> (width, height)""" return _windows.PyWindow_base_DoGetSize(*args, **kwargs) def base_DoGetClientSize(*args, **kwargs): - """base_DoGetClientSize(int OUTPUT, int OUTPUT)""" + """base_DoGetClientSize() -> (width, height)""" return _windows.PyWindow_base_DoGetClientSize(*args, **kwargs) def base_DoGetPosition(*args, **kwargs): - """base_DoGetPosition(int OUTPUT, int OUTPUT)""" + """base_DoGetPosition() -> (x,y)""" return _windows.PyWindow_base_DoGetPosition(*args, **kwargs) def base_DoGetVirtualSize(*args, **kwargs): @@ -2596,15 +2600,15 @@ class PyPanel(Panel): return _windows.PyPanel_base_DoSetVirtualSize(*args, **kwargs) def base_DoGetSize(*args, **kwargs): - """base_DoGetSize(int OUTPUT, int OUTPUT)""" + """base_DoGetSize() -> (width, height)""" return _windows.PyPanel_base_DoGetSize(*args, **kwargs) def base_DoGetClientSize(*args, **kwargs): - """base_DoGetClientSize(int OUTPUT, int OUTPUT)""" + """base_DoGetClientSize() -> (width, height)""" return _windows.PyPanel_base_DoGetClientSize(*args, **kwargs) def base_DoGetPosition(*args, **kwargs): - """base_DoGetPosition(int OUTPUT, int OUTPUT)""" + """base_DoGetPosition() -> (x,y)""" return _windows.PyPanel_base_DoGetPosition(*args, **kwargs) def base_DoGetVirtualSize(*args, **kwargs): @@ -3296,20 +3300,20 @@ class Printout(core.Object): """SetDC(wxDC dc)""" return _windows.Printout_SetDC(*args, **kwargs) - def GetPageSizePixels(*args, **kwargs): - """GetPageSizePixels(int OUTPUT, int OUTPUT)""" - return _windows.Printout_GetPageSizePixels(*args, **kwargs) - def SetPageSizePixels(*args, **kwargs): """SetPageSizePixels(int w, int h)""" return _windows.Printout_SetPageSizePixels(*args, **kwargs) + def GetPageSizePixels(*args, **kwargs): + """GetPageSizePixels() -> (w, h)""" + return _windows.Printout_GetPageSizePixels(*args, **kwargs) + def SetPageSizeMM(*args, **kwargs): """SetPageSizeMM(int w, int h)""" return _windows.Printout_SetPageSizeMM(*args, **kwargs) def GetPageSizeMM(*args, **kwargs): - """GetPageSizeMM(int OUTPUT, int OUTPUT)""" + """GetPageSizeMM() -> (w, h)""" return _windows.Printout_GetPageSizeMM(*args, **kwargs) def SetPPIScreen(*args, **kwargs): @@ -3317,7 +3321,7 @@ class Printout(core.Object): return _windows.Printout_SetPPIScreen(*args, **kwargs) def GetPPIScreen(*args, **kwargs): - """GetPPIScreen(int OUTPUT, int OUTPUT)""" + """GetPPIScreen() -> (x,y)""" return _windows.Printout_GetPPIScreen(*args, **kwargs) def SetPPIPrinter(*args, **kwargs): @@ -3325,7 +3329,7 @@ class Printout(core.Object): return _windows.Printout_SetPPIPrinter(*args, **kwargs) def GetPPIPrinter(*args, **kwargs): - """GetPPIPrinter(int OUTPUT, int OUTPUT)""" + """GetPPIPrinter() -> (x,y)""" return _windows.Printout_GetPPIPrinter(*args, **kwargs) def IsPreview(*args, **kwargs): @@ -3356,14 +3360,14 @@ class Printout(core.Object): """base_OnPreparePrinting()""" return _windows.Printout_base_OnPreparePrinting(*args, **kwargs) - def base_GetPageInfo(*args, **kwargs): - """base_GetPageInfo(int OUTPUT, int OUTPUT, int OUTPUT, int OUTPUT)""" - return _windows.Printout_base_GetPageInfo(*args, **kwargs) - def base_HasPage(*args, **kwargs): """base_HasPage(int page) -> bool""" return _windows.Printout_base_HasPage(*args, **kwargs) + def base_GetPageInfo(*args, **kwargs): + """base_GetPageInfo() -> (minPage, maxPage, pageFrom, pageTo)""" + return _windows.Printout_base_GetPageInfo(*args, **kwargs) + class PrintoutPtr(Printout): def __init__(self, this): diff --git a/wxPython/src/gtk/windows_wrap.cpp b/wxPython/src/gtk/windows_wrap.cpp index afa01fc44b..8d2dfbff11 100644 --- a/wxPython/src/gtk/windows_wrap.cpp +++ b/wxPython/src/gtk/windows_wrap.cpp @@ -1668,33 +1668,29 @@ static PyObject *_wrap_ScrolledWindow_GetScaleY(PyObject *self, PyObject *args, static PyObject *_wrap_ScrolledWindow_CalcScrolledPosition__SWIG_0(PyObject *self, PyObject *args) { PyObject *resultobj; wxScrolledWindow *arg1 = (wxScrolledWindow *) 0 ; - int arg2 ; - int arg3 ; - int *arg4 = (int *) 0 ; - int *arg5 = (int *) 0 ; - int temp4 ; - int temp5 ; + wxPoint *arg2 = 0 ; + wxPoint result; + wxPoint temp2 ; PyObject * obj0 = 0 ; + PyObject * obj1 = 0 ; - arg4 = &temp4; - arg5 = &temp5; - if(!PyArg_ParseTuple(args,(char *)"Oii:ScrolledWindow_CalcScrolledPosition",&obj0,&arg2,&arg3)) goto fail; + if(!PyArg_ParseTuple(args,(char *)"OO:ScrolledWindow_CalcScrolledPosition",&obj0,&obj1)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxScrolledWindow,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; + { + arg2 = &temp2; + if ( ! wxPoint_helper(obj1, &arg2)) SWIG_fail; + } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - ((wxScrolledWindow const *)arg1)->CalcScrolledPosition(arg2,arg3,arg4,arg5); + result = ((wxScrolledWindow const *)arg1)->CalcScrolledPosition((wxPoint const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } - Py_INCREF(Py_None); resultobj = Py_None; - { - PyObject *o = PyInt_FromLong((long) (*arg4)); - resultobj = t_output_helper(resultobj,o); - } { - PyObject *o = PyInt_FromLong((long) (*arg5)); - resultobj = t_output_helper(resultobj,o); + wxPoint * resultptr; + resultptr = new wxPoint((wxPoint &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); } return resultobj; fail: @@ -1705,29 +1701,33 @@ static PyObject *_wrap_ScrolledWindow_CalcScrolledPosition__SWIG_0(PyObject *sel static PyObject *_wrap_ScrolledWindow_CalcScrolledPosition__SWIG_1(PyObject *self, PyObject *args) { PyObject *resultobj; wxScrolledWindow *arg1 = (wxScrolledWindow *) 0 ; - wxPoint *arg2 = 0 ; - wxPoint result; - wxPoint temp2 ; + int arg2 ; + int arg3 ; + int *arg4 = (int *) 0 ; + int *arg5 = (int *) 0 ; + int temp4 ; + int temp5 ; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; - if(!PyArg_ParseTuple(args,(char *)"OO:ScrolledWindow_CalcScrolledPosition",&obj0,&obj1)) goto fail; + arg4 = &temp4; + arg5 = &temp5; + if(!PyArg_ParseTuple(args,(char *)"Oii:ScrolledWindow_CalcScrolledPosition",&obj0,&arg2,&arg3)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxScrolledWindow,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - { - arg2 = &temp2; - if ( ! wxPoint_helper(obj1, &arg2)) SWIG_fail; - } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = ((wxScrolledWindow const *)arg1)->CalcScrolledPosition((wxPoint const &)*arg2); + ((wxScrolledWindow const *)arg1)->CalcScrolledPosition(arg2,arg3,arg4,arg5); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } + Py_INCREF(Py_None); resultobj = Py_None; { - wxPoint * resultptr; - resultptr = new wxPoint((wxPoint &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); + PyObject *o = PyInt_FromLong((long) (*arg4)); + resultobj = t_output_helper(resultobj,o); + } + { + PyObject *o = PyInt_FromLong((long) (*arg5)); + resultobj = t_output_helper(resultobj,o); } return resultobj; fail: @@ -1760,7 +1760,7 @@ static PyObject *_wrap_ScrolledWindow_CalcScrolledPosition(PyObject *self, PyObj _v = wxPySimple_typecheck(argv[1], wxT("wxPoint"), 2); } if (_v) { - return _wrap_ScrolledWindow_CalcScrolledPosition__SWIG_1(self,args); + return _wrap_ScrolledWindow_CalcScrolledPosition__SWIG_0(self,args); } } } @@ -1784,7 +1784,7 @@ static PyObject *_wrap_ScrolledWindow_CalcScrolledPosition(PyObject *self, PyObj _v = (PyInt_Check(argv[2]) || PyLong_Check(argv[2])) ? 1 : 0; } if (_v) { - return _wrap_ScrolledWindow_CalcScrolledPosition__SWIG_0(self,args); + return _wrap_ScrolledWindow_CalcScrolledPosition__SWIG_1(self,args); } } } @@ -1798,33 +1798,29 @@ static PyObject *_wrap_ScrolledWindow_CalcScrolledPosition(PyObject *self, PyObj static PyObject *_wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_0(PyObject *self, PyObject *args) { PyObject *resultobj; wxScrolledWindow *arg1 = (wxScrolledWindow *) 0 ; - int arg2 ; - int arg3 ; - int *arg4 = (int *) 0 ; - int *arg5 = (int *) 0 ; - int temp4 ; - int temp5 ; + wxPoint *arg2 = 0 ; + wxPoint result; + wxPoint temp2 ; PyObject * obj0 = 0 ; + PyObject * obj1 = 0 ; - arg4 = &temp4; - arg5 = &temp5; - if(!PyArg_ParseTuple(args,(char *)"Oii:ScrolledWindow_CalcUnscrolledPosition",&obj0,&arg2,&arg3)) goto fail; + if(!PyArg_ParseTuple(args,(char *)"OO:ScrolledWindow_CalcUnscrolledPosition",&obj0,&obj1)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxScrolledWindow,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; + { + arg2 = &temp2; + if ( ! wxPoint_helper(obj1, &arg2)) SWIG_fail; + } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - ((wxScrolledWindow const *)arg1)->CalcUnscrolledPosition(arg2,arg3,arg4,arg5); + result = ((wxScrolledWindow const *)arg1)->CalcUnscrolledPosition((wxPoint const &)*arg2); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } - Py_INCREF(Py_None); resultobj = Py_None; - { - PyObject *o = PyInt_FromLong((long) (*arg4)); - resultobj = t_output_helper(resultobj,o); - } { - PyObject *o = PyInt_FromLong((long) (*arg5)); - resultobj = t_output_helper(resultobj,o); + wxPoint * resultptr; + resultptr = new wxPoint((wxPoint &) result); + resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); } return resultobj; fail: @@ -1835,29 +1831,33 @@ static PyObject *_wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_0(PyObject *s static PyObject *_wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_1(PyObject *self, PyObject *args) { PyObject *resultobj; wxScrolledWindow *arg1 = (wxScrolledWindow *) 0 ; - wxPoint *arg2 = 0 ; - wxPoint result; - wxPoint temp2 ; + int arg2 ; + int arg3 ; + int *arg4 = (int *) 0 ; + int *arg5 = (int *) 0 ; + int temp4 ; + int temp5 ; PyObject * obj0 = 0 ; - PyObject * obj1 = 0 ; - if(!PyArg_ParseTuple(args,(char *)"OO:ScrolledWindow_CalcUnscrolledPosition",&obj0,&obj1)) goto fail; + arg4 = &temp4; + arg5 = &temp5; + if(!PyArg_ParseTuple(args,(char *)"Oii:ScrolledWindow_CalcUnscrolledPosition",&obj0,&arg2,&arg3)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxScrolledWindow,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - { - arg2 = &temp2; - if ( ! wxPoint_helper(obj1, &arg2)) SWIG_fail; - } { PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = ((wxScrolledWindow const *)arg1)->CalcUnscrolledPosition((wxPoint const &)*arg2); + ((wxScrolledWindow const *)arg1)->CalcUnscrolledPosition(arg2,arg3,arg4,arg5); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } + Py_INCREF(Py_None); resultobj = Py_None; { - wxPoint * resultptr; - resultptr = new wxPoint((wxPoint &) result); - resultobj = SWIG_NewPointerObj((void *) resultptr, SWIGTYPE_p_wxPoint, 1); + PyObject *o = PyInt_FromLong((long) (*arg4)); + resultobj = t_output_helper(resultobj,o); + } + { + PyObject *o = PyInt_FromLong((long) (*arg5)); + resultobj = t_output_helper(resultobj,o); } return resultobj; fail: @@ -1890,7 +1890,7 @@ static PyObject *_wrap_ScrolledWindow_CalcUnscrolledPosition(PyObject *self, PyO _v = wxPySimple_typecheck(argv[1], wxT("wxPoint"), 2); } if (_v) { - return _wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_1(self,args); + return _wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_0(self,args); } } } @@ -1914,7 +1914,7 @@ static PyObject *_wrap_ScrolledWindow_CalcUnscrolledPosition(PyObject *self, PyO _v = (PyInt_Check(argv[2]) || PyLong_Check(argv[2])) ? 1 : 0; } if (_v) { - return _wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_0(self,args); + return _wrap_ScrolledWindow_CalcUnscrolledPosition__SWIG_1(self,args); } } } @@ -18544,64 +18544,64 @@ static PyObject *_wrap_Printout_SetDC(PyObject *self, PyObject *args, PyObject * } -static PyObject *_wrap_Printout_GetPageSizePixels(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_Printout_SetPageSizePixels(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxPyPrintout *arg1 = (wxPyPrintout *) 0 ; - int *arg2 = (int *) 0 ; - int *arg3 = (int *) 0 ; - int temp2 ; - int temp3 ; + int arg2 ; + int arg3 ; PyObject * obj0 = 0 ; char *kwnames[] = { - (char *) "self", NULL + (char *) "self",(char *) "w",(char *) "h", NULL }; - arg2 = &temp2; - arg3 = &temp3; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Printout_GetPageSizePixels",kwnames,&obj0)) goto fail; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oii:Printout_SetPageSizePixels",kwnames,&obj0,&arg2,&arg3)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxPyPrintout,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - (arg1)->GetPageSizePixels(arg2,arg3); + (arg1)->SetPageSizePixels(arg2,arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } Py_INCREF(Py_None); resultobj = Py_None; - { - PyObject *o = PyInt_FromLong((long) (*arg2)); - resultobj = t_output_helper(resultobj,o); - } - { - PyObject *o = PyInt_FromLong((long) (*arg3)); - resultobj = t_output_helper(resultobj,o); - } return resultobj; fail: return NULL; } -static PyObject *_wrap_Printout_SetPageSizePixels(PyObject *self, PyObject *args, PyObject *kwargs) { +static PyObject *_wrap_Printout_GetPageSizePixels(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxPyPrintout *arg1 = (wxPyPrintout *) 0 ; - int arg2 ; - int arg3 ; + int *arg2 = (int *) 0 ; + int *arg3 = (int *) 0 ; + int temp2 ; + int temp3 ; PyObject * obj0 = 0 ; char *kwnames[] = { - (char *) "self",(char *) "w",(char *) "h", NULL + (char *) "self", NULL }; - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oii:Printout_SetPageSizePixels",kwnames,&obj0,&arg2,&arg3)) goto fail; + arg2 = &temp2; + arg3 = &temp3; + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:Printout_GetPageSizePixels",kwnames,&obj0)) goto fail; if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxPyPrintout,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; { PyThreadState* __tstate = wxPyBeginAllowThreads(); - (arg1)->SetPageSizePixels(arg2,arg3); + (arg1)->GetPageSizePixels(arg2,arg3); wxPyEndAllowThreads(__tstate); if (PyErr_Occurred()) SWIG_fail; } Py_INCREF(Py_None); resultobj = Py_None; + { + PyObject *o = PyInt_FromLong((long) (*arg2)); + resultobj = t_output_helper(resultobj,o); + } + { + PyObject *o = PyInt_FromLong((long) (*arg3)); + resultobj = t_output_helper(resultobj,o); + } return resultobj; fail: return NULL; @@ -18976,6 +18976,32 @@ static PyObject *_wrap_Printout_base_OnPreparePrinting(PyObject *self, PyObject } +static PyObject *_wrap_Printout_base_HasPage(PyObject *self, PyObject *args, PyObject *kwargs) { + PyObject *resultobj; + wxPyPrintout *arg1 = (wxPyPrintout *) 0 ; + int arg2 ; + bool result; + PyObject * obj0 = 0 ; + char *kwnames[] = { + (char *) "self",(char *) "page", NULL + }; + + if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:Printout_base_HasPage",kwnames,&obj0,&arg2)) goto fail; + if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxPyPrintout,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; + { + PyThreadState* __tstate = wxPyBeginAllowThreads(); + result = (bool)(arg1)->base_HasPage(arg2); + + wxPyEndAllowThreads(__tstate); + if (PyErr_Occurred()) SWIG_fail; + } + resultobj = PyInt_FromLong((long)result); + return resultobj; + fail: + return NULL; +} + + static PyObject *_wrap_Printout_base_GetPageInfo(PyObject *self, PyObject *args, PyObject *kwargs) { PyObject *resultobj; wxPyPrintout *arg1 = (wxPyPrintout *) 0 ; @@ -19028,32 +19054,6 @@ static PyObject *_wrap_Printout_base_GetPageInfo(PyObject *self, PyObject *args, } -static PyObject *_wrap_Printout_base_HasPage(PyObject *self, PyObject *args, PyObject *kwargs) { - PyObject *resultobj; - wxPyPrintout *arg1 = (wxPyPrintout *) 0 ; - int arg2 ; - bool result; - PyObject * obj0 = 0 ; - char *kwnames[] = { - (char *) "self",(char *) "page", NULL - }; - - if(!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"Oi:Printout_base_HasPage",kwnames,&obj0,&arg2)) goto fail; - if ((SWIG_ConvertPtr(obj0,(void **) &arg1, SWIGTYPE_p_wxPyPrintout,SWIG_POINTER_EXCEPTION | 0 )) == -1) SWIG_fail; - { - PyThreadState* __tstate = wxPyBeginAllowThreads(); - result = (bool)(arg1)->base_HasPage(arg2); - - wxPyEndAllowThreads(__tstate); - if (PyErr_Occurred()) SWIG_fail; - } - resultobj = PyInt_FromLong((long)result); - return resultobj; - fail: - return NULL; -} - - static PyObject * Printout_swigregister(PyObject *self, PyObject *args) { PyObject *obj; if (!PyArg_ParseTuple(args,(char*)"O", &obj)) return NULL; @@ -21522,8 +21522,8 @@ static PyMethodDef SwigMethods[] = { { (char *)"Printout_GetTitle", (PyCFunction) _wrap_Printout_GetTitle, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_GetDC", (PyCFunction) _wrap_Printout_GetDC, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_SetDC", (PyCFunction) _wrap_Printout_SetDC, METH_VARARGS | METH_KEYWORDS }, - { (char *)"Printout_GetPageSizePixels", (PyCFunction) _wrap_Printout_GetPageSizePixels, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_SetPageSizePixels", (PyCFunction) _wrap_Printout_SetPageSizePixels, METH_VARARGS | METH_KEYWORDS }, + { (char *)"Printout_GetPageSizePixels", (PyCFunction) _wrap_Printout_GetPageSizePixels, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_SetPageSizeMM", (PyCFunction) _wrap_Printout_SetPageSizeMM, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_GetPageSizeMM", (PyCFunction) _wrap_Printout_GetPageSizeMM, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_SetPPIScreen", (PyCFunction) _wrap_Printout_SetPPIScreen, METH_VARARGS | METH_KEYWORDS }, @@ -21537,8 +21537,8 @@ static PyMethodDef SwigMethods[] = { { (char *)"Printout_base_OnBeginPrinting", (PyCFunction) _wrap_Printout_base_OnBeginPrinting, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_base_OnEndPrinting", (PyCFunction) _wrap_Printout_base_OnEndPrinting, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_base_OnPreparePrinting", (PyCFunction) _wrap_Printout_base_OnPreparePrinting, METH_VARARGS | METH_KEYWORDS }, - { (char *)"Printout_base_GetPageInfo", (PyCFunction) _wrap_Printout_base_GetPageInfo, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_base_HasPage", (PyCFunction) _wrap_Printout_base_HasPage, METH_VARARGS | METH_KEYWORDS }, + { (char *)"Printout_base_GetPageInfo", (PyCFunction) _wrap_Printout_base_GetPageInfo, METH_VARARGS | METH_KEYWORDS }, { (char *)"Printout_swigregister", Printout_swigregister, METH_VARARGS }, { (char *)"new_PreviewCanvas", (PyCFunction) _wrap_new_PreviewCanvas, METH_VARARGS | METH_KEYWORDS }, { (char *)"PreviewCanvas_swigregister", PreviewCanvas_swigregister, METH_VARARGS }, diff --git a/wxPython/src/gtk/wizard.py b/wxPython/src/gtk/wizard.py index 55feb72b34..589de2b875 100644 --- a/wxPython/src/gtk/wizard.py +++ b/wxPython/src/gtk/wizard.py @@ -111,15 +111,15 @@ class PyWizardPage(WizardPage): return _wizard.PyWizardPage_base_DoSetVirtualSize(*args, **kwargs) def base_DoGetSize(*args, **kwargs): - """base_DoGetSize(int OUTPUT, int OUTPUT)""" + """base_DoGetSize() -> (width, height)""" return _wizard.PyWizardPage_base_DoGetSize(*args, **kwargs) def base_DoGetClientSize(*args, **kwargs): - """base_DoGetClientSize(int OUTPUT, int OUTPUT)""" + """base_DoGetClientSize() -> (width, height)""" return _wizard.PyWizardPage_base_DoGetClientSize(*args, **kwargs) def base_DoGetPosition(*args, **kwargs): - """base_DoGetPosition(int OUTPUT, int OUTPUT)""" + """base_DoGetPosition() -> (x,y)""" return _wizard.PyWizardPage_base_DoGetPosition(*args, **kwargs) def base_DoGetVirtualSize(*args, **kwargs): diff --git a/wxPython/src/wizard.i b/wxPython/src/wizard.i index 8d75ca5750..b7e7653bbd 100644 --- a/wxPython/src/wizard.i +++ b/wxPython/src/wizard.i @@ -234,9 +234,15 @@ public: void base_DoSetClientSize(int width, int height); void base_DoSetVirtualSize( int x, int y ); - void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const; - void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const; + DocDeclA( + void, base_DoGetSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetSize() -> (width, height)"); + DocDeclA( + void, base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetClientSize() -> (width, height)"); + DocDeclA( + void, base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const, + "base_DoGetPosition() -> (x,y)"); wxSize base_DoGetVirtualSize() const; wxSize base_DoGetBestSize() const; -- 2.45.2