/** * * Gets backgroundColor represented by the OpenDocument format used data * type {@odf.datatype color} See * <a href="http://www.w3.org/TR/CSS21/syndata.html#value-def-color">W3C CSS * specification</a> for further details. * * @return bkColor as String (see above) */ public String getBackgroundColorAttribute() { return mElement.getFoBackgroundColorAttribute(); } }
/** * Get the size of the bottom margin of this * <code>ParagraphProperties</code> * * @return the size of the bottom margin (in Millimeter) * @since 0.7 */ public double getMarginBottom() { // get the value String valueString = mElement.getFoMarginBottomAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
/** * Get the size of the left margin of this <code>ParagraphProperties</code> * * @return the size of the left margin (in Millimeter) * @since 0.7 */ public double getMarginLeft() { // get the value String valueString = mElement.getFoMarginLeftAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
String backgroundColor = ele.getFoBackgroundColorAttribute(); if (StringUtils.isNotEmpty(backgroundColor)) { cssStyleSheet.setCSSProperty(BACKGROUND_COLOR, backgroundColor); String border = ele.getFoBorderAttribute(); if (StringUtils.isNotEmpty(border)) { cssStyleSheet.setCSSProperty(BORDER, border); String borderBottom = ele.getFoBorderBottomAttribute(); if (StringUtils.isNotEmpty(borderBottom)) { cssStyleSheet.setCSSProperty(BORDER_BOTTOM, borderBottom); String borderLeft = ele.getFoBorderLeftAttribute(); if (StringUtils.isNotEmpty(borderLeft)) { cssStyleSheet.setCSSProperty(BORDER_LEFT, borderLeft); String borderRight = ele.getFoBorderRightAttribute(); if (StringUtils.isNotEmpty(borderRight)) { cssStyleSheet.setCSSProperty(BORDER_RIGHT, borderRight); String borderTop = ele.getFoBorderTopAttribute(); if (StringUtils.isNotEmpty(borderTop)) { cssStyleSheet.setCSSProperty(BORDER_TOP, borderTop); String lineHeight = ele.getFoLineHeightAttribute(); if (StringUtils.isNotEmpty(lineHeight)) { cssStyleSheet.setCSSProperty(LINE_HEIGHT, lineHeight); String margin = ele.getFoMarginAttribute();
/** * Return the horizontal alignment. * <p> * Null will be returned if there is no horizontal alignment setting. * * @return - the horizontal alignment; null if there is no horizontal * alignment setting. */ public HorizontalAlignmentType getHorizontalAlignment() { String alignType = mElement.getFoTextAlignAttribute(); if ((alignType == null) || (alignType.length() == 0)) return HorizontalAlignmentType.DEFAULT; FoTextAlignAttribute.Value value = FoTextAlignAttribute.Value.enumValueOf(alignType); switch (value) { case CENTER: return HorizontalAlignmentType.CENTER; case END: return HorizontalAlignmentType.RIGHT; case JUSTIFY: return HorizontalAlignmentType.JUSTIFY; case LEFT: return HorizontalAlignmentType.LEFT; case RIGHT: return HorizontalAlignmentType.RIGHT; case START: return HorizontalAlignmentType.LEFT; } return null; }
/** * Get the size of the top margin of this <code>ParagraphProperties</code> * * @return the size of the top margin (in Millimeter) * @since 0.7 */ public double getMarginTop() { // get the value String valueString = mElement.getFoMarginTopAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
/** * Get the size of the right margin of this <code>ParagraphProperties</code> * * @return the size of the right margin (in Millimeter) * @since 0.7 */ public double getMarginRight() { // get the value String valueString = mElement.getFoMarginRightAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
/** * Get the size of the text indention of this * <code>ParagraphProperties</code> * * @return the size of the text indention (in Millimeter) * @since 0.7 */ public double getTextIndent() { // get the value String valueString = mElement.getFoTextIndentAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
String backgroundColor = ele.getFoBackgroundColorAttribute(); if (StringUtils.isNotEmpty(backgroundColor)) { paragraphProperties.setBackgroundColor(ColorRegistry.getInstance() String border = ele.getFoBorderAttribute(); if (StringUtils.isNotEmpty(border)) { paragraphProperties.setBorder(new StyleBorder(border, String borderBottom = ele.getFoBorderBottomAttribute(); if (StringUtils.isNotEmpty(borderBottom)) { paragraphProperties.setBorderBottom(new StyleBorder(borderBottom, String borderLeft = ele.getFoBorderLeftAttribute(); if (StringUtils.isNotEmpty(borderLeft)) { paragraphProperties.setBorderLeft(new StyleBorder(borderBottom, String borderRight = ele.getFoBorderRightAttribute(); if (StringUtils.isNotEmpty(borderRight)) { paragraphProperties.setBorderRight(new StyleBorder(borderRight, String borderTop = ele.getFoBorderTopAttribute(); if (StringUtils.isNotEmpty(borderTop)) { paragraphProperties.setBorderTop(new StyleBorder(borderTop, String lineHeight = ele.getFoLineHeightAttribute(); if (StringUtils.isNotEmpty(lineHeight)) { paragraphProperties.setLineHeight(ODFUtils String margin = ele.getFoMarginAttribute();
/** * Return the horizontal alignment. * <p> * Null will be returned if there is no horizontal alignment setting. * * @return - the horizontal alignment; null if there is no horizontal * alignment setting. */ public HorizontalAlignmentType getHorizontalAlignment() { String alignType = mElement.getFoTextAlignAttribute(); if ((alignType == null) || (alignType.length() == 0)) { return HorizontalAlignmentType.DEFAULT; } FoTextAlignAttribute.Value value = FoTextAlignAttribute.Value.enumValueOf(alignType); switch (value) { case CENTER: return HorizontalAlignmentType.CENTER; case END: return HorizontalAlignmentType.RIGHT; case JUSTIFY: return HorizontalAlignmentType.JUSTIFY; case LEFT: return HorizontalAlignmentType.LEFT; case RIGHT: return HorizontalAlignmentType.RIGHT; case START: return HorizontalAlignmentType.LEFT; } return null; }
/** * Get the size of the top margin of this <code>ParagraphProperties</code> * * @return the size of the top margin (in Millimeter) * @since 0.7 */ public double getMarginTop() { // get the value String valueString = mElement.getFoMarginTopAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
/** * Get the size of the right margin of this <code>ParagraphProperties</code> * * @return the size of the right margin (in Millimeter) * @since 0.7 */ public double getMarginRight() { // get the value String valueString = mElement.getFoMarginRightAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
/** * Get the size of the text indention of this * <code>ParagraphProperties</code> * * @return the size of the text indention (in Millimeter) * @since 0.7 */ public double getTextIndent() { // get the value String valueString = mElement.getFoTextIndentAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
String backgroundColor = ele.getFoBackgroundColorAttribute(); if ( StringUtils.isNotEmpty( backgroundColor ) ) String border = ele.getFoBorderAttribute(); if ( StringUtils.isNotEmpty( border ) ) String borderBottom = ele.getFoBorderBottomAttribute(); if ( StringUtils.isNotEmpty( borderBottom ) ) String borderLeft = ele.getFoBorderLeftAttribute(); if ( StringUtils.isNotEmpty( borderLeft ) ) String borderRight = ele.getFoBorderRightAttribute(); if ( StringUtils.isNotEmpty( borderRight ) ) String borderTop = ele.getFoBorderTopAttribute(); if ( StringUtils.isNotEmpty( borderTop ) ) String lineHeight = ele.getFoLineHeightAttribute(); if ( StringUtils.isNotEmpty( lineHeight ) ) String margin = ele.getFoMarginAttribute(); if ( StringUtils.isNotEmpty( margin ) ) String marginBottom = ele.getFoMarginBottomAttribute(); if ( StringUtils.isNotEmpty( marginBottom ) ) String marginLeft = ele.getFoMarginLeftAttribute(); if ( StringUtils.isNotEmpty( marginLeft ) )
/** * Return the horizontal alignment. * <p> * Null will be returned if there is no horizontal alignment setting. * * @return - the horizontal alignment; null if there is no horizontal * alignment setting. */ public HorizontalAlignmentType getHorizontalAlignment() { String alignType = mElement.getFoTextAlignAttribute(); if ((alignType == null) || (alignType.length() == 0)) { return HorizontalAlignmentType.DEFAULT; } FoTextAlignAttribute.Value value = FoTextAlignAttribute.Value.enumValueOf(alignType); switch (value) { case CENTER: return HorizontalAlignmentType.CENTER; case END: return HorizontalAlignmentType.RIGHT; case JUSTIFY: return HorizontalAlignmentType.JUSTIFY; case LEFT: return HorizontalAlignmentType.LEFT; case RIGHT: return HorizontalAlignmentType.RIGHT; case START: return HorizontalAlignmentType.LEFT; } return null; }
/** * * Gets backgroundColor represented by the OpenDocument format used data * type {@odf.datatype color} See * <a href="http://www.w3.org/TR/CSS21/syndata.html#value-def-color">W3C CSS * specification</a> for further details. * * @return bkColor as String (see above) */ public String getBackgroundColorAttribute() { return mElement.getFoBackgroundColorAttribute(); } }
/** * Get the size of the bottom margin of this * <code>ParagraphProperties</code> * * @return the size of the bottom margin (in Millimeter) * @since 0.7 */ public double getMarginBottom() { // get the value String valueString = mElement.getFoMarginBottomAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
/** * Get the size of the left margin of this <code>ParagraphProperties</code> * * @return the size of the left margin (in Millimeter) * @since 0.7 */ public double getMarginLeft() { // get the value String valueString = mElement.getFoMarginLeftAttribute(); // check if a value was returned if (valueString == null) { // if not use the default length valueString = DEFAULT_LENGTH; } // return the converted value return Length.parseDouble(valueString, Unit.MILLIMETER); }
String backgroundColor = ele.getFoBackgroundColorAttribute(); if ( StringUtils.isNotEmpty( backgroundColor ) ) String border = ele.getFoBorderAttribute(); if ( StringUtils.isNotEmpty( border ) ) String borderBottom = ele.getFoBorderBottomAttribute(); if ( StringUtils.isNotEmpty( borderBottom ) ) String borderLeft = ele.getFoBorderLeftAttribute(); if ( StringUtils.isNotEmpty( borderLeft ) ) String borderRight = ele.getFoBorderRightAttribute(); if ( StringUtils.isNotEmpty( borderRight ) ) String borderTop = ele.getFoBorderTopAttribute(); if ( StringUtils.isNotEmpty( borderTop ) ) Boolean joinBorder = ele.getStyleJoinBorderAttribute(); if ( joinBorder != null ) String lineHeight = ele.getFoLineHeightAttribute(); if ( StringUtils.isNotEmpty( lineHeight ) ) String margin = ele.getFoMarginAttribute(); if ( StringUtils.isNotEmpty( margin ) ) String marginBottom = ele.getFoMarginBottomAttribute(); if ( StringUtils.isNotEmpty( marginBottom ) )
String backgroundColor = ele.getFoBackgroundColorAttribute(); if ( StringUtils.isNotEmpty( backgroundColor ) ) String border = ele.getFoBorderAttribute(); if ( StringUtils.isNotEmpty( border ) ) String borderBottom = ele.getFoBorderBottomAttribute(); if ( StringUtils.isNotEmpty( borderBottom ) ) String borderLeft = ele.getFoBorderLeftAttribute(); if ( StringUtils.isNotEmpty( borderLeft ) ) String borderRight = ele.getFoBorderRightAttribute(); if ( StringUtils.isNotEmpty( borderRight ) ) String borderTop = ele.getFoBorderTopAttribute(); if ( StringUtils.isNotEmpty( borderTop ) ) Boolean joinBorder = ele.getStyleJoinBorderAttribute(); if ( joinBorder != null ) String lineHeight = ele.getFoLineHeightAttribute(); if ( StringUtils.isNotEmpty( lineHeight ) ) String margin = ele.getFoMarginAttribute(); if ( StringUtils.isNotEmpty( margin ) ) String marginBottom = ele.getFoMarginBottomAttribute(); if ( StringUtils.isNotEmpty( marginBottom ) )