gtksource.file_loader
Module for [FileLoader] class
Types 3
Methods
FileLoaderGidBuilder builder() static nothrowGet builder for [gtksource.file_loader.FileLoader] Returns: New builder objectgtksource.buffer.Buffer buffer() @property nothrowGet `buffer` property. Returns: The #GtkSourceBuffer to load the contents into. The #GtkSourceFileLoader object has a weak reference to the buffer.gtksource.file.File file() @property nothrowGet `file` property. Returns: The #GtkSourceFile. The #GtkSourceFileLoader object has a weak reference to the file.gio.input_stream.InputStream inputStream() @property nothrowGet `inputStream` property. Returns: The #GInputStream to load. Useful for reading stdin. If this property is set, the #GtkSourceFileLoader:location property is ignored.gio.file.File location() @property nothrowGet `location` property. Returns: The #GFile to load. If the #GtkSourceFileLoader:input-stream is null, by default the location is taken from the #GtkSourceFile at construction time.gtksource.file_loader.FileLoader newFromStream(gtksource.buffer.Buffer buffer, gtksource.file.File file, gio.input_stream.InputStream stream) static nothrowCreates a new #GtkSourceFileLoader object. The contents is read from stream.gtksource.buffer.Buffer getBuffer() nothrowgtksource.encoding.Encoding getEncoding() nothrowgtksource.file.File getFile() nothrowgio.input_stream.InputStream getInputStream() nothrowgio.file.File getLocation() nothrowgtksource.types.NewlineType getNewlineType() nothrowvoid loadAsync(int ioPriority, gio.cancellable.Cancellable cancellable = null, gio.types.FileProgressCallback progressCallback = null, gio.types.AsyncReadyCallback callback = null) nothrowLoads asynchronously the file or input stream contents into the #GtkSourceBuffer. See the #GAsyncResult documentation to know how to use this function.bool loadFinish(gio.async_result.AsyncResult result)Finishes a file loading started with [gtksource.file_loader.FileLoader.loadAsync].void setCandidateEncodings(gtksource.encoding.Encoding[] candidateEncodings) nothrowSets the candidate encodings for the file loading. The encodings are tried in the same order as the list.Constructors
this(gtksource.buffer.Buffer buffer, gtksource.file.File file)Creates a new #GtkSourceFileLoader object. The contents is read from the #GtkSourceFile's location. If not already done, call [gtksource.file.File.setLocation] before calling this constructor. The ...Fluent builder implementation template for gtksource.file_loader.FileLoader
Methods
T buffer(gtksource.buffer.Buffer propval) nothrowSet `buffer` property. Params: propval = The #GtkSourceBuffer to load the contents into. The #GtkSourceFileLoader object has a weak reference to the buffer. Returns: Builder instance for fluent cha...T file(gtksource.file.File propval) nothrowSet `file` property. Params: propval = The #GtkSourceFile. The #GtkSourceFileLoader object has a weak reference to the file. Returns: Builder instance for fluent chainingT inputStream(gio.input_stream.InputStream propval) nothrowSet `inputStream` property. Params: propval = The #GInputStream to load. Useful for reading stdin. If this property is set, the #GtkSourceFileLoader:location property is ignored. Returns: Builder i...T location(gio.file.File propval) nothrowSet `location` property. Params: propval = The #GFile to load. If the #GtkSourceFileLoader:input-stream is null, by default the location is taken from the #GtkSourceFile at construction time. Retur...Fluent builder for gtksource.file_loader.FileLoader
Methods