merge map and layout