]> git.saurik.com Git - wxWidgets.git/blobdiff - wxPython/src/msw/gdi.py
wxWindowsPrinter::Print ignored the "All pages" option, instead it was using the...
[wxWidgets.git] / wxPython / src / msw / gdi.py
index 034c0529cd7ca1f47c54e831d8de5dc3d9317617..4c4f884c6253b5c6a675a4b20dd3974788362363 100644 (file)
@@ -364,7 +364,7 @@ class wxColourPtr(wxObjectPtr):
         return "<%s.%s instance; proxy of C++ wxColour instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
     asTuple = Get
     def __str__(self):                  return str(self.asTuple())
-    def __repr__(self):                 return 'wxColour:' + str(self.asTuple())
+    def __repr__(self):                 return 'wxColour' + str(self.asTuple())
     def __nonzero__(self):              return self.Ok()
     def __getinitargs__(self):          return ()
     def __getstate__(self):             return self.asTuple()
@@ -382,13 +382,15 @@ class wxColourDatabasePtr(wxObjectPtr):
     def __init__(self,this):
         self.this = this
         self.thisown = 0
-    def FindColour(self, *_args, **_kwargs):
-        val = gdic.wxColourDatabase_FindColour(self, *_args, **_kwargs)
-        if val: val = wxColourPtr(val) 
-        return val
-    def FindColourNoAdd(self, *_args, **_kwargs):
-        val = gdic.wxColourDatabase_FindColourNoAdd(self, *_args, **_kwargs)
-        if val: val = wxColourPtr(val) 
+    def __del__(self, delfunc=gdic.delete_wxColourDatabase):
+        if self.thisown == 1:
+            try:
+                delfunc(self)
+            except:
+                pass
+    def Find(self, *_args, **_kwargs):
+        val = gdic.wxColourDatabase_Find(self, *_args, **_kwargs)
+        if val: val = wxColourPtr(val) ; val.thisown = 1
         return val
     def FindName(self, *_args, **_kwargs):
         val = gdic.wxColourDatabase_FindName(self, *_args, **_kwargs)
@@ -402,8 +404,9 @@ class wxColourDatabasePtr(wxObjectPtr):
     def __repr__(self):
         return "<%s.%s instance; proxy of C++ wxColourDatabase instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
 class wxColourDatabase(wxColourDatabasePtr):
-    def __init__(self,this):
-        self.this = this
+    def __init__(self,*_args,**_kwargs):
+        self.this = gdic.new_wxColourDatabase(*_args,**_kwargs)
+        self.thisown = 1
 
 
 
@@ -1424,6 +1427,9 @@ class wxRegionIteratorPtr(wxObjectPtr):
     def Next(self, *_args, **_kwargs):
         val = gdic.wxRegionIterator_Next(self, *_args, **_kwargs)
         return val
+    def __nonzero__(self, *_args, **_kwargs):
+        val = gdic.wxRegionIterator___nonzero__(self, *_args, **_kwargs)
+        return val
     def __repr__(self):
         return "<%s.%s instance; proxy of C++ wxRegionIterator instance at %s>" % (self.__class__.__module__, self.__class__.__name__, self.this)
 class wxRegionIterator(wxRegionIteratorPtr):