Fixed order in Apply instance.
Added Layout pretty printer.