MeVisLab Web Toolkit Reference
Loading...
Searching...
No Matches
MLAB.GUI.RemoteRenderingWidgetBase Class Reference

Base class for remote rendering widgets. More...

Inheritance diagram for MLAB.GUI.RemoteRenderingWidgetBase:
MLAB.GUI.Widget MLAB.Core.Object MLAB.GUI.RemoteRenderingWidget

Public Member Functions

 getMaximumSize ()
 Returns the maximum size of the viewport.
 getMinimumSize ()
 Returns the minimum size of the viewport.
 getViewport ()
 Returns the viewport DOM element.
 getViewportSize ()
 Returns the viewport size.
 resizeViewport (w, h, deviceWidth, deviceHeight)
 Resizes the viewport.
 resizeViewportToSizeHint ()
 This method resizes the viewport to the size hint, or the viewport size if the size hint is invalid.
 setMaximumSize (size)
 Sets the maximum size of the viewport.
 setMinimumSize (size)
 Sets the maximum size of the viewport.
 setScaleImageOnResize (flag)
 Sets if scaling of the image on the canvas is done on resize.
 setSizeHint (sizeHint)
 Sets the size hint for the viewport.
 slaveWasAdded ()
 Called from the slave when it is added.
 useSizeHintHeight ()
 Returns true if the height of the size hint should be used.
 useSizeHintWidth ()
 Returns true if the width of the size hint should be used.
Signals

See MLAB.Core.Object about use.

#

 viewportSizeChanged (width, height)
 Is emitted when the size of the viewport has changed.
Public Member Functions inherited from MLAB.GUI.Widget
 isEnabled ()
 Returns if the widget is enabled.
 isVisible ()
 Returns if the widget is visible.
 visitChildren ()
 Visits all children recursively and calls visitor with each child as argument.
Public Member Functions inherited from MLAB.Core.Object
 __init__ ()
 Creates a new MLAB.Core.Object.
 blockSignals (blocked)
 Sets if signals are blocked, which means that signals are suppressed in situations where they would have been emitted.
 connect (signal, receiver, slot)
 Connects a signal of this object to the slot of the receiver.
 connectCallback (signal, callback)
 Connects a signal of this object to the given callback function.
 connectSignal (signal, receiver, targetSignal)
 Connects a signal of this object to the signal of the receiver, so that if this signal is emitted, the target signal on the receiver is also emitted.
 disconnect (signal, receiver, signal)
 Disconnects a signal of this object from the slot of the receiver.
 disconnectCallback (signal, callback)
 Disconnects a signal of this object from the given callback function.
 disconnectReceiver (signal, receiver)
 Disconnects a signal of this object from all slots of the receiver.
 emit (signal)
 Emits a signal.
 isSignalRegistered ()
 Returns true if the given signal is registered.
 registerSignal (signal)
 Registers a signal.
 signalsBlocked ()
 Returns true if signals are blocked.

Protected Member Functions

 _setDOMElementVisible ()
 Sets the visibility of this widget.

Detailed Description

Base class for remote rendering widgets.

Definition at line 1131 of file GUI.py.

Member Function Documentation

◆ _setDOMElementVisible()

MLAB.GUI.RemoteRenderingWidgetBase._setDOMElementVisible ( )
protected

Sets the visibility of this widget.

Calls MLAB.GUI.Widget.setVisible() and enables/disables the slave according to the visibility (if the slave exists and is added).

Definition at line 1229 of file GUI.py.

◆ getMaximumSize()

MLAB.GUI.RemoteRenderingWidgetBase.getMaximumSize ( )

Returns the maximum size of the viewport.

Returns
An array with two elements: [width, height]

Definition at line 1188 of file GUI.py.

◆ getMinimumSize()

MLAB.GUI.RemoteRenderingWidgetBase.getMinimumSize ( )

Returns the minimum size of the viewport.

Returns
An array with two elements: [width, height]

Definition at line 1202 of file GUI.py.

◆ getViewport()

MLAB.GUI.RemoteRenderingWidgetBase.getViewport ( )

Returns the viewport DOM element.

Needs to be implemented by the concrete remote rendering control class. The default implementation throws an exception.

Returns
Returns the DOM element that is the viewport.

Definition at line 1224 of file GUI.py.

◆ getViewportSize()

MLAB.GUI.RemoteRenderingWidgetBase.getViewportSize ( )

Returns the viewport size.

Returns
The viewport size as array with two elements: [width, height].

Definition at line 1143 of file GUI.py.

◆ resizeViewport()

MLAB.GUI.RemoteRenderingWidgetBase.resizeViewport ( w,
h,
deviceWidth,
deviceHeight )

Resizes the viewport.

Parameters
wThe new viewport width.
hThe new viewport height.
deviceWidthThe new viewport width in device pixels (optional).
deviceHeightThe new viewport height in device pixels (optional).

Definition at line 1153 of file GUI.py.

◆ resizeViewportToSizeHint()

MLAB.GUI.RemoteRenderingWidgetBase.resizeViewportToSizeHint ( )

This method resizes the viewport to the size hint, or the viewport size if the size hint is invalid.

MLAB.Core.RemoteRenderingSlave.setSizeHints() calls this function.

Definition at line 1174 of file GUI.py.

◆ setMaximumSize()

MLAB.GUI.RemoteRenderingWidgetBase.setMaximumSize ( size)

Sets the maximum size of the viewport.

Parameters
sizeAn array with two elements is expected: [width, height]

Definition at line 1181 of file GUI.py.

◆ setMinimumSize()

MLAB.GUI.RemoteRenderingWidgetBase.setMinimumSize ( size)

Sets the maximum size of the viewport.

Parameters
sizeAn array with two elements is expected: [width, height]

Definition at line 1195 of file GUI.py.

◆ setScaleImageOnResize()

MLAB.GUI.RemoteRenderingWidgetBase.setScaleImageOnResize ( flag)

Sets if scaling of the image on the canvas is done on resize.

It is enabled by default.

Parameters
flagFlag if scaling should be done.

Definition at line 1161 of file GUI.py.

◆ setSizeHint()

MLAB.GUI.RemoteRenderingWidgetBase.setSizeHint ( sizeHint)

Sets the size hint for the viewport.

Parameters
sizeHintAn array with two elements is expected: [width, height]

Definition at line 1168 of file GUI.py.

◆ slaveWasAdded()

MLAB.GUI.RemoteRenderingWidgetBase.slaveWasAdded ( )

Called from the slave when it is added.

If this control is visible, then the slave is enabled. Otherwise the slave will be enabled when the control is shown (_setVisible()).

Definition at line 1136 of file GUI.py.

◆ useSizeHintHeight()

MLAB.GUI.RemoteRenderingWidgetBase.useSizeHintHeight ( )

Returns true if the height of the size hint should be used.

Returns
A boolean value.

Definition at line 1216 of file GUI.py.

◆ useSizeHintWidth()

MLAB.GUI.RemoteRenderingWidgetBase.useSizeHintWidth ( )

Returns true if the width of the size hint should be used.

Returns
A boolean value.

Definition at line 1209 of file GUI.py.

◆ viewportSizeChanged()

MLAB.GUI.RemoteRenderingWidgetBase.viewportSizeChanged ( width,
height )

Is emitted when the size of the viewport has changed.

Parameters
widthnew width
heightnew height

Definition at line 1241 of file GUI.py.


The documentation for this class was generated from the following file:
  • C:/jh/mevislab/5.0_0/build/doc.gen/public/SDK/MeVisLabWebToolkitReference/source/MLAB/GUI.py