Search in sources :

Example 1 with GridsetRecord

use of org.apache.poi.hssf.record.GridsetRecord in project poi by apache.

the class TestHSSFSheet method backupRecord.

/**
     * Test the gridset field gets set as expected.
     */
@Test
public void backupRecord() throws IOException {
    HSSFWorkbook wb = new HSSFWorkbook();
    HSSFSheet s = wb.createSheet();
    GridsetRecord gridsetRec = s.getSheet().getGridsetRecord();
    assertTrue(gridsetRec.getGridset());
    s.setGridsPrinted(true);
    assertFalse(gridsetRec.getGridset());
    wb.close();
}
Also used : GridsetRecord(org.apache.poi.hssf.record.GridsetRecord) Test(org.junit.Test)

Example 2 with GridsetRecord

use of org.apache.poi.hssf.record.GridsetRecord in project poi by apache.

the class InternalSheet method createGridset.

/**
     * creates the Gridset record and sets it to true (user has mucked with the gridlines)
     */
private static GridsetRecord createGridset() {
    GridsetRecord retval = new GridsetRecord();
    retval.setGridset(true);
    return retval;
}
Also used : GridsetRecord(org.apache.poi.hssf.record.GridsetRecord)

Aggregations

GridsetRecord (org.apache.poi.hssf.record.GridsetRecord)2 Test (org.junit.Test)1