diff --git a/TODO.txt b/TODO.txt index 82a0d82e..d8e19d62 100644 --- a/TODO.txt +++ b/TODO.txt @@ -126,14 +126,13 @@ other dev stuff * filehistory * fswatcher * headerctrl - * minifram * mousemanager * msgout * palette ? * persist ? * quantize * rawbmp - * richmsgdlg + * richmsgdlg (requires wrappers for wxGenericMessageDialog) * textdlg * valgen * valnum diff --git a/etg/_core.py b/etg/_core.py index 1d31203e..dc1f822a 100644 --- a/etg/_core.py +++ b/etg/_core.py @@ -185,6 +185,7 @@ INCLUDES = [ # base and core stuff 'mdi', 'fontdlg', 'rearrangectrl', + 'minifram', # misc 'power', diff --git a/etg/minifram.py b/etg/minifram.py new file mode 100644 index 00000000..59a6930a --- /dev/null +++ b/etg/minifram.py @@ -0,0 +1,47 @@ +#--------------------------------------------------------------------------- +# Name: etg/minifram.py +# Author: Robin Dunn +# +# Created: 28-Jun-2012 +# Copyright: (c) 2012 by Total Control Software +# License: wxWindows License +#--------------------------------------------------------------------------- + +import etgtools +import etgtools.tweaker_tools as tools + +PACKAGE = "wx" +MODULE = "_core" +NAME = "minifram" # Base name of the file to generate to for this script +DOCSTRING = "" + +# The classes and/or the basename of the Doxygen XML files to be processed by +# this script. +ITEMS = [ "wxMiniFrame", + ] + +#--------------------------------------------------------------------------- + +def run(): + # Parse the XML file(s) building a collection of Extractor objects + module = etgtools.ModuleDef(PACKAGE, MODULE, NAME, DOCSTRING) + etgtools.parseDoxyXML(module, ITEMS) + + #----------------------------------------------------------------- + # Tweak the parsed meta objects in the module object as needed for + # customizing the generated code and docstrings. + + c = module.find('wxMiniFrame') + assert isinstance(c, etgtools.ClassDef) + tools.fixTopLevelWindowClass(c) + + + #----------------------------------------------------------------- + tools.doCommonTweaks(module) + tools.runGenerators(module) + + +#--------------------------------------------------------------------------- +if __name__ == '__main__': + run() + diff --git a/unittests/test_minifram.py b/unittests/test_minifram.py new file mode 100644 index 00000000..efc4f357 --- /dev/null +++ b/unittests/test_minifram.py @@ -0,0 +1,21 @@ +import imp_unittest, unittest +import wtc +import wx + +#--------------------------------------------------------------------------- + +class minifram_Tests(wtc.WidgetTestCase): + + def test_minifram1(self): + f = wx.MiniFrame() + f.Create(self.frame, title="Hello") + f.Show() + + def test_minifram2(self): + f = wx.MiniFrame(self.frame, title="Hello") + f.Show() + +#--------------------------------------------------------------------------- + +if __name__ == '__main__': + unittest.main()