Home / Lua API Manual / darktable / darktable.gui / darktable.gui.libs / darktable.gui.libs.filter
< darktable.gui.libs.filmstrip
darktable.gui.libs.geotagging >

# darktable.gui.libs.filter

The image-filter menus at the top of the UI

Attributes:

- has_tostring
- parent : types.dt_lua_lib_t

## 🔗darktable.gui.libs.filter.sort

    function(
      [sort : types.dt_collection_sort_t]
    ) : types.dt_collection_sort_t

Change the collection sort field.

- [sort] - types.dt_collection_sort_t - The new field to sort by. If empty the current sort field is unchanged
- return - types.dt_collection_sort_t = The current sort field.

## 🔗darktable.gui.libs.filter.sort_order

    function(
      [order : types.dt_collection_sort_order_t]
    ) : types.dt_collection_sort_order_t

Change the collection sort order.

- [order] - types.dt_collection_sort_order_t - The order to sort by. If empty the current sort order is unchanged.
- return - types.dt_collection_sort_order_t - The current sort order.

## 🔗darktable.gui.libs.filter.rating

    function(
      [rating : types.dt_collection_filter_t]
    ) : types.dt_collection_filter_t

Change the collection rating filter.

- [rating] - types.dt_collection_filter_t - The new rating field to filter by. If empty the current rating field is unchanged.
- return - types.dt_collection_filter_t - The current rating field.

## 🔗darktable.gui.libs.filter.rating_comparator

    function(
      [comparator : types.dt_collection_rating_comperator_t]
    ) : types.dt_collection_rating_comperator_t

Change the collection filter comparison field.

- [comparator] - types.dt_collection_rating_comperator_t - The new comparison field to filter the rating by. If empty the current rating comparison field is unchanged
- return - types.dt_collection_rating_comperator_t - The current rating comparison field

< darktable.gui.libs.filmstrip
darktable.gui.libs.geotagging >