Hi, Can you tell me how to change the color on a SegmentedControl please? Attached is my implementation and you can see the white border lines. I'd like control of the color so I can have it blend in better.
Thank you,
Brian
3 Answers, 1 is accepted
0
Hello Brian,
Thank you for providing the screenshot.
Border color is defined by SelectedSegmentBackgroundColor property of the control by design. I am afraid there isn't a way to set the border for different segments. We have a feature request logged for exposing more styling options for the segments, you could comment and cast your vote at the link below:
https://feedback.telerik.com/xamarin/1366194-segmentedcontrol-expose-additional-properties-or-mechanism-to-control-the-appearance-of-the-items
You can consider using a RadTabView control instead as it provides more ways to customize the HeaderItems by setting custom control templates. You can find more information on the following article from our documentation page - TabViewHeaderItem. Furthermore, you can have a look at the examples in the SDK Samples Application(located in the Examples folder of your local Telerik UI for Xamarin installation) or in the QSF Application(located in the QSF folder of your local installation).
Let me know if you have any additional questions.
Regards,
Yana
Progress Telerik
Thank you for providing the screenshot.
Border color is defined by SelectedSegmentBackgroundColor property of the control by design. I am afraid there isn't a way to set the border for different segments. We have a feature request logged for exposing more styling options for the segments, you could comment and cast your vote at the link below:
https://feedback.telerik.com/xamarin/1366194-segmentedcontrol-expose-additional-properties-or-mechanism-to-control-the-appearance-of-the-items
You can consider using a RadTabView control instead as it provides more ways to customize the HeaderItems by setting custom control templates. You can find more information on the following article from our documentation page - TabViewHeaderItem. Furthermore, you can have a look at the examples in the SDK Samples Application(located in the Examples folder of your local Telerik UI for Xamarin installation) or in the QSF Application(located in the QSF folder of your local installation).
Let me know if you have any additional questions.
Regards,
Yana
Progress Telerik
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Feedback Portal
and vote to affect the priority of the items
0
Brian
Top achievements
Rank 2
answered on 04 Feb 2019, 01:26 PM
Hi Yana, I got it working but I have one more question. Can I change the font attributes if I use a custom renderer? I can't go to radTabView for other issues with Tab and now I've SegmentedControl so close. :) . I will update the feat request above and explain that I still would like header attributes style-able.
Thanks again,
B
0
Hi Brian,
I am afraid that would not be an easy task, especially on Android. I have tested creating a custom renderers on Android and iOS platforms, you can find my sample project attached.
On Android we're wrapping a native RadSegmentedView control which basically is Android RadioGroup. You could explore the available options and try to find a way to set its font attributes.
I hope this would be helpful.
Regards,
Yana
Progress Telerik
I am afraid that would not be an easy task, especially on Android. I have tested creating a custom renderers on Android and iOS platforms, you can find my sample project attached.
On Android we're wrapping a native RadSegmentedView control which basically is Android RadioGroup. You could explore the available options and try to find a way to set its font attributes.
I hope this would be helpful.
Regards,
Yana
Progress Telerik
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Feedback Portal
and vote to affect the priority of the items