User: kz Date: 2008-05-05 15:24:28+0000 Modified: dba/reportdesign/java/com/sun/star/report/pentaho/parser/stylemapper/style/FontFamilyMapper.java
Log: INTEGRATION: CWS dba30beta (1.3.6); FILE MERGED 2008/04/22 10:30:32 oj 1.3.6.1: #i88503# merge changes from rptchart02 File Changes: Directory: /dba/reportdesign/java/com/sun/star/report/pentaho/parser/stylemapper/style/ ======================================================================================= File [changed]: FontFamilyMapper.java Url: http://dba.openoffice.org/source/browse/dba/reportdesign/java/com/sun/star/report/pentaho/parser/stylemapper/style/FontFamilyMapper.java?r1=1.3&r2=1.4 Delta lines: +17 -19 --------------------- --- FontFamilyMapper.java 2008-04-10 17:55:11+0000 1.3 +++ FontFamilyMapper.java 2008-05-05 15:24:25+0000 1.4 @@ -27,8 +27,6 @@ * for a copy of the LGPLv3 License. * ************************************************************************/ - - package com.sun.star.report.pentaho.parser.stylemapper.style; import com.sun.star.report.pentaho.parser.StyleMapper; @@ -41,24 +39,24 @@ public class FontFamilyMapper implements StyleMapper { - public FontFamilyMapper () + + public FontFamilyMapper() { } - public void updateStyle (String uri, String attrName, String attrValue, - CSSDeclarationRule targetRule) + public void updateStyle(final String uri, final String attrName, final String attrValue, + final CSSDeclarationRule targetRule) { - final CSSStringValue cssVal = new CSSStringValue(CSSStringType.STRING, attrValue); - final CSSValue value = targetRule.getPropertyCSSValue(FontStyleKeys.FONT_FAMILY); - if (value instanceof CSSValueList == false) + if (!(value instanceof CSSValueList)) { + final CSSStringValue cssVal = new CSSStringValue(CSSStringType.STRING, attrValue); targetRule.setPropertyValue(FontStyleKeys.FONT_FAMILY, - new CSSValueList(new CSSValue[]{ cssVal })); + new CSSValueList(new CSSValue[]{cssVal})); } else { - CSSValueList list = (CSSValueList) value; + final CSSValueList list = (CSSValueList) value; targetRule.setPropertyValue(FontStyleKeys.FONT_FAMILY, CSSValueList.insertFirst(list, value)); } --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
