C# Class AODL.Document.TextDocuments.TextDocument

Represent a opendocument text document.
Inheritance: IDisposable, IDocument
Show file Open project: monsterlabs/HumanRightsTracker Class Usage Examples

Public Methods

Method Description
AddNewForm ( string name ) : ODFForm

Adds new form to the forms collection

CreateAttribute ( string name, string prefix ) : XmlAttribute

Create a new XmlAttribute for this document.

CreateNode ( string name, string prefix ) : XmlNode

Create a new XmlNode for this document.

DeleteUnpackedFiles ( ) : void
Dispose ( ) : void

Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection.

FindControlById ( string id ) : ODFFormControl

Looks for a specific control through all the forms by its ID

FindControlByName ( string name ) : ODFFormControl

Looks for a specific control through all the forms by its name

GetNamespaceUri ( string prefix ) : string

Return the namespaceuri for the given prefixname.

GetObjectByName ( string ObjectName ) : EmbedObject
Load ( string file ) : void

Loads the document by using the specified importer.

New ( ) : TextDocument

Create a blank new document.

SaveTo ( string filename ) : void

Save the TextDocument as OpenDocument textdocument.

SaveTo ( string filename, IExporter iExporter ) : void

Save the document by using the passed IExporter with the passed file name.

TextDocument ( ) : System

Create a new TextDocument object.

Private Methods

Method Description
AddFont ( string fontname ) : void

Adds a font to the document. All fonts that you use within your text must be added to the document. The class FontFamilies represent all available fonts.

CreateCommonStyleContent ( ) : void

Creates the content of the common style.

CreateContentBody ( ) : void

Creates the content body.

CreateLocalStyleContent ( ) : void

Creates the content of the local style.

Dispose ( bool disposing ) : void

Disposes the specified disposing.

FormsCollection_Clear ( ) : void
FormsCollection_Removed ( int index, object value ) : void
ReadCommonStyles ( ) : void

Reads the common styles.

Method Details

AddNewForm() public method

Adds new form to the forms collection
public AddNewForm ( string name ) : ODFForm
name string Form name
return AODL.Document.Forms.ODFForm

CreateAttribute() public method

Create a new XmlAttribute for this document.
public CreateAttribute ( string name, string prefix ) : XmlAttribute
name string The attributename.
prefix string The prefixname.
return System.Xml.XmlAttribute

CreateNode() public method

Create a new XmlNode for this document.
public CreateNode ( string name, string prefix ) : XmlNode
name string The elementname.
prefix string The prefix.
return System.Xml.XmlNode

DeleteUnpackedFiles() public method

public DeleteUnpackedFiles ( ) : void
return void

Dispose() public method

Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection.
public Dispose ( ) : void
return void

FindControlById() public method

Looks for a specific control through all the forms by its ID
public FindControlById ( string id ) : ODFFormControl
id string Control ID
return AODL.Document.Forms.Controls.ODFFormControl

FindControlByName() public method

Looks for a specific control through all the forms by its name
public FindControlByName ( string name ) : ODFFormControl
name string
return AODL.Document.Forms.Controls.ODFFormControl

GetNamespaceUri() public method

Return the namespaceuri for the given prefixname.
public GetNamespaceUri ( string prefix ) : string
prefix string The prefixname.
return string

GetObjectByName() public method

public GetObjectByName ( string ObjectName ) : EmbedObject
ObjectName string
return AODL.Document.Content.EmbedObjects.EmbedObject

Load() public method

Loads the document by using the specified importer.
public Load ( string file ) : void
file string The the file.
return void

New() public method

Create a blank new document.
public New ( ) : TextDocument
return TextDocument

SaveTo() public method

Save the TextDocument as OpenDocument textdocument.
public SaveTo ( string filename ) : void
filename string The filename. With or without full path. Without will save the file to application path!
return void

SaveTo() public method

Save the document by using the passed IExporter with the passed file name.
public SaveTo ( string filename, IExporter iExporter ) : void
filename string The name of the new file.
iExporter IExporter
return void

TextDocument() public method

Create a new TextDocument object.
public TextDocument ( ) : System
return System