Class FileTypeSaver
- Namespace
- PaintDotNet.FileTypes
- Assembly
- PaintDotNet.FileTypes.dll
The base class for IFileTypeSavers. These are created by a PaintDotNet.FileTypes.FileTypeSaver.FileType that supports saving, and are returned from their OnCreateSaver() implementation.
public abstract class FileTypeSaver : RefTrackedObject, ISerializable, IFileTypeSaver, IObjectRef, IIsDisposed, IDisposable, IInternalImpl
- Inheritance
-
FileTypeSaver
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
- FileTypeSaver(IFileType)
The base constructor for the FileTypeSaver.
Properties
- Services
Provides access to the services provided by the host application. This is the same services object that the PaintDotNet.FileTypes.FileTypeSaver.FileType has access to.
Methods
- CreateDefaultSaveOptions()
Creates the default save options for this file type.
- CreateSaveOptionsControl()
Creates a control that allows the user to configure the save options.
- CreateSaveOptionsForDocument(IReadOnlyFileTypeDocument, IFileTypeSaveOptions, IReadOnlyFileTypePropertyBag)
Customizes the proposed save options for the given document. This allows the FileType to inspect the document and adjust the options accordingly. This is typically used with special metadata that was provided at load time by the same FileType.
- OnCreateSaveOptionsForDocument(ICreateSaveOptionsForDocumentContext)
A FileType plugin should implement this if it wants to customize the save options using metadata it provided at load time. See CreateSaveOptionsForDocument(IReadOnlyFileTypeDocument, IFileTypeSaveOptions, IReadOnlyFileTypePropertyBag) for more information.
- OnSave(IFileTypeSaveContext)
Implemented by the derived class to perform the actual saving operation.
- Save(Stream, IReadOnlyFileTypeDocument, IFileTypeSaveOptions, ProgressEventHandler?)
Saves the specified document to the output stream.