gi-gtksource-3.0.15: GtkSource bindings

CopyrightWill Thompson Iñaki García Etxebarria and Jonas Platte
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria (garetxe@gmail.com)
Safe HaskellNone
LanguageHaskell2010

GI.GtkSource.Objects.FileSaver

Contents

Description

 

Synopsis

Exported types

Methods

getBuffer

fileSaverGetBuffer Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m Buffer

Returns: the Buffer to save.

No description available in the introspection data.

Since: 3.14

getCompressionType

fileSaverGetCompressionType Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m CompressionType

Returns: the compression type.

No description available in the introspection data.

Since: 3.14

getEncoding

fileSaverGetEncoding Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m Encoding

Returns: the encoding.

No description available in the introspection data.

Since: 3.14

getFile

fileSaverGetFile Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m File

Returns: the File.

No description available in the introspection data.

Since: 3.14

getFlags

fileSaverGetFlags Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m [FileSaverFlags]

Returns: the flags.

No description available in the introspection data.

Since: 3.14

getLocation

fileSaverGetLocation Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m File

Returns: the File where to save the buffer to.

No description available in the introspection data.

Since: 3.14

getNewlineType

fileSaverGetNewlineType Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> m NewlineType

Returns: the newline type.

No description available in the introspection data.

Since: 3.14

new

fileSaverNew Source #

Arguments

:: (HasCallStack, MonadIO m, IsBuffer a, IsFile b) 
=> a

buffer: the Buffer to save.

-> b

file: the File.

-> m FileSaver

Returns: a new FileSaver object.

Creates a new FileSaver object. The buffer will be saved to the 'GI.GtkSource.Objects.File.File'\'s location.

This constructor is suitable for a simple "save" operation, when the file already contains a non-Nothing File:location.

Since: 3.14

newWithTarget

fileSaverNewWithTarget Source #

Arguments

:: (HasCallStack, MonadIO m, IsBuffer a, IsFile b, IsFile c) 
=> a

buffer: the Buffer to save.

-> b

file: the File.

-> c

targetLocation: the File where to save the buffer to.

-> m FileSaver

Returns: a new FileSaver object.

Creates a new FileSaver object with a target location. When the file saving is finished successfully, targetLocation is set to the file's File:location property. If an error occurs, the previous valid location is still available in File.

This constructor is suitable for a "save as" operation, or for saving a new buffer for the first time.

Since: 3.14

saveAsync

fileSaverSaveAsync Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a, IsCancellable b) 
=> a

saver: a FileSaver.

-> Int32

ioPriority: the I/O priority of the request. E.g. PRIORITY_LOW, PRIORITY_DEFAULT or PRIORITY_HIGH.

-> Maybe b

cancellable: optional Cancellable object, Nothing to ignore.

-> Maybe FileProgressCallback

progressCallback: function to call back with progress information, or Nothing if progress information is not needed.

-> Maybe AsyncReadyCallback

callback: a AsyncReadyCallback to call when the request is satisfied.

-> m () 

Saves asynchronously the buffer into the file. See the AsyncResult documentation to know how to use this function.

Since: 3.14

saveFinish

fileSaverSaveFinish Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a, IsAsyncResult b) 
=> a

saver: a FileSaver.

-> b

result: a AsyncResult.

-> m ()

(Can throw GError)

Finishes a file saving started with fileSaverSaveAsync.

If the file has been saved successfully, the following File properties will be updated: the location, the encoding, the newline type and the compression type.

Since the 3.20 version, textBufferSetModified is called with False if the file has been saved successfully.

Since: 3.14

setCompressionType

fileSaverSetCompressionType Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> CompressionType

compressionType: the new compression type.

-> m () 

Sets the compression type. By default the compression type is taken from the File.

Since: 3.14

setEncoding

fileSaverSetEncoding Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> Maybe Encoding

encoding: the new encoding, or Nothing for UTF-8.

-> m () 

Sets the encoding. If encoding is Nothing, the UTF-8 encoding will be set. By default the encoding is taken from the File.

Since: 3.14

setFlags

fileSaverSetFlags Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> [FileSaverFlags]

flags: the new flags.

-> m () 

No description available in the introspection data.

Since: 3.14

setNewlineType

fileSaverSetNewlineType Source #

Arguments

:: (HasCallStack, MonadIO m, IsFileSaver a) 
=> a

saver: a FileSaver.

-> NewlineType

newlineType: the new newline type.

-> m () 

Sets the newline type. By default the newline type is taken from the File.

Since: 3.14

Properties

buffer

compressionType

encoding

file

flags

location

newlineType