Skip to content

Filmstock Selector

filmstock_selector

Widget to select film stocks.

Classes:

FilmStockSelector

FilmStockSelector(film_stocks, main_parent, parent, **kwargs)

Bases: QWidget

A combobox for selecting camera and print film stocks.

Combobox style UI element that lets you select a film stock and can open a pop-up window for more detailed information on the various film stocks.

Parameters:

  • film_stocks

    lList of film stocks to choose from.

  • **kwargs

    Arguments passed to FilmStockSelectorWindow.

Methods:

  • open_selector

    Opens the FilmStockSelectorWindow when clicking on the looking-glass button.

open_selector

open_selector()

Opens the FilmStockSelectorWindow when clicking on the looking-glass button.

FilmStockSelectorWindow

FilmStockSelectorWindow(
    parent=None,
    film_stocks=None,
    sort_keys=None,
    group_keys=None,
    list_keys=None,
    sidebar_keys=None,
    default_sort=None,
    default_group=None,
    default_filter=None,
    highlighted_stock=None,
    image_key=None,
    view_state=None,
)

Bases: QDialog

A pop-up window for selecting camera and print film stocks.

Popup window which lets you choose a film stock with more detailed info. Has a tabular view with some details and a grid view with thumbnail color checkers. Lets you sort and group by keys and has a search field. Shows detailed info of the currently selected film stock on the sidebar.

Parameters:

  • parent

    Parent widget.

  • film_stocks

    List of film stocks to choose from.

  • sort_keys

    Keys by which the film stocks can be sorted by.

  • group_keys

    Keys by which the film stocks can be grouped by.

  • list_keys

    Keys for attributes that show up in the list view.

  • sidebar_keys

    Keys for attributes that show up in the sidebar view.

  • default_sort

    Default sort key.

  • default_group

    Default group key.

  • highlighted_stock

    Currently highlighted stock.

  • image_key

    Key of the image used in the grid and sidebar view.

Methods:

sort_and_group_stocks

sort_and_group_stocks()

Returns:

  • dict

    Sorted, filtered, and grouped film stocks.