Copyright | Will Thompson, Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria (garetxe@gmail.com) |
Safe Haskell | None |
Language | Haskell2010 |
RecentChooserDialog
is a dialog box suitable for displaying the recently
used documents. This widgets works by putting a RecentChooserWidget
inside
a Dialog
. It exposes the RecentChooserIface
interface, so you can use
all the RecentChooser
functions on the recent chooser dialog as well as
those for Dialog
.
Note that RecentChooserDialog
does not have any methods of its own.
Instead, you should use the functions that work on a RecentChooser
.
## {gtkrecentchooser
-typical-usage}
In the simplest of cases, you can use the following code to use
a RecentChooserDialog
to select a recently used file:
C code
GtkWidget *dialog; gint res; dialog = gtk_recent_chooser_dialog_new ("Recent Documents", parent_window, _("_Cancel"), GTK_RESPONSE_CANCEL, _("_Open"), GTK_RESPONSE_ACCEPT, NULL); res = gtk_dialog_run (GTK_DIALOG (dialog)); if (res == GTK_RESPONSE_ACCEPT) { GtkRecentInfo *info; GtkRecentChooser *chooser = GTK_RECENT_CHOOSER (dialog); info = gtk_recent_chooser_get_current_item (chooser); open_file (gtk_recent_info_get_uri (info)); gtk_recent_info_unref (info); } gtk_widget_destroy (dialog);
Recently used files are supported since GTK+ 2.10.
Exported types
newtype RecentChooserDialog Source #
GObject RecentChooserDialog Source # | |
IsImplementorIface RecentChooserDialog Source # | |
IsObject RecentChooserDialog Source # | |
IsWindow RecentChooserDialog Source # | |
IsWidget RecentChooserDialog Source # | |
IsDialog RecentChooserDialog Source # | |
IsContainer RecentChooserDialog Source # | |
IsBin RecentChooserDialog Source # | |
IsRecentChooser RecentChooserDialog Source # | |
IsBuildable RecentChooserDialog Source # | |
IsRecentChooserDialog RecentChooserDialog Source # | |
((~) * info (ResolveRecentChooserDialogMethod t RecentChooserDialog), MethodInfo * info RecentChooserDialog p) => IsLabel t (RecentChooserDialog -> p) Source # | |
((~) * info (ResolveRecentChooserDialogMethod t RecentChooserDialog), MethodInfo * info RecentChooserDialog p) => IsLabelProxy t (RecentChooserDialog -> p) Source # | |
HasAttributeList * RecentChooserDialog Source # | |
type AttributeList RecentChooserDialog Source # | |
type SignalList RecentChooserDialog Source # | |
class GObject o => IsRecentChooserDialog o Source #
toRecentChooserDialog :: IsRecentChooserDialog o => o -> IO RecentChooserDialog Source #