Android Question Panel with border e gradient in Designer

Erel

B4X founder
Staff member
Licensed User
Longtime User
You can do it with the designer by putting a panel inside a panel where the inner panel is anchored to all sides with distances matching the border width:

1714884935686.png

1714884947888.png


You can also add a border programmatically with:
B4X:
Private Sub SetBorder(v As View, BorderWidth As Int, BorderColor As Int)
    v.Background.As(JavaObject).RunMethod("setStroke", Array(BorderWidth, BorderColor))
End Sub

B4X:
SetBorder(Panel3, 5dip, xui.Color_Blue)
 
Upvote 0
Top