fix some variables for layout