Examples of IPPImage


Examples of com.aspose.slides.IPPImage

    //Get the first slide
    ISlide sld = pres.getSlides().get_Item(0);

    //Instantiate the Image class
    IPPImage imgx = null;

    try{
        imgx = pres.getImages().addImage(new FileInputStream(new File("data/pptx4j/greentick.png")));
    }
    catch(IOException e){}

    //Add Picture Frame with height and width equivalent of Picture
    sld.getShapes().addPictureFrame(ShapeType.Rectangle, 50, 150, imgx.getWidth(), imgx.getHeight(), imgx);

    //Write the PPTX file to disk
    pres.save("data/pptx4j/ImageInSlide-Aspose.pptx", SaveFormat.Pptx);
  }
View Full Code Here

Examples of com.aspose.slides.IPPImage

    pres.getSlides().get_Item(0).getBackground().setType (BackgroundType.OwnBackground);
    pres.getSlides().get_Item(0).getBackground().getFillFormat().setFillType ( FillType.Picture);
    pres.getSlides().get_Item(0).getBackground().getFillFormat().getPictureFillFormat().setPictureFillMode( PictureFillMode.Stretch);

    //Set the picture
    IPPImage imgx =null;
    imgx = pres.getImages().addImage(new FileInputStream(new File("data/background.jpg")));

    //Image imgx = pres.getImages().addImage(image);
    //Add image to presentation's images collection
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.