FelixKratz / SketchyBar

A highly customizable macOS status bar replacement
https://felixkratz.github.io/SketchyBar/
GNU General Public License v3.0
5.45k stars 85 forks source link

is there a way to split the bar in half for notched screens #578

Closed Itstatertots closed 3 weeks ago

Itstatertots commented 1 month ago

i want to have to have a bar on each side of the notch is there a way to split the bar in half

maulik13 commented 1 month ago

Not directly. You can check the tips for multiple bars, however considering that you cannot specify width for a bar it will not work.

Technically, if you use positions "left", "q" and use brackets for those items you can simulate a bar to the left of the notch. And use "e" and "right" for rendering one on the right side. You just have to think creatively here :)

FelixKratz commented 3 weeks ago

Using brackets is the way to go, simply add this at the top of your sketchybarrc (before adding any other items):

sketchybar --add item left_anchor left --set left_anchor width=0 \
           --add item q_anchor q --set q_anchor width=0 \
           --add item e_anchor e --set e_anchor width=0 \
           --add item right_anchor right --set right_anchor width=0 \
           --add bracket left_bar left_anchor q_anchor \
           --set left_bar background.color=0xff000000 \
           --add bracket right_bar e_anchor right_anchor \
           --set right_bar background.color=0xffffffff

now you can control the properties of the left_bar and right_bar trough its bracket background properties.