| Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte | 
|---|---|
| License | LGPL-2.1 | 
| Maintainer | Iñaki García Etxebarria | 
| Safe Haskell | None | 
| Language | Haskell2010 | 
GI.Gtk.Objects.RecentAction
Description
A RecentAction represents a list of recently used files, which
 can be shown by widgets such as RecentChooserDialog or
 RecentChooserMenu.
To construct a submenu showing recently used files, use a RecentAction
 as the action for a <menuitem>. To construct a menu toolbutton showing
 the recently used files in the popup menu, use a RecentAction as the
 action for a <toolitem> element.
Synopsis
- newtype RecentAction = RecentAction (ManagedPtr RecentAction)
 - class (GObject o, IsDescendantOf RecentAction o) => IsRecentAction o
 - toRecentAction :: (MonadIO m, IsRecentAction o) => o -> m RecentAction
 - recentActionGetShowNumbers :: (HasCallStack, MonadIO m, IsRecentAction a) => a -> m Bool
 - recentActionNew :: (HasCallStack, MonadIO m) => Text -> Maybe Text -> Maybe Text -> Maybe Text -> m RecentAction
 - recentActionNewForManager :: (HasCallStack, MonadIO m, IsRecentManager a) => Text -> Maybe Text -> Maybe Text -> Maybe Text -> Maybe a -> m RecentAction
 - recentActionSetShowNumbers :: (HasCallStack, MonadIO m, IsRecentAction a) => a -> Bool -> m ()
 - constructRecentActionShowNumbers :: (IsRecentAction o, MonadIO m) => Bool -> m (GValueConstruct o)
 - getRecentActionShowNumbers :: (MonadIO m, IsRecentAction o) => o -> m Bool
 - setRecentActionShowNumbers :: (MonadIO m, IsRecentAction o) => o -> Bool -> m ()
 
Exported types
newtype RecentAction Source #
Memory-managed wrapper type.
Constructors
| RecentAction (ManagedPtr RecentAction) | 
Instances
| Eq RecentAction Source # | |
Defined in GI.Gtk.Objects.RecentAction  | |
| IsGValue RecentAction Source # | Convert   | 
Defined in GI.Gtk.Objects.RecentAction  | |
| GObject RecentAction Source # | |
Defined in GI.Gtk.Objects.RecentAction Methods gobjectType :: IO GType #  | |
| HasParentTypes RecentAction Source # | |
Defined in GI.Gtk.Objects.RecentAction  | |
| type ParentTypes RecentAction Source # | |
Defined in GI.Gtk.Objects.RecentAction  | |
class (GObject o, IsDescendantOf RecentAction o) => IsRecentAction o Source #
Type class for types which can be safely cast to RecentAction, for instance with toRecentAction.
Instances
| (GObject o, IsDescendantOf RecentAction o) => IsRecentAction o Source # | |
Defined in GI.Gtk.Objects.RecentAction  | |
toRecentAction :: (MonadIO m, IsRecentAction o) => o -> m RecentAction Source #
Cast to RecentAction, for types for which this is known to be safe. For general casts, use castTo.
Methods
Overloaded methods
getShowNumbers
recentActionGetShowNumbers Source #
Arguments
| :: (HasCallStack, MonadIO m, IsRecentAction a) | |
| => a | 
  | 
| -> m Bool | Returns:   | 
Deprecated: (Since version 3.10)
Returns the value set by recentChooserMenuSetShowNumbers.
Since: 2.12
new
Arguments
| :: (HasCallStack, MonadIO m) | |
| => Text | 
  | 
| -> Maybe Text | 
  | 
| -> Maybe Text | 
  | 
| -> Maybe Text | 
  | 
| -> m RecentAction | Returns: the newly created   | 
Deprecated: (Since version 3.10)
Creates a new RecentAction object. To add the action to
 a ActionGroup and set the accelerator for the action,
 call actionGroupAddActionWithAccel.
Since: 2.12
newForManager
recentActionNewForManager Source #
Arguments
| :: (HasCallStack, MonadIO m, IsRecentManager a) | |
| => Text | 
  | 
| -> Maybe Text | 
  | 
| -> Maybe Text | 
  | 
| -> Maybe Text | 
  | 
| -> Maybe a | 
  | 
| -> m RecentAction | Returns: the newly created   | 
Deprecated: (Since version 3.10)
Creates a new RecentAction object. To add the action to
 a ActionGroup and set the accelerator for the action,
 call actionGroupAddActionWithAccel.
Since: 2.12
setShowNumbers
recentActionSetShowNumbers Source #
Arguments
| :: (HasCallStack, MonadIO m, IsRecentAction a) | |
| => a | 
  | 
| -> Bool | 
  | 
| -> m () | 
Deprecated: (Since version 3.10)
Sets whether a number should be added to the items shown by the
 widgets representing action. The numbers are shown to provide
 a unique character for a mnemonic to be used inside the menu item's
 label. Only the first ten items get a number to avoid clashes.
Since: 2.12
Properties
showNumbers
Whether the items should be displayed with a number.
constructRecentActionShowNumbers :: (IsRecentAction o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct with valid value for the “show-numbers” property. This is rarely needed directly, but it is used by new.
getRecentActionShowNumbers :: (MonadIO m, IsRecentAction o) => o -> m Bool Source #
Get the value of the “show-numbers” property.
 When overloading is enabled, this is equivalent to
get recentAction #showNumbers
setRecentActionShowNumbers :: (MonadIO m, IsRecentAction o) => o -> Bool -> m () Source #
Set the value of the “show-numbers” property.
 When overloading is enabled, this is equivalent to
setrecentAction [ #showNumbers:=value ]