Added layout generator, added preferences and its preview.