Border color of a text field??

Is there any way to set the border color of a text field??

OSes? There’s nothing built in but with declares it’s probably doable.

Or in pure Xojo, set the textfields border off and draw it in the Paint event of whatever it’s on

Sub Paint(g As Graphics, areas() As REALbasic.Rect) g.ForeColor = &cFF0000 g.DrawRect(TextField1.Left-1, TextField1.Top-1, TextField1.Width+2, TextField1.Height+2) End Sub

1 Like

where can i find the declare for window to set the border color e.g. to grey??

Trying to revive this topic…

Has anyone figured a nice way to change the color of the border of a TextArea (or TextField) ?

Is there something in the MBS plugin set? I can’t seem to find it :frowning:
I would expect to find something in NSTextFieldMBS, under the Layer property.

There is something in NSTextField.Layer.BorderColor, according to something I just ran into on StackOverflow.

@Edwin_van_den_Akker How did this work out for you?

First I played with the MBS plugins for a bit. But I decided to make the TextField transparent and placed a line underneath. So, I kind of abandoned the BorderColor idea.