[MWF] Pass graphics when calculating button text and image

This fixes a problem with calculating the text width of a button which caused the text to get truncated under certain circumstances instead of being wrapped. This fixes Xamarin-23168.