Search in sources :

Example 6 with CTTblCellMar

use of org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblCellMar in project poi by apache.

the class XWPFTable method getCellMarginTop.

public int getCellMarginTop() {
    int margin = 0;
    CTTblPr tblPr = getTrPr();
    CTTblCellMar tcm = tblPr.getTblCellMar();
    if (tcm != null) {
        CTTblWidth tw = tcm.getTop();
        if (tw != null) {
            margin = tw.getW().intValue();
        }
    }
    return margin;
}
Also used : CTTblWidth(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblWidth) CTTblPr(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblPr) CTTblCellMar(org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblCellMar)

Aggregations

CTTblCellMar (org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblCellMar)6 CTTblPr (org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblPr)5 CTTblWidth (org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTblWidth)5 CTTbl (org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTbl)1