For the medium-size widget, I had to go by a 360 x 170 point size since there was no way to get the actual view dimensions before the the view gets displayed. Just to touch on this, there is a way to do this.
TimelineProviderContext has a displaySize property that lets you know "The size, in points, of the widget."