void ResizeToFit() { if (iconImage == null || resultString == null) { return; } var stringSize = resultString.GetSize(); Frame = new CGRect(Frame.X, Frame.Y, iconImage.Size.Width + stringSize.Width, Frame.Height); NeedsDisplay = true; }