Hi all,
when I test my (B4XPages) app under iOS (iPhone), occasionally (not always) the images (which are loaded into the CLV) appear blurry.
This happens on both the emulator and the real device (so it could happen to users as well).
Within the Android version (B4XPages app) this problem does not occur.
Why does this happen?
Sub Class_Globals
Private imgSubCat As B4XView
End Sub
Private Sub CreateItem (aNID As Int, aTitle As String, aImg As Bitmap, iv As ItemValue) As B4XView
Private pnl As B4XView = xui.CreatePanel("")
pnl.SetLayoutAnimated (0,0,0,100%x, 300dip)
pnl.LoadLayout("subcat_itemlayout")
imgSubCat.SetBitmap(aImg.Resize(pnl.Width, 300dip, True))
lblSubCatTitle.Text = aTitle
iv.nid = aNID
iv.title = aTitle
iv.img = aImg
Return pnl
End Sub
I'm loading an "ImageView" with LoadLayout("subcat_itemlayout") than I set it with "imgSubCat.SetBitmap".
Thank you Erel! The mod you suggested works fine (no more blurred images).
The only little thing that I cannot understand how to handle is how to fit correctly between top and bottom without show the grey and white horizontal "bars" (as you can see within image above).
B4XImageView is a new custom view, added to XUI Views v2.40. It adds several useful resize modes to the standard ImageView: (Images source: https://www.b4x.com/android/forum/threads/compass-gm-a-gyro-magnetic-compass-app-featuring-true-and-magnetic-heading.121239/...