improved layout and dragging