Added Rect.midX and Rect.midY. Removed layout.pack (aka table) from layout.js.
New layout.table .