creating viewer layout