in addition to Erel's suggestion, maybe your label height is too small so when you round the corners it cuts out the labels edges. Try a bigger height.
in addition to Erel's suggestion, maybe your label height is too small so when you round the corners it cuts out the labels edges. Try a bigger height.
Sub AddPanelBeforeLabel(lbl As Label)
Dim p As Panel
p.Initialize("")
Dim parent As Panel = lbl.Parent
parent.AddView(p, lbl.Left, lbl.Top, lbl.Width, lbl.Height)
p.SetBorder(2, Colors.Red, 4)
lbl.RemoveViewFromParent
p.AddView(lbl, 0, 0, p.Width, p.Height)
End Sub
Sub AddPanelBeforeLabel(lbl As Label)
Dim p As Panel
p.Initialize("")
Dim parent As Panel = lbl.Parent
parent.AddView(p, lbl.Left, lbl.Top, lbl.Width, lbl.Height)
p.SetBorder(2, Colors.Red, 4)
lbl.RemoveViewFromParent
p.AddView(lbl, 0, 0, p.Width, p.Height)
End Sub