addHTML
Class: mlreportgen.dom.Document
Namespace: mlreportgen.dom
Append HTML string to document
Syntax
htmlObjOut = addHTML(documentObj,htmlText)
Description
converts
a string of HTML text to a group of DOM objects and appends the group
to the htmlObjOut
= addHTML(documentObj
,htmlText
)Document
object documentObj
.
Input Arguments
Output Arguments
Examples
Tips
MATLAB® Report Generator™
mlreportgen.dom.HTML
ormlreportgen.dom.HTMLFile
objects typically cannot accept the raw HTML output of third-party applications, such as Microsoft Word, that export native documents as HTML markup. In these cases, your Report API report generation program can use themlreportgen.utils.html2dom.prepHTMLString
andmlreportgen.utils.html2dom.prepHTMLFile
functions to prepare the raw HTML for use with themlreportgen.dom.HTML
ormlreportgen.dom.HTMLFile
objects. Typically, your program will have to further process the prepared HTML to remove valid but undesirable objects, such as line feeds that were in the raw content.By default, the DOM API uses a base font size of 12 points to convert
em
units to actual font sizes. For example, a font size specified as2em
converts to 24 points. To specify a different base font size, add your content to a report by using anmlreportgen.dom.HTML
object. Set theEMBaseFontSize
property of the object to the base font size. For example, if you set theEMBaseFontSize
property to 14, a font size of2em
converts to 28 points.
Version History
Introduced in R2015a