use xtemplate layout