/** * Return the background color. * <p> * Null will be returned if there is no the background color definition or * the background color definition is not valid. * * @return the background color */ public Color getBackgroundColor() { String property = mElement.getFoBackgroundColorAttribute(); Color color = null; try { color = Color.valueOf(property); } catch (Exception e) { Logger.getLogger(TableCellProperties.class.getName()).log(Level.WARNING, e.getMessage()); } return color; }
/** * Return the vertical alignment. * <p> * If there is no vertical alignment definition, null will be returned. * * @return the vertical alignment */ public StyleTypeDefinitions.VerticalAlignmentType getVerticalAlignment() { String alignType = mElement.getStyleVerticalAlignAttribute(); if ((alignType == null) || (alignType.length() == 0)) return null; StyleVerticalAlignAttribute.Value value = StyleVerticalAlignAttribute.Value.enumValueOf(alignType); switch (value) { case AUTO: return StyleTypeDefinitions.VerticalAlignmentType.DEFAULT; case AUTOMATIC: return StyleTypeDefinitions.VerticalAlignmentType.DEFAULT; case BASELINE: return StyleTypeDefinitions.VerticalAlignmentType.BOTTOM; case BOTTOM: return StyleTypeDefinitions.VerticalAlignmentType.BOTTOM; case MIDDLE: return StyleTypeDefinitions.VerticalAlignmentType.MIDDLE; case TOP: return StyleTypeDefinitions.VerticalAlignmentType.TOP; } return null; }
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 padding = ele.getFoPaddingAttribute(); if (StringUtils.isNotEmpty(padding)) { cssStyleSheet.setCSSProperty(PADDING, padding); String paddingBottom = ele.getFoPaddingBottomAttribute();
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 padding = ele.getFoPaddingAttribute(); if ( StringUtils.isNotEmpty( padding ) ) String paddingBottom = ele.getFoPaddingBottomAttribute(); if ( StringUtils.isNotEmpty( paddingBottom ) ) String paddingLeft = ele.getFoPaddingLeftAttribute(); if ( StringUtils.isNotEmpty( paddingLeft ) ) String paddingRight = ele.getFoPaddingRightAttribute(); if ( StringUtils.isNotEmpty( paddingRight ) )
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 padding = ele.getFoPaddingAttribute(); if ( StringUtils.isNotEmpty( padding ) ) String paddingBottom = ele.getFoPaddingBottomAttribute(); if ( StringUtils.isNotEmpty( paddingBottom ) ) String paddingLeft = ele.getFoPaddingLeftAttribute(); if ( StringUtils.isNotEmpty( paddingLeft ) ) String paddingRight = ele.getFoPaddingRightAttribute(); if ( StringUtils.isNotEmpty( paddingRight ) )
/** * Return the background color. * <p> * Null will be returned if there is no the background color definition or * the background color definition is not valid. * * @return the background color */ public Color getBackgroundColor() { String property = mElement.getFoBackgroundColorAttribute(); Color color = null; try { color = Color.valueOf(property); } catch (Exception e) { Logger.getLogger(TableCellProperties.class.getName()).log(Level.WARNING, e.getMessage()); } return color; }
/** * Return the vertical alignment. * <p> * If there is no vertical alignment definition, null will be returned. * * @return the vertical alignment */ public StyleTypeDefinitions.VerticalAlignmentType getVerticalAlignment() { String alignType = mElement.getStyleVerticalAlignAttribute(); if ((alignType == null) || (alignType.length() == 0)) return null; StyleVerticalAlignAttribute.Value value = StyleVerticalAlignAttribute.Value.enumValueOf(alignType); switch (value) { case AUTO: return StyleTypeDefinitions.VerticalAlignmentType.DEFAULT; case AUTOMATIC: return StyleTypeDefinitions.VerticalAlignmentType.DEFAULT; case BASELINE: return StyleTypeDefinitions.VerticalAlignmentType.BOTTOM; case BOTTOM: return StyleTypeDefinitions.VerticalAlignmentType.BOTTOM; case MIDDLE: return StyleTypeDefinitions.VerticalAlignmentType.MIDDLE; case TOP: return StyleTypeDefinitions.VerticalAlignmentType.TOP; } return null; }
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 padding = ele.getFoPaddingAttribute(); if ( StringUtils.isNotEmpty( padding ) ) String paddingBottom = ele.getFoPaddingBottomAttribute(); if ( StringUtils.isNotEmpty( paddingBottom ) ) String paddingLeft = ele.getFoPaddingLeftAttribute(); if ( StringUtils.isNotEmpty( paddingLeft ) ) String paddingRight = ele.getFoPaddingRightAttribute(); if ( StringUtils.isNotEmpty( paddingRight ) )
/** * Return the background color. * <p> * Null will be returned if there is no the background color definition or * the background color definition is not valid. * * @return the background color */ public Color getBackgroundColor() { String property = mElement.getFoBackgroundColorAttribute(); Color color = null; try { color = Color.valueOf(property); } catch (Exception e) { Logger.getLogger(TableCellProperties.class.getName()).log(Level.WARNING, e.getMessage()); } return color; }
/** * Return the vertical alignment. * <p> * If there is no vertical alignment definition, null will be returned. * * @return the vertical alignment */ public StyleTypeDefinitions.VerticalAlignmentType getVerticalAlignment() { String alignType = mElement.getStyleVerticalAlignAttribute(); if ((alignType == null) || (alignType.length() == 0)) return null; StyleVerticalAlignAttribute.Value value = StyleVerticalAlignAttribute.Value.enumValueOf(alignType); switch (value) { case AUTO: return StyleTypeDefinitions.VerticalAlignmentType.DEFAULT; case AUTOMATIC: return StyleTypeDefinitions.VerticalAlignmentType.DEFAULT; case BASELINE: return StyleTypeDefinitions.VerticalAlignmentType.BOTTOM; case BOTTOM: return StyleTypeDefinitions.VerticalAlignmentType.BOTTOM; case MIDDLE: return StyleTypeDefinitions.VerticalAlignmentType.MIDDLE; case TOP: return StyleTypeDefinitions.VerticalAlignmentType.TOP; } return null; }
String backgroundColor = ele.getFoBackgroundColorAttribute(); if (StringUtils.isNotEmpty(backgroundColor)) { tableCellProperties.setBackgroundColor(ColorRegistry.getInstance() String border = ele.getFoBorderAttribute(); if (StringUtils.isNotEmpty(border)) { tableCellProperties.setBorder(new StyleBorder(border, String borderBottom = ele.getFoBorderBottomAttribute(); if (StringUtils.isNotEmpty(borderBottom)) { tableCellProperties.setBorderBottom(new StyleBorder(borderBottom, String borderLeft = ele.getFoBorderLeftAttribute(); if (StringUtils.isNotEmpty(borderLeft)) { tableCellProperties.setBorderLeft(new StyleBorder(borderBottom, String borderRight = ele.getFoBorderRightAttribute(); if (StringUtils.isNotEmpty(borderRight)) { tableCellProperties.setBorderRight(new StyleBorder(borderRight, String borderTop = ele.getFoBorderTopAttribute(); if (StringUtils.isNotEmpty(borderTop)) { tableCellProperties.setBorderTop(new StyleBorder(borderTop, String padding = ele.getFoPaddingAttribute(); if (StringUtils.isNotEmpty(padding)) { if (stylePadding == null) { String paddingBottom = ele.getFoPaddingBottomAttribute();