It is correct.
Placeholders in PowerPoint have type=Rectangle unlike normal text
 which has type=TextBox. In 3.0.2 there was a hack to create TextBox
 in both cases. In the version 3.1 it was removed.

If you need to access text, cast shapes to TextShape, not to TextBox.
Both AutoShape and TextBox are subclasses of TextShape.

Yegor
 
> I've encountered following problem with poi-3.1-beta1-20080428:

> I have a simple one-slide presentation with a heading and a bullet list
> (i.e. one of the default layouts).
> Then I'll execute following code:
> ------
> import java.io.*;
> import org.apache.poi.hslf.model.Shape;
> import org.apache.poi.hslf.model.Slide;
> import org.apache.poi.hslf.usermodel.SlideShow;

> public class Main {

>         public static void main(String[] args) throws Exception {
>                 
>                 FileInputStream inputStream = new
> FileInputStream("/path/to/my/slideshow.ppt");
>                 SlideShow slideshow = new SlideShow(inputStream);
>                 for (Slide slide : slideshow.getSlides()) {
>                         for (Shape shape : slide.getShapes()) {
>                                 System.out.println(shape.toString());
>                         }
>                 }
>     }
> }
> ------
> Using 3.1-beta1 the result is:
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]

> which is incorrect in my opinion. 

> Previous version (3.0.2) gives:
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]


> Tomas


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to