Rect和RectF的区别

来源:互联网 发布:php多线程 swoole 编辑:程序博客网 时间:2024/05/21 05:42
 

1、Rect的变量使用int类型,而RectF使用float类型。

2、一些方法区别

<1>、Rect类

equals(Object obj) (for some reason it as it's own implementation of equals)
exactCenterX()
exactCenterY()
flattenToString()
toShortString()
unflattenFromString(String str)


<2>、RectF类
round(Rect dst)
roundOut(Rect dst)
set(Rect src)

原创粉丝点击