From f2a497dcf96f37892403a662fb7bfb539e5b0c0e Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Mon, 3 Jan 2000 19:30:51 +0000 Subject: [PATCH] Made wxEditor constructor args consistent with other window classes git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5217 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- utils/wxPython/demo/wxEditor.py | 4 ++-- utils/wxPython/lib/editor/editor.py | 7 ++++--- utils/wxPython/lib/editor/py_editor.py | 5 +++-- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/utils/wxPython/demo/wxEditor.py b/utils/wxPython/demo/wxEditor.py index a798b9a8f6..a55dc9def2 100644 --- a/utils/wxPython/demo/wxEditor.py +++ b/utils/wxPython/demo/wxEditor.py @@ -6,8 +6,8 @@ from wxPython.lib.editor import wxEditor, wxPyEditor def runTest(frame, nb, log): win = wxPanel(nb, -1) - ed = wxEditor(win) - pyed = wxPyEditor(win) + ed = wxEditor(win, -1, style=wxSUNKEN_BORDER) + pyed = wxPyEditor(win, -1, style=wxSUNKEN_BORDER) box = wxBoxSizer(wxVERTICAL) box.Add(ed, 1, wxALL|wxGROW, 5) box.Add(pyed, 1, wxALL|wxGROW, 5) diff --git a/utils/wxPython/lib/editor/editor.py b/utils/wxPython/lib/editor/editor.py index 247afba036..b34d724798 100644 --- a/utils/wxPython/lib/editor/editor.py +++ b/utils/wxPython/lib/editor/editor.py @@ -44,15 +44,16 @@ class Line: class wxEditor(wxScrolledWindow): - def __init__(self, parent, id=-1): + def __init__(self, parent, id, + pos=wxDefaultPosition, size=wxDefaultSize, style=0): ############################################################### """ Alles hat einen Anfang """ wxScrolledWindow.__init__(self, parent, id, - wxDefaultPosition, wxSize(500,400), - wxSUNKEN_BORDER|wxWANTS_CHARS) + pos, size, + style|wxWANTS_CHARS) # the syntax informations, if they don't exist, # all syntax stuff will be ignored diff --git a/utils/wxPython/lib/editor/py_editor.py b/utils/wxPython/lib/editor/py_editor.py index 0f75551f7b..883370d77d 100644 --- a/utils/wxPython/lib/editor/py_editor.py +++ b/utils/wxPython/lib/editor/py_editor.py @@ -18,8 +18,9 @@ class wxPyEditor(wxEditor): # ------------------------------------------------------------------ - def __init__(self, parent, id=-1): - wxEditor.__init__(self, parent, id) + def __init__(self, parent, id, + pos=wxDefaultPosition, size=wxDefaultSize, style=0): + wxEditor.__init__(self, parent, id, pos, size, style) self.SetFontTab([ wxNamedColour('black'), wxNamedColour('blue'),