Skip to content

OmeroBrowserDialog

OmeroBrowserDialog

OmeroBrowserDialog(parent=None, *, gateway: OmeroGateway | None = None, multiselect: bool = True)

Bases: QDialog

Resizable dialog for browsing an OMERO server and selecting images.

Usage::

dlg = OmeroBrowserDialog(parent, gateway=my_gateway)
if dlg.exec() == QDialog.DialogCode.Accepted:
    images = dlg.get_selected_images()
    # images is a list of OMERO ImageWrapper objects
Signals

images_selected(list) Emitted with a list of OMERO ImageWrapper objects when the user clicks Import or double-clicks an image.

select_images classmethod

select_images(parent=None, *, gateway: OmeroGateway | None = None, multiselect: bool = True) -> list

Show login if needed, then browse and return selected images.

Parameters:

Name Type Description Default
parent

Optional parent widget.

None
gateway OmeroGateway | None

Optional pre-connected :class:OmeroGateway.

None
multiselect bool

When True (default) the user can select multiple images. Pass False to restrict selection to a single image.

True
Returns
required
If
required
again
required

select_image_contexts classmethod

select_image_contexts(parent=None, *, gateway: OmeroGateway | None = None, multiselect: bool = True) -> list[SelectedImageContext]

Show login if needed, then browse and return selected contexts.

Parameters:

Name Type Description Default
parent

Optional parent widget.

None
gateway OmeroGateway | None

Optional pre-connected :class:OmeroGateway.

None
multiselect bool

When True (default) the user can select multiple images. Pass False to restrict selection to a single image.

True

get_selected_images

get_selected_images() -> list

Return the list of selected OMERO ImageWrapper objects.

get_selected_image_contexts

get_selected_image_contexts() -> list[SelectedImageContext]

Return structured selection data for the selected images.