internal static Cairo.Point MeasureTextSize(Pango.FontDescription font, string text) { var label = new Gtk.Label(text); var layout = label.CreatePangoLayout(text); layout.FontDescription = font; int width, height; layout.GetPixelSize(out width, out height); return(new Cairo.Point(width, height)); }