static double calculateTabsWidth(List<TTab> tabs) { return tabs.fold<double>(0.0, (a, b) => a + b.calculateWidth()) + ((tabs.length - 1) * 16); }