Added layout functionality