Adapt layout.