Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Posts: 83
Registered: ‎10-26-2008
My Device: Z10
My Carrier: MTS UKR
Accepted Solution

TextField border color



Is it possible to change standard TextField's border color? I would like to highlight it depending on the entered content. The same behavior has System Settings app, Add account page. See screenshots for details.





Posts: 103
Registered: ‎12-31-2012
My Device: Blackberry 9810
My Carrier: Verizon

Re: TextField border color

I had the same problm a few days back, and couldnt find any straight property to get it to work.


What i did instead was to hold the textField withina container and change the background color of the container. Be careful to set the focusHighlightEnabled: false  for the textField.


        Container {
            background: Color.Blue
             rightPadding: 2
             topPadding: 2
             bottomPadding: 2
             leftPadding: 2
             preferredWidth: maxWidth
             preferredHeight: minHeight
         TextField {
             text: qsTr("World")
             textStyle.base: SystemDefaults.TextStyles.BigText
             focusHighlightEnabled: false

Hope this helps  






Please mark this as solved if its fine.