fixed layout bugs