X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bfddbb17dcdef78d84dbfcd021f8d49143d32adf..976f924083419b6a7feb1ff7d597c746a70abf1a:/wxPython/src/mac/_windows.py diff --git a/wxPython/src/mac/_windows.py b/wxPython/src/mac/_windows.py index 20110b173d..961a3a49ca 100644 --- a/wxPython/src/mac/_windows.py +++ b/wxPython/src/mac/_windows.py @@ -27,6 +27,8 @@ class Panel(_core.Window): Create(self, Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=wxTAB_TRAVERSAL|wxNO_BORDER, String name=PanelNameStr) -> bool + + Create the GUI part of the Window for 2-phase creation mode. """ return _windows_.Panel_Create(*args, **kwargs) @@ -110,6 +112,8 @@ class ScrolledWindow(Panel): Create(self, Window parent, int id=-1, Point pos=DefaultPosition, Size size=DefaultSize, long style=wxHSCROLL|wxVSCROLL, String name=PanelNameStr) -> bool + + Create the GUI part of the Window for 2-phase creation mode. """ return _windows_.ScrolledWindow_Create(*args, **kwargs) @@ -137,7 +141,11 @@ class ScrolledWindow(Panel): return _windows_.ScrolledWindow_SetScrollRate(*args, **kwargs) def GetScrollPixelsPerUnit(*args, **kwargs): - """GetScrollPixelsPerUnit() -> (xUnit, yUnit)""" + """ + GetScrollPixelsPerUnit() -> (xUnit, yUnit) + + Get the size of one logical unit in physical units. + """ return _windows_.ScrolledWindow_GetScrollPixelsPerUnit(*args, **kwargs) def EnableScrolling(*args, **kwargs): @@ -145,7 +153,11 @@ class ScrolledWindow(Panel): return _windows_.ScrolledWindow_EnableScrolling(*args, **kwargs) def GetViewStart(*args, **kwargs): - """GetViewStart() -> (x,y)""" + """ + GetViewStart() -> (x,y) + + Get the view start + """ return _windows_.ScrolledWindow_GetViewStart(*args, **kwargs) def SetScale(*args, **kwargs): @@ -202,6 +214,14 @@ class ScrolledWindow(Panel): """GetTargetRect(self) -> Rect""" return _windows_.ScrolledWindow_GetTargetRect(*args, **kwargs) + def DoPrepareDC(*args, **kwargs): + """ + DoPrepareDC(self, DC dc) + + Normally what is called by `PrepareDC`. + """ + return _windows_.ScrolledWindow_DoPrepareDC(*args, **kwargs) + def GetClassDefaultAttributes(*args, **kwargs): """ GetClassDefaultAttributes(int variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes @@ -285,6 +305,8 @@ FULLSCREEN_NOBORDER = _windows_.FULLSCREEN_NOBORDER FULLSCREEN_NOCAPTION = _windows_.FULLSCREEN_NOCAPTION FULLSCREEN_ALL = _windows_.FULLSCREEN_ALL TOPLEVEL_EX_DIALOG = _windows_.TOPLEVEL_EX_DIALOG +USER_ATTENTION_INFO = _windows_.USER_ATTENTION_INFO +USER_ATTENTION_ERROR = _windows_.USER_ATTENTION_ERROR class TopLevelWindow(_core.Window): def __init__(self): raise RuntimeError, "No constructor defined" def __repr__(self): @@ -349,6 +371,10 @@ class TopLevelWindow(_core.Window): """SetShape(self, Region region) -> bool""" return _windows_.TopLevelWindow_SetShape(*args, **kwargs) + def RequestUserAttention(*args, **kwargs): + """RequestUserAttention(self, int flags=USER_ATTENTION_INFO)""" + return _windows_.TopLevelWindow_RequestUserAttention(*args, **kwargs) + def MacSetMetalAppearance(*args, **kwargs): """MacSetMetalAppearance(self, bool on)""" return _windows_.TopLevelWindow_MacSetMetalAppearance(*args, **kwargs) @@ -601,6 +627,9 @@ class Dialog(TopLevelWindow): return _windows_.Dialog_GetClassDefaultAttributes(*args, **kwargs) GetClassDefaultAttributes = staticmethod(GetClassDefaultAttributes) + def SendSizeEvent(self): + self.ProcessEvent(wx.SizeEvent((-1,-1))) + class DialogPtr(Dialog): def __init__(self, this): @@ -745,6 +774,9 @@ _windows_.SplashScreen_swigregister(SplashScreenPtr) #--------------------------------------------------------------------------- +SB_NORMAL = _windows_.SB_NORMAL +SB_FLAT = _windows_.SB_FLAT +SB_RAISED = _windows_.SB_RAISED class StatusBar(_core.Window): def __repr__(self): return "<%s.%s; proxy of C++ wxStatusBar instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) @@ -788,6 +820,10 @@ class StatusBar(_core.Window): """SetStatusWidths(self, int widths, int widths_field)""" return _windows_.StatusBar_SetStatusWidths(*args, **kwargs) + def SetStatusStyles(*args, **kwargs): + """SetStatusStyles(self, int styles, int styles_field)""" + return _windows_.StatusBar_SetStatusStyles(*args, **kwargs) + def GetFieldRect(*args, **kwargs): """GetFieldRect(self, int i) -> Rect""" return _windows_.StatusBar_GetFieldRect(*args, **kwargs) @@ -1765,13 +1801,13 @@ class VScrolledWindow(Panel): """RefreshLines(self, size_t from, size_t to)""" return _windows_.VScrolledWindow_RefreshLines(*args, **kwargs) - def HitTestXT(*args, **kwargs): + def HitTestXY(*args, **kwargs): """ - HitTestXT(self, int x, int y) -> int + HitTestXY(self, int x, int y) -> int Test where the given (in client coords) point lies """ - return _windows_.VScrolledWindow_HitTestXT(*args, **kwargs) + return _windows_.VScrolledWindow_HitTestXY(*args, **kwargs) def HitTest(*args, **kwargs): """ @@ -1865,11 +1901,11 @@ class VListBox(VScrolledWindow): return _windows_.VListBox_GetSelectedCount(*args, **kwargs) def GetFirstSelected(*args, **kwargs): - """GetFirstSelected(self, unsigned long cookie) -> int""" + """GetFirstSelected(self) -> PyObject""" return _windows_.VListBox_GetFirstSelected(*args, **kwargs) def GetNextSelected(*args, **kwargs): - """GetNextSelected(self, unsigned long cookie) -> int""" + """GetNextSelected(self, unsigned long cookie) -> PyObject""" return _windows_.VListBox_GetNextSelected(*args, **kwargs) def GetMargins(*args, **kwargs): @@ -2445,7 +2481,12 @@ class MultiChoiceDialog(Dialog): self._setOORInfo(self) def SetSelections(*args, **kwargs): - """SetSelections(List selections)""" + """ + SetSelections(List selections) + + Specify the items in the list that should be selected, using a list of + integers. + """ return _windows_.MultiChoiceDialog_SetSelections(*args, **kwargs) def GetSelections(*args, **kwargs): @@ -2802,8 +2843,10 @@ class ProgressDialog(Frame): Update(self, int value, String newmsg=EmptyString) -> bool Updates the dialog, setting the progress bar to the new value and, if - given changes the message above it. Returns true unless the Cancel - button has been pressed. + given changes the message above it. The value given should be less + than or equal to the maximum value given to the constructor and the + dialog is closed if it is equal to the maximum. Returns true unless + the Cancel button has been pressed. If false is returned, the application can either immediately destroy the dialog or ask the user for the confirmation and if the abort is @@ -3608,9 +3651,12 @@ PRINT_MODE_STREAM = _windows_.PRINT_MODE_STREAM class PrintData(_core.Object): def __repr__(self): return "<%s.%s; proxy of C++ wxPrintData instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) - def __init__(self, *args, **kwargs): - """__init__(self) -> PrintData""" - newobj = _windows_.new_PrintData(*args, **kwargs) + def __init__(self, *args): + """ + __init__(self) -> PrintData + __init__(self, PrintData data) -> PrintData + """ + newobj = _windows_.new_PrintData(*args) self.this = newobj.this self.thisown = 1 del newobj.thisown @@ -3806,9 +3852,12 @@ PreviewCanvasNameStr = cvar.PreviewCanvasNameStr class PageSetupDialogData(_core.Object): def __repr__(self): return "<%s.%s; proxy of C++ wxPageSetupDialogData instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this,) - def __init__(self, *args, **kwargs): - """__init__(self) -> PageSetupDialogData""" - newobj = _windows_.new_PageSetupDialogData(*args, **kwargs) + def __init__(self, *args): + """ + __init__(self) -> PageSetupDialogData + __init__(self, PageSetupDialogData data) -> PageSetupDialogData + """ + newobj = _windows_.new_PageSetupDialogData(*args) self.this = newobj.this self.thisown = 1 del newobj.thisown