Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
CustomFilter
is a Filter
that uses a callback to determine
whether to include an item or not.
Synopsis
- newtype CustomFilter = CustomFilter (ManagedPtr CustomFilter)
- class (GObject o, IsDescendantOf CustomFilter o) => IsCustomFilter o
- toCustomFilter :: (MonadIO m, IsCustomFilter o) => o -> m CustomFilter
- customFilterNew :: (HasCallStack, MonadIO m) => Maybe CustomFilterFunc -> m CustomFilter
- customFilterSetFilterFunc :: (HasCallStack, MonadIO m, IsCustomFilter a) => a -> Maybe CustomFilterFunc -> m ()
Exported types
newtype CustomFilter Source #
Memory-managed wrapper type.
CustomFilter (ManagedPtr CustomFilter) |
Instances
Eq CustomFilter Source # | |
Defined in GI.Gtk.Objects.CustomFilter (==) :: CustomFilter -> CustomFilter -> Bool # (/=) :: CustomFilter -> CustomFilter -> Bool # | |
GObject CustomFilter Source # | |
Defined in GI.Gtk.Objects.CustomFilter | |
ManagedPtrNewtype CustomFilter Source # | |
Defined in GI.Gtk.Objects.CustomFilter toManagedPtr :: CustomFilter -> ManagedPtr CustomFilter | |
TypedObject CustomFilter Source # | |
Defined in GI.Gtk.Objects.CustomFilter | |
HasParentTypes CustomFilter Source # | |
Defined in GI.Gtk.Objects.CustomFilter | |
IsGValue (Maybe CustomFilter) Source # | Convert |
Defined in GI.Gtk.Objects.CustomFilter gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe CustomFilter -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe CustomFilter) | |
type ParentTypes CustomFilter Source # | |
Defined in GI.Gtk.Objects.CustomFilter |
class (GObject o, IsDescendantOf CustomFilter o) => IsCustomFilter o Source #
Type class for types which can be safely cast to CustomFilter
, for instance with toCustomFilter
.
Instances
(GObject o, IsDescendantOf CustomFilter o) => IsCustomFilter o Source # | |
Defined in GI.Gtk.Objects.CustomFilter |
toCustomFilter :: (MonadIO m, IsCustomFilter o) => o -> m CustomFilter Source #
Cast to CustomFilter
, for types for which this is known to be safe. For general casts, use castTo
.
Methods
Click to display all available methods, including inherited ones
Methods
bindProperty, bindPropertyFull, changed, forceFloating, freezeNotify, getv, isFloating, match, notify, notifyByPspec, ref, refSink, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getData, getProperty, getQdata, getStrictness.
Setters
new
:: (HasCallStack, MonadIO m) | |
=> Maybe CustomFilterFunc |
|
-> m CustomFilter | Returns: a new |
Creates a new filter using the given matchFunc
to filter
items.
If matchFunc
is Nothing
, the filter matches all items.
If the filter func changes its filtering behavior,
filterChanged
needs to be called.
setFilterFunc
customFilterSetFilterFunc Source #
:: (HasCallStack, MonadIO m, IsCustomFilter a) | |
=> a |
|
-> Maybe CustomFilterFunc |
|
-> m () |
Sets (or unsets) the function used for filtering items.
If matchFunc
is Nothing
, the filter matches all items.
If the filter func changes its filtering behavior,
filterChanged
needs to be called.
If a previous function was set, its userDestroy
will be
called now.