use the following actions:
from the android docs for Path:
*computeBounds*<http://developer.android.com/reference/android/graphics/Path.html#computeBounds(android.graphics.RectF,
boolean)>(*RectF*<http://developer.android.com/reference/android/graphics/RectF.html>bounds,
boolean exact)
from the android docs for RectF:
*width*<http://developer.android.com/reference/android/graphics/RectF.html#width()>()
and
*height*<http://developer.android.com/reference/android/graphics/RectF.html#height()>()
for example:
RectF *pathrectanglebounds = new RectF();*
float pathwidth
float pathheight;
testPath.*computeBounds*<http://developer.android.com/reference/android/graphics/Path.html#computeBounds(android.graphics.RectF,
boolean)>(*pathrectanglebounds*,true); //this sets the dimensions of
*pathrectanglebounds
to the rectangular bounds of the path, the "exact" parameter is "no longer
used" according to docs, so i just set it to true*
pathwidth=*pathrectanglebounds.width();*
pathheight=*pathrectanglebounds.height();*
**
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en