Copyright | Will Thompson and Iñaki García Etxebarria |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | None |
Language | Haskell2010 |
GI.Gtk.Objects.FileDialog
Contents
- Exported types
- Methods
- getAcceptLabel
- getDefaultFilter
- getFilters
- getInitialFile
- getInitialFolder
- getInitialName
- getModal
- getTitle
- new
- open
- openFinish
- openMultiple
- openMultipleFinish
- openMultipleTextFiles
- openMultipleTextFilesFinish
- openTextFile
- openTextFileFinish
- save
- saveFinish
- saveTextFile
- saveTextFileFinish
- selectFolder
- selectFolderFinish
- selectMultipleFolders
- selectMultipleFoldersFinish
- setAcceptLabel
- setDefaultFilter
- setFilters
- setInitialFile
- setInitialFolder
- setInitialName
- setModal
- setTitle
- Properties
Description
Asynchronous API to present a file chooser dialog.
GtkFileDialog
collects the arguments that are needed to present
the dialog to the user, such as a title for the dialog and whether
it should be modal.
The dialog is shown with fileDialogOpen
,
fileDialogSave
, etc.
Since: 4.10
Synopsis
- newtype FileDialog = FileDialog (ManagedPtr FileDialog)
- class (GObject o, IsDescendantOf FileDialog o) => IsFileDialog o
- toFileDialog :: (MonadIO m, IsFileDialog o) => o -> m FileDialog
- fileDialogGetAcceptLabel :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m (Maybe Text)
- fileDialogGetDefaultFilter :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m (Maybe FileFilter)
- fileDialogGetFilters :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m (Maybe ListModel)
- fileDialogGetInitialFile :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m (Maybe File)
- fileDialogGetInitialFolder :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m (Maybe File)
- fileDialogGetInitialName :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m (Maybe Text)
- fileDialogGetModal :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m Bool
- fileDialogGetTitle :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> m Text
- fileDialogNew :: (HasCallStack, MonadIO m) => m FileDialog
- fileDialogOpen :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogOpenFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe File)
- fileDialogOpenMultiple :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogOpenMultipleFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe ListModel)
- fileDialogOpenMultipleTextFiles :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogOpenMultipleTextFilesFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe ListModel, Text)
- fileDialogOpenTextFile :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogOpenTextFileFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe File, Text)
- fileDialogSave :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogSaveFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe File)
- fileDialogSaveTextFile :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogSaveTextFileFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe File, Text, Text)
- fileDialogSelectFolder :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogSelectFolderFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe File)
- fileDialogSelectMultipleFolders :: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) => a -> Maybe b -> Maybe c -> Maybe AsyncReadyCallback -> m ()
- fileDialogSelectMultipleFoldersFinish :: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) => a -> b -> m (Maybe ListModel)
- fileDialogSetAcceptLabel :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> Maybe Text -> m ()
- fileDialogSetDefaultFilter :: (HasCallStack, MonadIO m, IsFileDialog a, IsFileFilter b) => a -> Maybe b -> m ()
- fileDialogSetFilters :: (HasCallStack, MonadIO m, IsFileDialog a, IsListModel b) => a -> Maybe b -> m ()
- fileDialogSetInitialFile :: (HasCallStack, MonadIO m, IsFileDialog a, IsFile b) => a -> Maybe b -> m ()
- fileDialogSetInitialFolder :: (HasCallStack, MonadIO m, IsFileDialog a, IsFile b) => a -> Maybe b -> m ()
- fileDialogSetInitialName :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> Maybe Text -> m ()
- fileDialogSetModal :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> Bool -> m ()
- fileDialogSetTitle :: (HasCallStack, MonadIO m, IsFileDialog a) => a -> Text -> m ()
- clearFileDialogAcceptLabel :: (MonadIO m, IsFileDialog o) => o -> m ()
- constructFileDialogAcceptLabel :: (IsFileDialog o, MonadIO m) => Text -> m (GValueConstruct o)
- getFileDialogAcceptLabel :: (MonadIO m, IsFileDialog o) => o -> m (Maybe Text)
- setFileDialogAcceptLabel :: (MonadIO m, IsFileDialog o) => o -> Text -> m ()
- clearFileDialogDefaultFilter :: (MonadIO m, IsFileDialog o) => o -> m ()
- constructFileDialogDefaultFilter :: (IsFileDialog o, MonadIO m, IsFileFilter a) => a -> m (GValueConstruct o)
- getFileDialogDefaultFilter :: (MonadIO m, IsFileDialog o) => o -> m (Maybe FileFilter)
- setFileDialogDefaultFilter :: (MonadIO m, IsFileDialog o, IsFileFilter a) => o -> a -> m ()
- clearFileDialogFilters :: (MonadIO m, IsFileDialog o) => o -> m ()
- constructFileDialogFilters :: (IsFileDialog o, MonadIO m, IsListModel a) => a -> m (GValueConstruct o)
- getFileDialogFilters :: (MonadIO m, IsFileDialog o) => o -> m (Maybe ListModel)
- setFileDialogFilters :: (MonadIO m, IsFileDialog o, IsListModel a) => o -> a -> m ()
- clearFileDialogInitialFile :: (MonadIO m, IsFileDialog o) => o -> m ()
- constructFileDialogInitialFile :: (IsFileDialog o, MonadIO m, IsFile a) => a -> m (GValueConstruct o)
- getFileDialogInitialFile :: (MonadIO m, IsFileDialog o) => o -> m (Maybe File)
- setFileDialogInitialFile :: (MonadIO m, IsFileDialog o, IsFile a) => o -> a -> m ()
- clearFileDialogInitialFolder :: (MonadIO m, IsFileDialog o) => o -> m ()
- constructFileDialogInitialFolder :: (IsFileDialog o, MonadIO m, IsFile a) => a -> m (GValueConstruct o)
- getFileDialogInitialFolder :: (MonadIO m, IsFileDialog o) => o -> m (Maybe File)
- setFileDialogInitialFolder :: (MonadIO m, IsFileDialog o, IsFile a) => o -> a -> m ()
- clearFileDialogInitialName :: (MonadIO m, IsFileDialog o) => o -> m ()
- constructFileDialogInitialName :: (IsFileDialog o, MonadIO m) => Text -> m (GValueConstruct o)
- getFileDialogInitialName :: (MonadIO m, IsFileDialog o) => o -> m (Maybe Text)
- setFileDialogInitialName :: (MonadIO m, IsFileDialog o) => o -> Text -> m ()
- constructFileDialogModal :: (IsFileDialog o, MonadIO m) => Bool -> m (GValueConstruct o)
- getFileDialogModal :: (MonadIO m, IsFileDialog o) => o -> m Bool
- setFileDialogModal :: (MonadIO m, IsFileDialog o) => o -> Bool -> m ()
- constructFileDialogTitle :: (IsFileDialog o, MonadIO m) => Text -> m (GValueConstruct o)
- getFileDialogTitle :: (MonadIO m, IsFileDialog o) => o -> m Text
- setFileDialogTitle :: (MonadIO m, IsFileDialog o) => o -> Text -> m ()
Exported types
newtype FileDialog Source #
Memory-managed wrapper type.
Constructors
FileDialog (ManagedPtr FileDialog) |
Instances
Eq FileDialog Source # | |
Defined in GI.Gtk.Objects.FileDialog | |
GObject FileDialog Source # | |
Defined in GI.Gtk.Objects.FileDialog | |
ManagedPtrNewtype FileDialog Source # | |
Defined in GI.Gtk.Objects.FileDialog Methods | |
TypedObject FileDialog Source # | |
Defined in GI.Gtk.Objects.FileDialog | |
HasParentTypes FileDialog Source # | |
Defined in GI.Gtk.Objects.FileDialog | |
IsGValue (Maybe FileDialog) Source # | Convert |
Defined in GI.Gtk.Objects.FileDialog Methods gvalueGType_ :: IO GType # gvalueSet_ :: Ptr GValue -> Maybe FileDialog -> IO () # gvalueGet_ :: Ptr GValue -> IO (Maybe FileDialog) # | |
type ParentTypes FileDialog Source # | |
Defined in GI.Gtk.Objects.FileDialog type ParentTypes FileDialog = '[Object] |
class (GObject o, IsDescendantOf FileDialog o) => IsFileDialog o Source #
Type class for types which can be safely cast to FileDialog
, for instance with toFileDialog
.
Instances
(GObject o, IsDescendantOf FileDialog o) => IsFileDialog o Source # | |
Defined in GI.Gtk.Objects.FileDialog |
toFileDialog :: (MonadIO m, IsFileDialog o) => o -> m FileDialog Source #
Cast to FileDialog
, 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, forceFloating, freezeNotify, getv, isFloating, notify, notifyByPspec, open, openFinish, openMultiple, openMultipleFinish, openMultipleTextFiles, openMultipleTextFilesFinish, openTextFile, openTextFileFinish, ref, refSink, runDispose, save, saveFinish, saveTextFile, saveTextFileFinish, selectFolder, selectFolderFinish, selectMultipleFolders, selectMultipleFoldersFinish, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getAcceptLabel, getData, getDefaultFilter, getFilters, getInitialFile, getInitialFolder, getInitialName, getModal, getProperty, getQdata, getTitle.
Setters
setAcceptLabel, setData, setDataFull, setDefaultFilter, setFilters, setInitialFile, setInitialFolder, setInitialName, setModal, setProperty, setTitle.
getAcceptLabel
fileDialogGetAcceptLabel Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m (Maybe Text) | Returns: the label shown on the file chooser's accept button |
Retrieves the text used by the dialog on its accept button.
Since: 4.10
getDefaultFilter
fileDialogGetDefaultFilter Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m (Maybe FileFilter) | Returns: the default filter |
Gets the filter that will be selected by default in the file chooser dialog.
Since: 4.10
getFilters
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m (Maybe ListModel) | Returns: the filters,
as a list model of |
Gets the filters that will be offered to the user in the file chooser dialog.
Since: 4.10
getInitialFile
fileDialogGetInitialFile Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m (Maybe File) | Returns: the file |
Gets the file that will be initially selected in the file chooser dialog.
Since: 4.10
getInitialFolder
fileDialogGetInitialFolder Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m (Maybe File) | Returns: the folder |
Gets the folder that will be set as the initial folder in the file chooser dialog.
Since: 4.10
getInitialName
fileDialogGetInitialName Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m (Maybe Text) | Returns: the name |
Gets the filename that will be initially selected.
Since: 4.10
getModal
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m Bool | Returns: true if the file chooser dialog is modal |
Returns whether the file chooser dialog blocks interaction with the parent window while it is presented.
Since: 4.10
getTitle
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> m Text | Returns: the title |
Returns the title that will be shown on the file chooser dialog.
Since: 4.10
new
Arguments
:: (HasCallStack, MonadIO m) | |
=> m FileDialog | Returns: the new |
Creates a new GtkFileDialog
object.
Since: 4.10
open
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Presents a file chooser dialog to the user.
The file chooser dialog will be set up to select a single file.
The callback
will be called when the dialog is dismissed.
Since: 4.10
openFinish
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe File) | Returns: the file that was selected (Can throw |
Finishes the fileDialogOpen
call.
Since: 4.10
openMultiple
fileDialogOpenMultiple Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Presents a file chooser dialog to the user.
The file chooser dialog will be set up to select multiple files.
The file chooser dialog will initially be opened in the directory FileDialog:initialFolder.
The callback
will be called when the dialog is dismissed.
Since: 4.10
openMultipleFinish
fileDialogOpenMultipleFinish Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe ListModel) | Returns: the files that were selected,
as a list model of |
Finishes the fileDialogOpen
call.
Since: 4.10
openMultipleTextFiles
fileDialogOpenMultipleTextFiles Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Presents a file chooser dialog to the user.
The file chooser dialog will be set up to select multiple files.
The file chooser dialog will initially be opened in the directory FileDialog:initialFolder.
In contrast to fileDialogOpen
, this function
lets the user select the text encoding for the files, if possible.
The callback
will be called when the dialog is dismissed.
Since: 4.18
openMultipleTextFilesFinish
fileDialogOpenMultipleTextFilesFinish Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe ListModel, Text) | Returns: the files that were selected,
as a list model of |
Finishes the fileDialogOpen
call.
Since: 4.18
openTextFile
fileDialogOpenTextFile Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Initiates a file selection operation by presenting a file chooser dialog to the user.
In contrast to fileDialogOpen
, this function
lets the user select the text encoding for the file, if possible.
The callback
will be called when the dialog is dismissed.
Since: 4.18
openTextFileFinish
fileDialogOpenTextFileFinish Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe File, Text) | Returns: the file that was selected (Can throw |
Finishes the fileDialogOpenTextFile
call
and returns the resulting file and text encoding.
If the user has explicitly selected a text encoding to use
for the file, then encoding
will be set to a codeset name that
is suitable for passing to iconv_open()
. Otherwise, it will
be NULL
.
Since: 4.18
save
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Presents a file chooser dialog to the user.
The file chooser dialog will be save mode.
The callback
will be called when the dialog is dismissed.
Since: 4.10
saveFinish
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe File) | Returns: the file that was selected (Can throw |
Finishes the fileDialogSave
call.
Since: 4.10
saveTextFile
fileDialogSaveTextFile Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Initiates a file save operation by presenting a file chooser dialog to the user.
In contrast to fileDialogSave
, this function
lets the user select the text encoding and line endings for
the text file, if possible.
The callback
will be called when the dialog is dismissed.
Since: 4.18
saveTextFileFinish
fileDialogSaveTextFileFinish Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe File, Text, Text) | Returns: the file that was selected.
Otherwise, |
Finishes the fileDialogSaveTextFile
call
and returns the resulting file, text encoding and line endings.
If the user has explicitly selected a text encoding to use
for the file, then encoding
will be set to a codeset name that
is suitable for passing to iconv_open()
. Otherwise, it will
be NULL
.
The lineEnding
will be set to one of "\n", "\r\n", "\r" or "",
where the latter means to preserve existing line endings.
Since: 4.18
selectFolder
fileDialogSelectFolder Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Presents a file chooser dialog to the user.
The file chooser dialog will be set up to select a single folder.
If you pass initialFolder
, the file chooser dialog will initially
be opened in the parent directory of that folder, otherwise, it
will be in the directory FileDialog:initialFolder.
The callback
will be called when the dialog is dismissed.
Since: 4.10
selectFolderFinish
fileDialogSelectFolderFinish Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe File) | Returns: the folder that was selected (Can throw |
Finishes the fileDialogSelectFolder
call.
Since: 4.10
selectMultipleFolders
fileDialogSelectMultipleFolders Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsWindow b, IsCancellable c) | |
=> a |
|
-> Maybe b |
|
-> Maybe c |
|
-> Maybe AsyncReadyCallback |
|
-> m () |
Presents a file chooser dialog to the user.
The file chooser dialog will be set up to allow selecting multiple folders.
The file chooser dialog will initially be opened in the directory FileDialog:initialFolder.
The callback
will be called when the dialog is dismissed.
Since: 4.10
selectMultipleFoldersFinish
fileDialogSelectMultipleFoldersFinish Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsAsyncResult b) | |
=> a |
|
-> b |
|
-> m (Maybe ListModel) | Returns: the folders that were selected,
as a list model of |
Finishes the fileDialogSelectMultipleFolders
call.
Since: 4.10
setAcceptLabel
fileDialogSetAcceptLabel Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> Maybe Text |
|
-> m () |
Sets the label shown on the file chooser's accept button.
Leaving the accept label unset or setting it as NULL
will
fall back to a default label, depending on what API is used
to launch the file dialog.
Since: 4.10
setDefaultFilter
fileDialogSetDefaultFilter Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsFileFilter b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets the filter that will be selected by default in the file chooser dialog.
If set to NULL
, the first item in FileDialog:filters
will be used as the default filter. If that list is empty, the dialog
will be unfiltered.
Since: 4.10
setFilters
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsListModel b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets the filters that will be offered to the user in the file chooser dialog.
Since: 4.10
setInitialFile
fileDialogSetInitialFile Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsFile b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets the file that will be initially selected in the file chooser dialog.
This function is a shortcut for calling both
fileDialogSetInitialFolder
and
fileDialogSetInitialName
with the
directory and name of file
, respectively.
Since: 4.10
setInitialFolder
fileDialogSetInitialFolder Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a, IsFile b) | |
=> a |
|
-> Maybe b |
|
-> m () |
Sets the folder that will be set as the initial folder in the file chooser dialog.
Since: 4.10
setInitialName
fileDialogSetInitialName Source #
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> Maybe Text |
|
-> m () |
Sets the filename that will be initially selected.
For save dialogs, name
will usually be pre-entered into the
name field.
If a file with this name already exists in the directory set via FileDialog:initialFolder, the dialog will preselect it.
Since: 4.10
setModal
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> Bool |
|
-> m () |
Sets whether the file chooser dialog blocks interaction with the parent window while it is presented.
Since: 4.10
setTitle
Arguments
:: (HasCallStack, MonadIO m, IsFileDialog a) | |
=> a |
|
-> Text |
|
-> m () |
Sets the title that will be shown on the file chooser dialog.
Since: 4.10
Properties
acceptLabel
Label for the file chooser's accept button.
Since: 4.10
clearFileDialogAcceptLabel :: (MonadIO m, IsFileDialog o) => o -> m () Source #
Set the value of the “accept-label
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#acceptLabel
constructFileDialogAcceptLabel :: (IsFileDialog o, MonadIO m) => Text -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “accept-label
” property. This is rarely needed directly, but it is used by new
.
getFileDialogAcceptLabel :: (MonadIO m, IsFileDialog o) => o -> m (Maybe Text) Source #
Get the value of the “accept-label
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #acceptLabel
setFileDialogAcceptLabel :: (MonadIO m, IsFileDialog o) => o -> Text -> m () Source #
Set the value of the “accept-label
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #acceptLabel:=
value ]
defaultFilter
The default filter.
This filter is initially active in the file chooser dialog.
If the default filter is NULL
, the first filter of FileDialog:filters
is used as the default filter. If that property contains no filter, the dialog will
be unfiltered.
If FileDialog:filters is not NULL
, the default filter should be
part of the list. If it is not, the dialog may choose to not make it available.
Since: 4.10
clearFileDialogDefaultFilter :: (MonadIO m, IsFileDialog o) => o -> m () Source #
Set the value of the “default-filter
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#defaultFilter
constructFileDialogDefaultFilter :: (IsFileDialog o, MonadIO m, IsFileFilter a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “default-filter
” property. This is rarely needed directly, but it is used by new
.
getFileDialogDefaultFilter :: (MonadIO m, IsFileDialog o) => o -> m (Maybe FileFilter) Source #
Get the value of the “default-filter
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #defaultFilter
setFileDialogDefaultFilter :: (MonadIO m, IsFileDialog o, IsFileFilter a) => o -> a -> m () Source #
Set the value of the “default-filter
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #defaultFilter:=
value ]
filters
The list of filters.
See FileDialog:defaultFilter about how these two properties interact.
Since: 4.10
clearFileDialogFilters :: (MonadIO m, IsFileDialog o) => o -> m () Source #
Set the value of the “filters
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#filters
constructFileDialogFilters :: (IsFileDialog o, MonadIO m, IsListModel a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “filters
” property. This is rarely needed directly, but it is used by new
.
getFileDialogFilters :: (MonadIO m, IsFileDialog o) => o -> m (Maybe ListModel) Source #
Get the value of the “filters
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #filters
setFileDialogFilters :: (MonadIO m, IsFileDialog o, IsListModel a) => o -> a -> m () Source #
Set the value of the “filters
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #filters:=
value ]
initialFile
The initial file.
This file is initially selected in the file chooser dialog
This is a utility property that sets both FileDialog:initialFolder and FileDialog:initialName.
Since: 4.10
clearFileDialogInitialFile :: (MonadIO m, IsFileDialog o) => o -> m () Source #
Set the value of the “initial-file
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#initialFile
constructFileDialogInitialFile :: (IsFileDialog o, MonadIO m, IsFile a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “initial-file
” property. This is rarely needed directly, but it is used by new
.
getFileDialogInitialFile :: (MonadIO m, IsFileDialog o) => o -> m (Maybe File) Source #
Get the value of the “initial-file
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #initialFile
setFileDialogInitialFile :: (MonadIO m, IsFileDialog o, IsFile a) => o -> a -> m () Source #
Set the value of the “initial-file
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #initialFile:=
value ]
initialFolder
The initial folder.
This is the directory that is initially opened in the file chooser dialog.
Since: 4.10
clearFileDialogInitialFolder :: (MonadIO m, IsFileDialog o) => o -> m () Source #
Set the value of the “initial-folder
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#initialFolder
constructFileDialogInitialFolder :: (IsFileDialog o, MonadIO m, IsFile a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “initial-folder
” property. This is rarely needed directly, but it is used by new
.
getFileDialogInitialFolder :: (MonadIO m, IsFileDialog o) => o -> m (Maybe File) Source #
Get the value of the “initial-folder
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #initialFolder
setFileDialogInitialFolder :: (MonadIO m, IsFileDialog o, IsFile a) => o -> a -> m () Source #
Set the value of the “initial-folder
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #initialFolder:=
value ]
initialName
The initial name.
This is the name of the file that is initially selected in the file chooser dialog.
Since: 4.10
clearFileDialogInitialName :: (MonadIO m, IsFileDialog o) => o -> m () Source #
Set the value of the “initial-name
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#initialName
constructFileDialogInitialName :: (IsFileDialog o, MonadIO m) => Text -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “initial-name
” property. This is rarely needed directly, but it is used by new
.
getFileDialogInitialName :: (MonadIO m, IsFileDialog o) => o -> m (Maybe Text) Source #
Get the value of the “initial-name
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #initialName
setFileDialogInitialName :: (MonadIO m, IsFileDialog o) => o -> Text -> m () Source #
Set the value of the “initial-name
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #initialName:=
value ]
modal
Whether the file chooser dialog is modal.
Since: 4.10
constructFileDialogModal :: (IsFileDialog o, MonadIO m) => Bool -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “modal
” property. This is rarely needed directly, but it is used by new
.
getFileDialogModal :: (MonadIO m, IsFileDialog o) => o -> m Bool Source #
Get the value of the “modal
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #modal
setFileDialogModal :: (MonadIO m, IsFileDialog o) => o -> Bool -> m () Source #
Set the value of the “modal
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #modal:=
value ]
title
A title that may be shown on the file chooser dialog.
Since: 4.10
constructFileDialogTitle :: (IsFileDialog o, MonadIO m) => Text -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “title
” property. This is rarely needed directly, but it is used by new
.
getFileDialogTitle :: (MonadIO m, IsFileDialog o) => o -> m Text Source #
Get the value of the “title
” property.
When overloading is enabled, this is equivalent to
get
fileDialog #title
setFileDialogTitle :: (MonadIO m, IsFileDialog o) => o -> Text -> m () Source #
Set the value of the “title
” property.
When overloading is enabled, this is equivalent to
set
fileDialog [ #title:=
value ]