Closer to working layout funcationality