[#255] fix layout bugs
Merge pull request #181 from gotar/255-fix-layout-bugs

[#255] fix layout bugs