Return-Path: Delivered-To: apmail-jakarta-poi-dev-archive@www.apache.org Received: (qmail 17549 invoked from network); 10 May 2006 07:31:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 10 May 2006 07:31:10 -0000 Received: (qmail 51815 invoked by uid 500); 10 May 2006 07:31:09 -0000 Delivered-To: apmail-jakarta-poi-dev-archive@jakarta.apache.org Received: (qmail 51794 invoked by uid 500); 10 May 2006 07:31:08 -0000 Mailing-List: contact poi-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "POI Developers List" Reply-To: "POI Developers List" Delivered-To: mailing list poi-dev@jakarta.apache.org Received: (qmail 51783 invoked by uid 99); 10 May 2006 07:31:08 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 May 2006 00:31:08 -0700 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.198] (HELO brutus.apache.org) (209.237.227.198) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 10 May 2006 00:31:08 -0700 Received: by brutus.apache.org (Postfix, from userid 33) id 2649771429F; Wed, 10 May 2006 07:30:24 +0000 (GMT) From: bugzilla@apache.org To: poi-dev@jakarta.apache.org Subject: DO NOT REPLY [Bug 39395] - PATCH: Placeholder shape and other improvements In-Reply-To: X-Bugzilla-Reason: AssignedTo Message-Id: <20060510073024.2649771429F@brutus.apache.org> Date: Wed, 10 May 2006 07:30:24 +0000 (GMT) X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG� RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT . ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND� INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=39395 ------- Additional Comments From yegor@dinom.ru 2006-05-10 07:30 ------- >> Do you think have a nice helper for RGB for the text colour (and presumably also >> background colour, shape colour etc), splitting into the tripplets, or should we >> just stick with using the java.awt one? End-user should work with java.awt.Color. For internal purposes we can use either approach, but what we have now is OK to me. If you are going to work with colors in PowerPoint, be aware it is not always logical: - RGB values are swapped, i.e. it is 'BGR' instead of 'RGB' - alpha component is 254 for rich text runs and 0 for shape color. There may be more 'features' we don't know about . >> Looking at TextBox, I'm not happy with how much of RichTextRun it seems to be >> duplicating. Can we just provide a RichTextRun over the top of it? Otherwise, we >> should refactor both of them to remove the duplication. This is only temporary architecture. I have plans how to refactor it, just need time to put things in order in my head and start implementing it. >> Also, why did you change TextCharsAtom to no longer use the common StringUtil >> stuff? I didn't commit that, I didn't see the point! Ops. My bad, sorry. This is experimental code and it came to the patch by mistake. I studied why TextBox didn't display extended ASCII wingdings and decided to use TextCharsAtom by default, not TextBytesAtom when a new TextBox is created. Unfortunately I couldn't do it with current TextCharsAtom. The following simple code results in error: TextCharsAtom tca = new TextCharsAtom(); String txt = tca.getText(); ava.lang.ArrayIndexOutOfBoundsException: Illegal offset at org.apache.poi.util.StringUtil.getFromUnicodeLE(StringUtil.java:67) at org.apache.poi.util.StringUtil.getFromUnicodeLE(StringUtil.java:91) at org.apache.poi.hslf.record.TextCharsAtom.getText(TextCharsAtom.java:44) I looked at TextCharsAtom and simplified it a bit: construct UTF-16LE string directly from a byte array. With this simplification it worked fine. And what were your reasons to use StringUtil instead of constructing strings from byte array? I prefer to keep things simple. Of course I would have discussed this change with you if I meant to commit it. Regards, Yegor -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: poi-dev-unsubscribe@jakarta.apache.org Mailing List: http://jakarta.apache.org/site/mail2.html#poi The Apache Jakarta POI Project: http://jakarta.apache.org/poi/