Is there a way, given the current set font of the Graphics object and a String to get the bounding box that it would occupy?
Thanks
Is there a way, given the current set font of the Graphics object and a String to get the bounding box that it would occupy?
Thanks
I prefer TextLayout#getBounds(); but if you already have a Graphics context, the string bounds methods of FontMetrics are convenient.