0

我为布局中添加的图像视图实现了此代码。我得到startY = 0。

Matrix matrix = iv.getImageMatrix ();
float[] values = new float[];
matrix.getValues(values);
float startY = values[5];

我试过了

 int i=iv.getBottom();

这也返回 0。有人可以帮助在布局中找到我的 ImageView 的坐标值。

4

1 回答 1

0

我相信View.getLocationOnScreen()和/或是View.getLocationInWindow()您正在寻找的东西。

于 2013-08-08T09:34:52.847 回答