You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2008/06/04 08:12:43 UTC

DO NOT REPLY [Bug 45088] POI-HSLF changeTextInRichTextRun corrupts presentation

https://issues.apache.org/bugzilla/show_bug.cgi?id=45088





--- Comment #1 from Yegor Kozlov <ye...@dinom.ru>  2008-06-03 23:12:42 PST ---
>From poi-user:

Check setting style when '\n' needs to be the last
character in the first RichTextRun. It seems to be a related bug.

        SlideShow ppt = new SlideShow();

        Slide s = ppt.createSlide();
        TextBox tb = new TextBox();
        TextRun tr = tb.createTextRun();

        tb.setAnchor(new Rectangle(10,10,500,20));

        tr.getRichTextRuns()[0].setText("hello\n");
        tr.getRichTextRuns()[0].setFontName("Calibri");
        tr.getRichTextRuns()[0].setFontSize(12);

        RichTextRun rtr = tr.appendText("world");
        rtr.setFontName("Times New Roman");
        rtr.setFontSize(12);

        s.addShape(tb);

        FileOutputStream out = new FileOutputStream("report/slideshow.ppt");
        ppt.write(out);
        out.close();


-- 
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