Alter the colspan on any fnOpen rows
970678
function ()
	{
		var aoOpen = this.s.dt.aoOpenRows;
		var iVisible = this.s.dt.oApi._fnVisbleColumns( this.s.dt );

		for ( var i=0, iLen=aoOpen.length ; i<iLen ; i++ ) {
			aoOpen[i].nTr.getElementsByTagName('td')[0].colSpan = iVisible;
		}
	}
1285162
def columnise(rows, padding=2):
    """"""
    strs = []
    maxwidths = {}

    for row in rows:
        for i, e in enumerate(row):
            se = str(e)
            nse = len(se)
            w = maxwidths.get(i, -1)
            if nse > w:
                maxwidths[i] = nse

    for row in rows:
        s = ''
        for i, e in enumerate(row):
            se = str(e)
            if i < len(row) - 1:
                n = maxwidths[i] + padding - len(se)
                se += ' ' * n
            s += se
        strs.append(s)
    return strs
340582
def set_cols_align(self, array):
        

        self._check_row_size(array)
        self._align = array
        return self
541955
function removeColumnByKey(opts: Options, change: Change, key: string): Change {
    const { value } = change;

    const pos = TablePosition.create(opts, value.document, key);
    const { table } = pos;

    const colIndex = pos.getColumnIndex();

    const rows = table.nodes;

    // Remove the cell from every row
    if (pos.getWidth() > 1) {
        rows.forEach(row => {
            const cell = row.nodes.get(colIndex);
            change.removeNodeByKey(cell.key, { normalize: false });
        });
    } else {
        // If last column, clear text in cells instead
        rows.forEach(row => {
            row.nodes.forEach(cell => {
                cell.nodes.forEach(node => clearCell(opts, change, cell));
            });
        });
    }

    // Replace the table
    return change;
}
169188
function updateCSSNode(editor, srcProp, width, height) {
	const rule = srcProp.parent;
	const widthProp = getProperty(rule, 'width');
	const heightProp = getProperty(rule, 'height');

	// Detect formatting
	const separator = srcProp.separator || ': ';
	const before = getBefore(editor, srcProp);
	const insertOpt = { autoIndent: false };

	editor.transact(() => {
		// Apply changes from right to left, first for height, then for width

		if (!heightProp) {
			// no `height` property, add it right after `width` or source property
			editor.setCursorBufferPosition(widthProp ? widthProp.end : srcProp.end);
			editor.insertText(`${before}height${separator}${height}px;`, insertOpt);
		} else {
			editor.setTextInBufferRange(getRange(heightProp.valueToken), `${height}px`);
		}

		if (!widthProp) {
			// no `width` attribute, add it right after `height` or source property
			if (heightProp) {
				editor.setCursorBufferPosition(heightProp.previousSibling
					? heightProp.previousSibling.end
					: rule.contentStart.end);
			} else {
				editor.setCursorBufferPosition(srcProp.end);
			}
			editor.insertText(`${before}width${separator}${width}px;`, insertOpt);
		} else {
			editor.setTextInBufferRange(getRange(widthProp.valueToken), `${width}px`);
		}
	});
}
1333044
function _updateRowspan(tableData, startRowIndex, endRowIndex) {
  util.range(startRowIndex, endRowIndex + 1).forEach(rowIndex => {
    tableData[rowIndex].forEach((cell, cellIndex) => {
      if (util.isExisty(cell.rowMergeWith)) {
        const merger = tableData[cell.rowMergeWith][cellIndex];

        if (merger.rowspan) {
          merger.rowspan -= 1;
        }
      } else if (cell.rowspan > 1) {
        const lastMergedRowIndex = rowIndex + cell.rowspan - 1;

        cell.rowspan -= (endRowIndex - rowIndex + 1);

        if (lastMergedRowIndex > endRowIndex) {
          tableData[endRowIndex + 1][cellIndex] = util.extend({}, cell);
        }
      }
    });
  });
}
1277147
def resizeColumnsToContents(self, startCol=None, stopCol=None):
        
        numCols = self.model().columnCount()
        startCol = 0 if startCol is None else max(startCol, 0)
        stopCol  = numCols if stopCol is None else min(stopCol, numCols)

        row = 0
        for col in range(startCol, stopCol):
            indexWidget = self.indexWidget(self.model().index(row, col))

            if indexWidget:
                contentsWidth = indexWidget.sizeHint().width()
            else:
                contentsWidth = self.header().sectionSizeHint(col)

            self.header().resizeSection(col, contentsWidth)
960655
function _updateColspan(tableData, startColIndex, endColIndex) {
  tableData.forEach(rowData => {
    util.range(startColIndex, endColIndex + 1).forEach(colIndex => {
      const cellData = rowData [colIndex];

      if (util.isExisty(cellData.colMergeWith)) {
        const merger = rowData [cellData.colMergeWith];

        if (merger.colspan) {
          merger.colspan -= 1;
        }
      } else if (cellData.colspan > 1) {
        const lastMergedCellIndex = colIndex + cellData.colspan - 1;

        cellData.colspan -= (endColIndex - colIndex + 1);

        if (lastMergedCellIndex > endColIndex) {
          rowData [endColIndex + 1] = util.extend({}, cellData);
        }
      }
    });
  });
}
241556
function header(columns, opt, repeat, nodisplay){
  var headers = Object.keys(columns);
  var widths = headers.map(head => columns[head]);
  var topl = opt.title ? p[1][0] : p[0][0];
  var topr = opt.title ? p[1][2] : p[0][2];
  var topc = repeat ? p[1][1] : p[0][1];
  log(topl + widths.map(col => p.h + strN(col, p.h) + p.h).join(topc) + topr);
  if (!nodisplay) {
    log(p.v + ' ' + headers.map((txt, i) => fixed(txt, widths[i])).join(' ' + p.v + ' ') + ' ' + p.v);
    log(p[1][0] + widths.map(col => p.h + strN(col, p.h) + p.h).join(p[1][1]) + p[1][2]);
  }
}
1273477
function() {
      var i, j, col1, col2;
      var from = this.originalTable.startIndex;
      var to = this.originalTable.endIndex;
      /* Find children thead and tbody.
       * Only to process the immediate tr-children. Bugfix for inner tables
       */
      var thtb = this.originalTable.el.children();
      if (this.options.excludeFooter) {
        thtb = thtb.not('tfoot');
      }
      if (from < to) {
        for (i = from; i < to; i++) {
          col1 = thtb.find('> tr > td:nth-child(' + i + ')')
            .add(thtb.find('> tr > th:nth-child(' + i + ')'));
          col2 = thtb.find('> tr > td:nth-child(' + (i + 1) + ')')
            .add(thtb.find('> tr > th:nth-child(' + (i + 1) + ')'));
          for (j = 0; j < col1.length; j++) {
            swapNodes(col1[j], col2[j]);
          }
        }
      } else {
        for (i = from; i > to; i--) {
          col1 = thtb.find('> tr > td:nth-child(' + i + ')')
            .add(thtb.find('> tr > th:nth-child(' + i + ')'));
          col2 = thtb.find('> tr > td:nth-child(' + (i - 1) + ')')
            .add(thtb.find('> tr > th:nth-child(' + (i - 1) + ')'));
          for (j = 0; j < col1.length; j++) {
            swapNodes(col1[j], col2[j]);
          }
        }
      }
    }
828589
function ezColumnsStop()
    {
        if ( isset( $this->ez['columns'] ) && $this->ez['columns']['on']==1 )
        {
            $this->ez['columns']['on'] = 0;
            $this->ez['leftMargin'] = $this->ez['columns']['margins'][0];
            $this->ez['rightMargin'] = $this->ez['columns']['margins'][1];
            $this->ez['topMargin'] = $this->ez['columns']['margins'][2];
            $this->ez['bottomMargin'] = $this->ez['columns']['margins'][3];
        }
    }
966877
def set_cursor(self, col, row):
        """"""
        # Clamp row to the last row of the display.
        if row > self._lines:
            row = self._lines - 1
        # Set location.
        self.write8(LCD_SETDDRAMADDR | (col + LCD_ROW_OFFSETS[row]))
363858
def _swap_columns(self, side):
        """"""
        displayed_cols = self._displayed_cols
        i1 = self._dragged_col_index
        i2 = i1 + 1 if side == 'right' else i1 - 1
        if 0 <= i2 < len(displayed_cols):
            # there is a neighbor, swap columns:
            displayed_cols[i1] = displayed_cols[i2]
            displayed_cols[i2] = self._dragged_col
            self["displaycolumns"] = displayed_cols
            if side == 'left':
                right = self._dragged_col_neighbor_widths[0]
                self._dragged_col_x -= right  # update dragged column x coordinate
                # set new left neighbor width
                if i2 > 0:
                    left = ttk.Treeview.column(self, displayed_cols[i2 - 1], 'width')
                else:
                    left = None
            else:
                left = self._dragged_col_neighbor_widths[1]
                self._dragged_col_x += left  # update x coordinate of dragged column
                # set new right neighbor width
                if i2 < len(displayed_cols) - 1:
                    right = ttk.Treeview.column(self, displayed_cols[i2 + 1], 'width')
                else:
                    right = None
            self._dragged_col_index = i2  # update dragged column index
            self._dragged_col_neighbor_widths = (left, right)
330581
function nextCell( $colSpan = false )
    {
        $this->DocumentStack[$this->CurrentStackNumber]['CurrentCell'] += 1;
        if ( $colSpan != false )
            $this->DocumentStack[$this->CurrentStackNumber]['CurrentColSpan'] = $colSpan;
        else
            unset( $this->DocumentStack[$this->CurrentStackNumber]['CurrentColSpan'] );
    }
445619
public void setText (int row, int column, Object text, int colSpan, String... styles)
    {
        setText(row, column, String.valueOf(text));
        if (colSpan > 0) {
            getFlexCellFormatter().setColSpan(row, column, colSpan);
        }
        setStyleNames(row, column, styles);
    }
247031
def _shape_text(self, text, colsep=u"\t", rowsep=u"\n",
                    transpose=False, skiprows=0, comments='#'):
        """"""
        assert colsep != rowsep
        out = []
        text_rows = text.split(rowsep)[skiprows:]
        for row in text_rows:
            stripped = to_text_string(row).strip()
            if len(stripped) == 0 or stripped.startswith(comments):
                continue
            line = to_text_string(row).split(colsep)
            line = [try_to_parse(to_text_string(x)) for x in line]
            out.append(line)
        # Replace missing elements with np.nan's or None's
        if programs.is_module_installed('numpy'):
            from numpy import nan
            out = list(zip_longest(*out, fillvalue=nan))
        else:
            out = list(zip_longest(*out, fillvalue=None))
        # Tranpose the last result to get the expected one
        out = [[r[col] for r in out] for col in range(len(out[0]))]
        if transpose:
            return [[r[col] for r in out] for col in range(len(out[0]))]
        return out
98207
function() {
        var colspan = this.options.column.length;
        $.each(this.options.column, function(index, col) {
            if (col.visible) {
                colspan--;
            }
        });
        if (this.options.selectable) {
            colspan = colspan + 1;
        }
        this.$tableBody.find('tbody').append('<tr class="no-data"><td colspan="' + colspan + '">' + this.options.noDataContent + '</td></tr>');
    }