Closed JayBrown closed 3 years ago
Checkmark is a standard of OS X. I think this is good to leave up to the plugins.
I was going to make a similar comment. Although the bullet option is interesting, I can honestly say I've never seen a menu bar use bullets as opposed to simple checkmarks. Or along with them. So its definitely non-standard.
Then again, some of the options BitBar currently does aren't exactly common. Most menubar items don't use custom fonts, font sizes, styles or colors, and those are all available within BitBar. And many of them don't use icons either. (the Keyboard and Character viewer menubar item being one of the exceptions)
OS X has this diamond thingy.
Don't know what else there is.
What is this checked=true
feature? I don't see it listed in the Plugin API section of the README.
@frakman1 It is listed in the one of the beta branch: https://github.com/matryer/bitbar/blob/beta/README.md#plugin-api
Thank you @iosdeveloper !
Any idea when this feature will be integrated? I looked at the commit and it included other unrelated changes.
I was able to implement something like this with the existing bitbar features and some code in my plugin:
@JayBrown I just noticed that you included your emojis for your bullets and am now using those instead of mine. Thanks!
Yeah, but emojis are in my view only a temporary solution, for one thing because they're often ghastly. ;) It would be great to be able to add base64-encoded images, similar to the menu bar icon.
Another great feature would also be to show the icons of files. Let's say, you want to make a BitBar menu with all preference panes installed on your system, i.e. the ones in /System/Library/, /Library, and ~/Library—which is something I plan to do, so I can quickly open them—, it would be a great help to see the panes' icons in the menu as well.
I actually prefer using emojis when they fit the need because they render perfectly on retina and on-retina displays (automatically). Since I am coding on a non-retina Mac and didn't know that my icons that looked fine on my display but were in fact horrible on a retina-screen, I ended up having to re-encode all my custom icons images to 144 DPI before they would look sharp on a retina screen.
I don't understand what feature you are requesting. I can currently add a custom icon as long as it is to the left of the displayed text. See https://github.com/matryer/bitbar/issues/425
Oh, great… didn't know that you could use images in the menu itself. To the left is fine for me.
Then it leaves me with the idea to show icons of files automatically. But how would BitBar know that it needs to show a file's icon? Probably not possible.
You probably need to hack it yourself: get the path to the .icns of the target file, run iconutil -c iconset -o /DestinationPath/to/Target.iconset /TargetPath/to/Target.prefPane/Contents/Resources/*.icns
, then base64-convert the png labeled icon_32x32@2x.png
, write the base64 to your BitBar-script's support folder with a fitting basename, then echo it as $IMAGE. During subsequent BitBar script reloads, you can just cat the base64 string from the support folder. Should work, I assume. (Question is only, if icon_32x32@2x.png
is the correct one for Retina support. The actual resolution is 64*64 at 72 ppi.)
EDIT: nope, the actual resolution is the problem… you first need to convert 64*64 at 72 ppi to 32*32 at 144 ppi, maybe even less, because this will have to fit within the menu rows, not the menu bar… and what's more, you can't change the resolution with sips
.
it looks like four options are natively supported. https://developer.apple.com/design/human-interface-guidelines/macos/menus/menu-anatomy/#using-symbols-in-menus
Love the
checked=true
option.Proposal: bullet option
bullet=black
andbullet=white
(or dark/light, whatever).Currently doing it with emojis:
These are round large bullets, or the emojis black & white circle: ● ○ But tend to prefer squares… emojis black & white square … looks nicer to me: ■ □
Possible?