More performance improvements. Re-implemented the row-based centered pattern.