Why are the Width / Height of the drawable in ImageView wrong?

前端 未结 4 1893
失恋的感觉
失恋的感觉 2021-01-12 00:41

Should be a simple one.

When I pull image.getDrawable().getIntrinsicWidth() I get a value larger than the source image width. It\'s X coordinate is retu

4条回答
  •  無奈伤痛
    2021-01-12 01:16

    This is probably going to be nothing to with the issue you're having, but just for kicks I'll suggest it to be sure anyway: Are you specifying android:minSdkVersion in your manifest?

    Only reason I mention this is because for a while I wasn't doing so in a project, and I learned that this screws the screen density up and caused all sorts of strange problems.

提交回复
热议问题