public void SetColWidths(int[] widths)
{
var ccol = widths.Length;
var lengths = new VwLength[ccol];
for (var icol = 0; icol < ccol; icol++)
{
var len = new VwLength();
len.nVal = widths[icol];
len.unit = VwUnit.kunPoint1000;
lengths[icol] = len;
}
// We seem to need to tweak the first width to make things line up,
// possibly because of the left border.
lengths[0].nVal -= 1000;
if (RootBox != null)
RootBox.SetTableColWidths(lengths, ccol);
// TODO: fix this properly - why is m_vc null?
if (m_vc != null)
m_vc.SetColWidths(lengths);
}