mirror of https://github.com/kivy/kivy.git
Merge pull request #7322 from kivy/fix_7314
Widget: fix export_to_png not passing arguments through
This commit is contained in:
commit
ac30e71c03
|
@ -82,9 +82,9 @@ class WidgetTestCase(unittest.TestCase):
|
|||
wid.export_to_png(join(tmp, 'b.png'), scale=.5)
|
||||
wid.export_to_png(join(tmp, 'c.png'), scale=2)
|
||||
|
||||
CoreImage(join(tmp, 'a.png')).size == (200, 100)
|
||||
CoreImage(join(tmp, 'b.png')).size == (100, 50)
|
||||
CoreImage(join(tmp, 'c.png')).size == (400, 200)
|
||||
self.assertEqual(CoreImage(join(tmp, 'a.png')).size, (200, 100))
|
||||
self.assertEqual(CoreImage(join(tmp, 'b.png')).size, (100, 50))
|
||||
self.assertEqual(CoreImage(join(tmp, 'c.png')).size, (400, 200))
|
||||
rmtree(tmp)
|
||||
|
||||
self.root.remove_widget(wid)
|
||||
|
|
|
@ -720,7 +720,7 @@ class Widget(WidgetBase):
|
|||
|
||||
.. versionadded:: 1.11.0
|
||||
'''
|
||||
self.export_as_image().save(filename, flipped=False)
|
||||
self.export_as_image(*args, **kwargs).save(filename, flipped=False)
|
||||
|
||||
def export_as_image(self, *args, **kwargs):
|
||||
'''Return an core :class:`~kivy.core.image.Image` of the actual
|
||||
|
|
Loading…
Reference in New Issue