use of org.openxmlformats.schemas.wordprocessingml.x2006.main.CTOnOff in project poi by apache.
the class XWPFTableRow method setCantSplitRow.
/**
* Controls whether to allow this table row to split across pages.
* The logic for this attribute is a little unusual: a true value means
* DON'T allow rows to split, false means allow rows to split.
*
* @param split - if true, don't allow row to be split. If false, allow
* row to be split.
*/
public void setCantSplitRow(boolean split) {
CTTrPr trpr = getTrPr();
CTOnOff onoff = (trpr.sizeOfCantSplitArray() > 0 ? trpr.getCantSplitArray(0) : trpr.addNewCantSplit());
onoff.setVal(WMLHelper.convertBooleanToSTOnOff(split));
}
use of org.openxmlformats.schemas.wordprocessingml.x2006.main.CTOnOff in project poi by apache.
the class XWPFTableRow method getRepeat.
private boolean getRepeat() {
boolean repeat = false;
if (ctRow.isSetTrPr()) {
CTTrPr trpr = getTrPr();
if (trpr.sizeOfTblHeaderArray() > 0) {
CTOnOff rpt = trpr.getTblHeaderArray(0);
repeat = (rpt.isSetVal() ? WMLHelper.convertSTOnOffToBoolean(rpt.getVal()) : true);
}
}
return repeat;
}
Aggregations