[WPF] More size calculation fixes

After all, the actual size of a widget doesn't include the margin,
so I reverted the previous change. However, the desired size does
include the margin, so it has to be subtracted when calculating
the preferred size. Also, when assigning the size of the child of
a canvas, the size being set is the actual size, so we have to
subtract the margins since they should not be part of the actual size.