Load a file into a GtkSourceBuffer.
A gtksource.file_loader.FileLoader object permits to load the contents of a gio.file.File or a gio.input_stream.InputStream into a class@Buffer.
A file loader should be used only for one load operation, including errors handling. If an error occurs, you can reconfigure the loader and relaunch the operation with gtksource.file_loader.FileLoader.loadAsync.
Running a gtksource.file_loader.FileLoader is an undoable action for the class@Buffer.
After a file loading, the buffer is reset to the contents provided by the gio.file.File or gio.input_stream.InputStream, so the buffer is set as “unmodified”, that is, gtk.text_buffer.TextBuffer.setModified is called with false. If the contents isn't saved somewhere (for example if you load from stdin), then you should probably call gtk.text_buffer.TextBuffer.setModified with true after calling gtksource.file_loader.FileLoader.loadFinish.
Load a file into a GtkSourceBuffer.
A gtksource.file_loader.FileLoader object permits to load the contents of a gio.file.File or a gio.input_stream.InputStream into a class@Buffer.
A file loader should be used only for one load operation, including errors handling. If an error occurs, you can reconfigure the loader and relaunch the operation with gtksource.file_loader.FileLoader.loadAsync.
Running a gtksource.file_loader.FileLoader is an undoable action for the class@Buffer.
After a file loading, the buffer is reset to the contents provided by the gio.file.File or gio.input_stream.InputStream, so the buffer is set as “unmodified”, that is, gtk.text_buffer.TextBuffer.setModified is called with false. If the contents isn't saved somewhere (for example if you load from stdin), then you should probably call gtk.text_buffer.TextBuffer.setModified with true after calling gtksource.file_loader.FileLoader.loadFinish.