poi-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 50847] XSSFFont.setCharSet(int charset) allows to set only 3 charsets from FontCharset (ANSI, SYMBOL and DEFAULT)
Date Wed, 02 Mar 2011 15:18:22 GMT
https://issues.apache.org/bugzilla/show_bug.cgi?id=50847

--- Comment #5 from andrei <andrei.astrouski@gmail.com> 2011-03-02 10:18:20 EST ---
Patch:

public void setCharSet(int charset) {
        CTIntProperty charsetProperty = _ctFont.sizeOfCharsetArray() == 0 ?
_ctFont.addNewCharset() : _ctFont.getCharsetArray(0);
        FontCharset fontCharset = FontCharset.valueOf(charset);
        if (fontCharset != null) {
            charsetProperty.setVal(fontCharset.getValue());
        } else {
            throw new POIXMLException("Attention: an attempt to set a type of
unknow charset and charset");
        }
    }

-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


Mime
View raw message