Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remain left most menu item #678

Closed
adamkdean opened this issue Mar 31, 2021 · 7 comments
Closed

Remain left most menu item #678

adamkdean opened this issue Mar 31, 2021 · 7 comments

Comments

@adamkdean
Copy link

adamkdean commented Mar 31, 2021

With the original BitBar, if new menu icons appeared, you could refresh all BitBar scripts and they would appear on the left. However with the recent updates, while refresh still works, the menu objects are no longer recreated and thus, if you wish to position XBar back on the left-most side of icons, you have to quit and restart it.

I use a single script that displays text, so I like to keep it on the left. I imagine with icons it doesn't matter their position.

image

(IP obfuscated, but usually text is there, not a gap)

Is there anything we can do to ensure it remains on the left?

@magicus
Copy link

magicus commented Mar 31, 2021

I wonder if this is also related to how xbar behaves in conjunction with Bartender 4. I'm running both, and most of the times it works fine, and sometimes the icons just gets shuffled around. I was planning on opening a bug as soon as I had figured out exactly what was going on. Restarting/refreshing tend to mess with things, though, is my impression.

@matryer
Copy link
Owner

matryer commented Mar 31, 2021

@adamkdean @magicus thanks for reporting this, I don't see this behaviour. Perhaps you can elaborate on exactly what you have running so I can try and recreate it?

@leaanthony
Copy link
Collaborator

I've just looked through the BitBar code and there's nothing to indicate a preferred location within the system extras panel, so I suspect that Bartender is moving them around. If you are keen on setting this as a preference, there's an interesting thread here about doing just that. However, I suspect Bartender may be modifying these preferences to do what it does so YMMV.

@adamkdean
Copy link
Author

@matryer Other than a few other apps that also place items in the menu bar, it's just XBar. No Bartender or any other menu bar altering applications. Here's something you may be able to do to try and replace it:

Create an XBar plugin script that simply outputs some text, and then after that has launched, launch or restart any app that also places an item in the menu bar. If you have nothing ordering the icons, then the new icon (of the app you launched after XBar) would be placed on the left most side, moving your XBar text further toward the right.

If you then click the XBar plugin text and select refresh, you'd expect it to appear on the left most side again (at least, that was the behaviour within Bitbar), but for me, it retains its position.

I'm not necessarily sure if this is a bug really, just a curious change in behaviour from Bitbar.

Thanks all for your contributions

@leaanthony
Copy link
Collaborator

It sounds like bitbar would remove the different components rather than refresh them.

@matryer
Copy link
Owner

matryer commented Apr 3, 2021

I think BitBar would destroy and recreate menus. xbar is more memory efficient, and reuses the menu items if it can. So I'd say this is expected behaviour now. I don't think there's much we can do to ensure xbar appears on the left, except maybe delay it starting up or something - but that seems strange.

Closing this for now.

@adamkdean
Copy link
Author

That makes sense. No worries folks, thanks for discussing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants