// ZSS-725: separate inner and font style to avoid the conflict between // vertical alignment, subscript and superscript. public String getFontHtmlStyle() { if (!_cell.isNull()) { final StringBuffer sb = new StringBuffer(); final SFont font = _cellStyle.getFont(); // sb.append(BookHelper.getFontCSSStyle(_book, font)); sb.append(getFontCSSStyle(_cell, font)); // condition color final FormatResult ft = _formatEngine.format(_cell, new FormatContext(ZssContext.getCurrent().getLocale())); final boolean isRichText = ft.isRichText(); if (!isRichText) { final SColor color = ft.getColor(); if (color != null) { final String htmlColor = color.getHtmlColor(); sb.append("color:").append(htmlColor).append(";"); } } return sb.toString(); } return ""; }
// 20150303, henrichen: The fix for ZSS-945 is super dirty! // ZSS-945 // @since 3.8.0 // @Internal public FormatResult getFormatResult() { return _cell == null ? null : _formatEngine.format(_cell, new FormatContext(ZssContext.getCurrent().getLocale())); }
public String getCellFormattedText() { final FormatResult ft = _formatEngine.format(_cell, new FormatContext(ZssContext.getCurrent().getLocale())); return ft.getText(); }