Android – uses the page curl effect of the scrolling page curl library, and the page background is displayed as a black border instead of transparency
•
Android
Hi, I'm using the harism library for page curl effects( https://github.com/harism/android_page_curl )The effect is normal, but there are some transparent parts in the background of my page, which are displayed in black. I have tried in GitHub forum( https://github.com/harism/android_page_curl/issues/25 )The solutions mentioned in, But the solution doesn't work properly. You can also query my query there. You can also check the attached screenshot
thank you!
resolvent:
Comments these lines in the activity
r.left += border;
r.right -= border;
r.top += border;
r.bottom -= border;
r.left += ((r.width() - imageWidth) / 2) - border;
r.right = r.left + imageWidth + border + border;
r.top += ((r.height() - imageHeight) / 2) - border;
r.bottom = r.top + imageHeight + border + border;
replace this function in the CurlView Activity
public void setMargins(float left, float top, float right, float bottom) {
mRenderer.setMargins(left, top, right, bottom);
}
The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
二维码