Examples of CTTextParagraphProperties


Examples of org.docx4j.dml.CTTextParagraphProperties

      StringBuilder inlineStyle =  new StringBuilder();
      // Do we have CTTextParagraphProperties
      // <a:lvl?pPr>
      // Convert it to a WordML pPr
      CTTextParagraphProperties lvlPPr = unmarshalFormatting(lvlNpPr);
      if (lvlPPr!=null) {
     
        log.debug("We have lvlPPr");
        log.debug(
            XmlUtils.marshaltoString(lvlPPr, true, true,
View Full Code Here

Examples of org.docx4j.dml.CTTextParagraphProperties

  // methods.  Its a bit sad that we
  // can't just adorn our DOM tree with the
  // original JAXB objects?
  try {
    //CTTextListStyle lstStyle = null;
    CTTextParagraphProperties pPr = null;
   
    if (lvlNpPr!=null) {
      Node n = lvlNpPr.nextNode();
     
      log.debug(n.getClass().getName());
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

            if(!ok){
                CTPlaceholder ph = shape.getCTPlaceholder();
                if(ph == null){
                    // if it is a plain text box then take defaults from presentation.xml
                    XMLSlideShow ppt = shape.getSheet().getSlideShow();
                    CTTextParagraphProperties themeProps = ppt.getDefaultParagraphStyle(_p.getLevel());
                    if(themeProps != null) {
                        fetcher.isFetchingFromMaster = true;
                        ok = fetcher.fetch(themeProps);
                    }
                }
                if (!ok) {
                    CTTextParagraphProperties defaultProps =  _p.getDefaultMasterStyle();
                    if(defaultProps != null) {
                        fetcher.isFetchingFromMaster = true;
                        ok = fetcher.fetch(defaultProps);
                    }
                }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

            if(!ok){
                CTPlaceholder ph = shape.getCTPlaceholder();
                if(ph == null){
                    // if it is a plain text box then take defaults from presentation.xml
                    XMLSlideShow ppt = shape.getSheet().getSlideShow();
                    CTTextParagraphProperties themeProps = ppt.getDefaultParagraphStyle(_p.getLevel());
                    if(themeProps != null) {
                        fetcher.isFetchingFromMaster = true;
                        ok = fetcher.fetch(themeProps);
                    }
                }
                if (!ok) {
                    CTTextParagraphProperties defaultProps =  _p.getDefaultMasterStyle();
                    if(defaultProps != null) {
                        fetcher.isFetchingFromMaster = true;
                        ok = fetcher.fetch(defaultProps);
                    }
                }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

     * see {@link org.apache.poi.xslf.usermodel.TextAlign}.
     *
     * @param align text align
     */
    public void setTextAlign(TextAlign align){
        CTTextParagraphProperties pr = _p.isSetPPr() ? _p.getPPr() : _p.addNewPPr();
        if(align == null) {
            if(pr.isSetAlgn()) pr.unsetAlgn();
        } else {
            pr.setAlgn(STTextAlignType.Enum.forInt(align.ordinal() + 1));
        }
    }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

        fetchParagraphProperty(fetcher);
        return fetcher.getValue();
    }

    public void setBulletFont(String typeface){
        CTTextParagraphProperties pr = _p.isSetPPr() ? _p.getPPr() : _p.addNewPPr();
        CTTextFont font = pr.isSetBuFont() ? pr.getBuFont() : pr.addNewBuFont();
        font.setTypeface(typeface);
    }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

        fetchParagraphProperty(fetcher);
        return fetcher.getValue();
    }

    public void setBulletCharacter(String str){
        CTTextParagraphProperties pr = _p.isSetPPr() ? _p.getPPr() : _p.addNewPPr();
        CTTextCharBullet c = pr.isSetBuChar() ? pr.getBuChar() : pr.addNewBuChar();
        c.setChar(str);
    }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

        fetchParagraphProperty(fetcher);
        return fetcher.getValue();
    }

    public void setBulletFontColor(Color color){
        CTTextParagraphProperties pr = _p.isSetPPr() ? _p.getPPr() : _p.addNewPPr();
        CTColor c = pr.isSetBuClr() ? pr.getBuClr() : pr.addNewBuClr();
        CTSRgbColor clr = c.isSetSrgbClr() ? c.getSrgbClr() : c.addNewSrgbClr();
        clr.setVal(new byte[]{(byte) color.getRed(), (byte) color.getGreen(), (byte) color.getBlue()});
    }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

        fetchParagraphProperty(fetcher);
        return fetcher.getValue() == null ? 100 : fetcher.getValue();
    }

    public void setBulletFontSize(double size){
        CTTextParagraphProperties pr = _p.isSetPPr() ? _p.getPPr() : _p.addNewPPr();
        CTTextBulletSizePoint pt = pr.isSetBuSzPts() ? pr.getBuSzPts() : pr.addNewBuSzPts();
        pt.setVal((int)(size*1000));
        if(pr.isSetBuSzPct()) pr.unsetBuSzPct();
    }
View Full Code Here

Examples of org.openxmlformats.schemas.drawingml.x2006.main.CTTextParagraphProperties

     * Specifies the indent size that will be applied to the first line of text in the paragraph.
     *
     * @param value the indent in points.
     */
    public void setIndent(double value){
        CTTextParagraphProperties pr = _p.isSetPPr() ? _p.getPPr() : _p.addNewPPr();
        if(value == -1) {
            if(pr.isSetIndent()) pr.unsetIndent();
        } else {
            pr.setIndent(Units.toEMU(value));
        }
    }
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.