Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change color of a line separator in Cocoa

Tags:

cocoa

Is there is any way to change the color of a line ("vertical line" and "horizontal line" of Interface Builder). A line separator in IB is a NSBox and I didn't find any method to change color when is used as NSBoxSeparator.

like image 823
Azpiri Avatar asked Sep 22 '10 09:09

Azpiri


1 Answers

It doesn't look like the line color is exposed for the "line" convenience object, but it is for the regular NSBox.

You can use a regular NSBox with its Box Type set to Custom and its border color set to whatever you desire. Then just size it down to a single pixel width or height.

like image 138
Joshua Nozzi Avatar answered Oct 28 '22 03:10

Joshua Nozzi