Fix parameter handling
Height 0 doesn't have undo data
More fixes and tweaks