printLayouterTableHeader(d, cellSpacing, cellPadding, border, layout.getContainer());
printLayouterTableHeader(d, "SGridBagLayout", cellSpacing, cellPadding, border, layout);
    public void write(Device d, SLayoutManager l)            throws IOException {        SGridBagLayout layout = (SGridBagLayout) l;        boolean header = layout.getHeader();        int cellSpacing = layout.getCellSpacing() >= 0 ? layout.getCellSpacing() : 0;        int cellPadding = layout.getCellPadding() >= 0 ? layout.getCellPadding() : 0;        int border = layout.getBorder() >= 0 ? layout.getBorder() : 0;        SGridBagLayout.Grid grid = layout.getGrid();        if (grid.cols == 0) {            return;        }        printLayouterTableHeader(d, cellSpacing, cellPadding, border, layout.getContainer());        for (int row = grid.firstRow; row < grid.rows; row++) {            d.print("<tr>\n");            for (int col = grid.firstCol; col < grid.cols; col++) {                SComponent comp = grid.grid[col][row];                if (comp == null) {                    if (row == grid.firstRow && header) {                        d.print("<th></th>\n");                    } else {                        d.print("<td></td>\n");                    }                } else {                    GridBagConstraints c = layout.getConstraints(comp);                    if ((c.gridx == SGridBagLayout.LAST_CELL || c.gridx == col) &&                            (c.gridy == SGridBagLayout.LAST_CELL || c.gridy == row)) {                        if (row == grid.firstRow && header) {                            d.print("<th");                        } else {                            d.print("<td");                        }                        Utils.printTableCellAlignment(d, comp);                        Utils.printCSSInlineStyleAttributes(d, comp);                        int gridwidth = c.gridwidth;                        if (gridwidth == GridBagConstraints.RELATIVE) {                            gridwidth = grid.cols - col - 1;                        } else if (gridwidth == GridBagConstraints.REMAINDER) {                            gridwidth = grid.cols - col;                        }                        if (gridwidth > 1) {                            d.print(" colspan=" + gridwidth);                        }                        int gridheight = c.gridheight;                        if (gridheight == GridBagConstraints.RELATIVE) {                            gridheight = grid.rows - row - 1;                        } else if (gridheight == GridBagConstraints.REMAINDER) {                            gridheight = grid.rows - row;                        }                        if (gridheight > 1) {                            d.print(" rowspan=" + gridheight);                        }                        if (c.weightx > 0 && grid.colweight[row] > 0) {                            d.print(" width=\"" +                                    (int) (100 * c.weightx / grid.colweight[row]) +                                    "%\"");                        }                        if (c.weighty > 0 && grid.rowweight[col] > 0) {                            d.print(" height=\"" +                                    (int) (100 * c.weighty / grid.rowweight[col]) +                                    "%\"");                        }                        d.print(">");                        comp.write(d);                        if (row == grid.firstRow && header) {                            d.print("</th>\n");                        } else {                            d.print("</td>\n");                        }                    }                }            }            d.print("</tr>\n");        }        printLayouterTableFooter(d);    }