used proper if statements in widths