HtmlSaveOptions.TableWidthOutputMode
HtmlSaveOptions.TableWidthOutputMode property
Controls how table, row and cell widths are exported to HTML, MHTML or EPUB. Default value is All.
public HtmlElementSizeOutputMode TableWidthOutputMode { get; set; }
Remarks
In the HTML format, table, row and cell elements (<table>, <tr>, <th>, <td>) can have their widths specified either in relative (percentage) or in absolute units. In a document in Wordize, tables, rows and cells can have their widths specified using either relative or absolute units too.
When you convert a document to HTML using Wordize, you might want to control how table, row and cell widths are exported to affect how the resulting document is displayed in the visual agent (e.g. a browser or viewer).
Use this property as a filter to specify what table widths values are exported into the destination document. For example, if you are converting a document to EPUB and intend to view the document on a mobile reading device, then you probably want to avoid exporting absolute width values. To do this you need to specify the output mode RelativeOnly or None so the viewer on the mobile device can layout the table to fit the width of the screen as best as it can.
Examples
Shows how to specify table width mode while exporting document to HTML.
HtmlSaveOptions htmlSaveOptions = new HtmlSaveOptions();
htmlSaveOptions.TableWidthOutputMode = HtmlElementSizeOutputMode.None;
Converter.Create()
.From(MyDir + "Simple.docx")
.To(ArtifactsDir + "HtmlSaveOptions.TableWidthOutputMode.html", htmlSaveOptions)
.Execute();
See Also
- enum HtmlElementSizeOutputMode
- class HtmlSaveOptions
- namespace Wordize.Saving
- assembly Wordize