Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
为什么有时会画出像什么像素:
xAxis = new RectF(0, 0, 400, 400);
其他时候它需要浮点数,例如:
xAxis = new RectF(0.29f, 0.24f, 0.55f, 0.76f);
我如何知道使用哪一个以及何时使用?因为我使用的是浮点版本,然后突然线条消失了,我花了一段时间才弄清楚发生了什么。
为什么不只使用 Rect 而不是 RectF?RectF 用于浮点, Rect 用于整数