fsleyes_widgets.imagepanel
¶
This module provides the ImagePanel
class, for displaying a
wx.Image
.
-
class
fsleyes_widgets.imagepanel.
ImagePanel
(parent, image=None, preserveAspect=False)[source]¶ Bases:
wx._core.Panel
A
wx.Panel
which may be used to display a resizeablewx.Image
. The image is scaled to the size of the panel.Create an
ImagePanel
.If the
image
is not passed in here, it can be set later with theSetImage()
method.- Parameters
parent – The
wx
parent object.image – The
wx.Image
object to display.preserveAspect – Defaults to
False
. IfTrue
, the image aspect ratio is preserved.