You may have figured that out yourself, but just in case, you can achieve straight corners by chamfering/filleting one edge first, then the one next to it (or, for your example first chamfer two opposing edges, then the other two).
Cool tips ! (and if you have odd numbered edges, just make the last after made the others even chamfers edges :)
Seems you can clic edges (not oposite but like that) A C, B D, E G, F H, I K, J L...etc in a following list when you have many edges !
And for the M alone, chamfer it after alone :)