(re)added missing render func
removed old code around layouts