IPluginPreview

class mobase.IPluginPreview

Bases: IPlugin

These plugins add support for previewing files in the data pane. Right now all image formats supported by qt are implemented (including dds) but no audio files and no 3d mesh formats.

Methods Summary

genFilePreview(filename, max_size)

Generate a preview for the specified file.

supportedExtensions()

rtype:

Set[str]

Methods Documentation

abstract genFilePreview(filename, max_size)

Generate a preview for the specified file.

Return type:

QWidget

Parameters:
  • filename – Path to the file to preview.

  • max_size – Maximum size of the generated widget.

Returns:

The widget showing a preview of the file.

abstract supportedExtensions()
Return type:

Set[str]

Returns:

The list of file extensions that are supported by this preview plugin.