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 2011/02/11 17:15:04 UTC
DO NOT REPLY [Bug 50764] New: RichTextRun.setBulletColor doesn't
work
https://issues.apache.org/bugzilla/show_bug.cgi?id=50764
Summary: RichTextRun.setBulletColor doesn't work
Product: POI
Version: 3.7
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P2
Component: HSLF
AssignedTo: dev@poi.apache.org
ReportedBy: zhangsilly@gmail.com
Created an attachment (id=26642)
--> (https://issues.apache.org/bugzilla/attachment.cgi?id=26642)
Set BulletColor to Color.RED
SlideShow ppt = new SlideShow();
Slide slide = ppt.createSlide();
TextBox shape = new TextBox();
RichTextRun rt = shape.getTextRun().getRichTextRuns()[0];
shape.setText(
"January\r"
+ "February\r"
+ "March\r"
+ "April");
rt.setFontSize(42);
rt.setBullet(true);
//rt.setBulletColor(Color.BLUE);
rt.setBulletOffset(0); //bullet offset
rt.setTextOffset(50); //text offset (should be greater than bullet
offset)
rt.setBulletChar('\u263A'); //bullet character
slide.addShape(shape);
shape.setAnchor(new java.awt.Rectangle(50, 50, 500, 300)); //position
of the text box in the slide
slide.addShape(shape);
FileOutputStream out = new FileOutputStream("bullets.ppt");
ppt.write(out);
out.close();
If uncomment the //rt.setBulletColor(Color.BLUE); line, the ppt will show no
Bullet. If rt.setBulletColor(Color.RED); Set the Color to RED, the Bullet Char
shows, but it's wrong, and color is still black.
The attachment red.ppt is generate by set BulletColor red.
--
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