styles = ((OdfContentDom) dom).getAutomaticStyles();
} else if (dom instanceof OdfStylesDom) {
styles = ((OdfStylesDom) dom).getAutomaticStyles();
}
OdfStyle textStyle = styles.newStyle(OdfStyleFamily.Text);
StyleTextPropertiesElement styleTextPropertiesElement = textStyle.newStyleTextPropertiesElement(null);
styleTextPropertiesElement.setStyleFontNameAttribute("Tahoma");
styleTextPropertiesElement.setFoFontSizeAttribute("10pt");
styleTextPropertiesElement.setStyleFontNameAsianAttribute("Lucida Sans Unicode");
styleTextPropertiesElement.setStyleFontSizeAsianAttribute("12pt");
noteSpanElement.setStyleName(textStyle.getStyleNameAttribute());
// set comment content
noteSpanElement.setTextContent(content);
// insert comment to its position
insertOdfElement(annotationElement, mIndexInContainer, parentElement);