Android Question xCustomListView item panel color trasparency

Teech

Member
Licensed User
Longtime User
Hi.
I'll try to create a xCLV with items where base Panel has a trasparency in backgound color but something grey always appear

My xCLV has a backgroun color: without item is all OK
My Item Layout is fully transparent (activity and all views with Color #00FFFFFF)

If i add an Item without trasparency all work well and ItemPanel is correctly colored
B4X:
    Dim c As Customer=customers.Get(0)
    Dim p As B4XView=xui.CreatePanel("")
    p.SetLayoutAnimated(0,0,0,100%x,150dip)
    p.LoadLayout("CustomerItem")
    p.Color=xui.Color_White '<-- Total White is OK
    p.SetColorAndBorder(p.Color,2dip,xui.Color_ARGB(255,255,97,0),5%y)

But if i'll try to use a transparency (like in this code) there is somthing grey in some base panel that ruin my goal.
B4X:
    Dim c As Customer=customers.Get(0)
    Dim p As B4XView=xui.CreatePanel("")
    p.SetLayoutAnimated(0,0,0,100%x,150dip)
    p.LoadLayout("CustomerItem")
    p.Color=xui.Color_ARGB(30,255,97,0) '<-- Color HERE
    p.SetColorAndBorder(p.Color,2dip,xui.Color_ARGB(255,255,97,0),5%y)

Any suggestions?
Thank you.
 

Teech

Member
Licensed User
Longtime User
I have already set Divider Height to 0.
"something grey" is in a view under the panel.
The panel color is ok but under there seem to be another grey "panel".

Tomorrow i'll try to create a little app for this problem.
 
Upvote 0

Teech

Member
Licensed User
Longtime User
Thanks for your patience.
I have create a little APP that load 4 items in xCLV with 4 level of transparency.
In the Activity bottom there is a label "EFFECT" that show my purpose for relative items (when you click on it).
The difference between item background and label effect background is my issue.
It's obvious that in xCLV there is a grey panel under each item but i can't find it.

Is a B4X project but only B4A code work.

Thank in advace
 

Attachments

  • xCLVTransparency.zip
    11.3 KB · Views: 40
Upvote 0

zed

Active Member
Licensed User
It works very well.
I just changed the colors of the views.
 

Attachments

  • view1.jpg
    view1.jpg
    119.8 KB · Views: 46
  • view2.jpg
    view2.jpg
    119.8 KB · Views: 40
  • xCLVTransparency.zip
    11.3 KB · Views: 36
Upvote 0

Teech

Member
Licensed User
Longtime User
It works very well.
I just changed the colors of the views.
I can't understand.
With your APP is all good on all my devices too.
With my APP, on all my devices i have the result (with all colors) in attached screenshot.

What's different?
 

Attachments

  • screen1.png
    screen1.png
    56.6 KB · Views: 43
  • screen2.png
    screen2.png
    57.3 KB · Views: 44
  • screen3.png
    screen3.png
    57.3 KB · Views: 44
Upvote 0

zed

Active Member
Licensed User
It's because of the color separator.
Even on 0 it displays the color.
Set divider Color = Taransparent
 
Upvote 1
Solution

Teech

Member
Licensed User
Longtime User
It's because of the color separator.
Even on 0 it displays the color.
Set divider Color = Taransparent
Solved!!!
So separator is a panel a little more high then "front" panel.
Many Thanks
 
Last edited:
  • Like
Reactions: zed
Upvote 0

zed

Active Member
Licensed User
The separator is a panel.
Since everything else is transparent, the panel is visible.
The separator must also be transparent
 
Upvote 0
Top