Kmail window layout keeps changing

this is what it should look like when it launches:

but whenever I open it for the first time after booting my computer it looks like this: