public void trackAndUntrackAllColumns() { Assume.That(tracker.TrackedColumns.Count == 0); tracker.TrackAllColumns(); Assert.IsTrue(tracker.TrackedColumns.Count == 0); IRow row = sheet.CreateRow(0); foreach (int column in columns) { row.CreateCell(column); } // implicitly track the columns tracker.UpdateColumnWidths(row); Assert.AreEqual(columns, tracker.TrackedColumns); tracker.UntrackAllColumns(); Assert.IsTrue(tracker.TrackedColumns.Count == 0); }
/** * Tracks all columns in the sheet for auto-sizing. If this is called, individual columns do not need to be tracked. * Because determining the best-fit width for a cell is expensive, this may affect the performance. * @since 3.14beta1 */ public void TrackAllColumnsForAutoSizing() { _autoSizeColumnTracker.TrackAllColumns(); }