开发者

Scrolling png with text & alpha on top of a static UIImageView

开发者 https://www.devze.com 2022-12-28 21:21 出处:网络
I have a view controller that has a view structure as follows: FilesOwner FirstResponder View ImageView (.jpg)

I have a view controller that has a view structure as follows:

FilesOwner
FirstResponder
View
   ImageView (.jpg)
   ScrollView
     ImageView (.png)

The text in the innermost imageview has white text and clear (alpha) all around. I want to scroll the innermost imageview, and see the background image (the .jpg) behind it.

Its not working. Its acting like the scrollview background obscures the underneath .jpg. I say this because if I change the background color of the scrollview, that's what I see i.e. if I set it black, I see black behind my .png, if I set it white, I see white. If I change the alpha of the scro开发者_开发百科llview that doesn't seem to work either. The one other thing I tried was unchecking drawing: Opaque, but that doesn't get it either.


Try setting the alpha value of your scrollviews background color to 0 (not the alpha value of the scrollview itself). The scrollview should be set to not opaque.

(didn't try, just guessing...)

0

精彩评论

暂无评论...
验证码 换一张
取 消