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
Hide Menu Bar #633
Comments
This will likely cause some confusion for people who have lost their menu and can't get it back, if it's not done carefully. The UI to bring the menu back (ex. preferences, view menu, etc) won't be accessible, and having a single keybinding, which can't be inspected since preferences won't be available, is not a very discoverable way to bring it back. I'm not against allowing to hide the menu bar, I just think we should be careful to make it intuitive to bring the menu bar back. |
Ctrl + m is used to toggle menu bar off and back on in kwrite and kate. |
Hi, Recently I lost the menu bar. Any ideas? |
Is that on unity with the separated menubar? |
Yes. Using unity I'm not able to make it visible again
|
@peterrobles unfortunately that menu is entirely done by Unity and Ubuntu's own hacks, Geany does not hide the menu, as you can see from the discussion above. So you would be better off asking on a Ubuntu forum. |
Ok, I wonder if Ubuntu has changed the way to deal with that. Thanks for your help, really appreciated 2016-05-13 10:47 GMT+01:00 elextr notifications@github.com:
|
To be clear, Geany just uses the standard GTK 2 library calls to draw the menus. In the normal GTK library that displays at the top of the application window, but Ubuntu ships a modified GTK library that displays the separated menu. Probably the Ubuntu library isn't as well tested as the standard GTK library since that is used on many more systems. Also as some of the Geany menus are variable, Geany might delve further into some of the darker corners of the library than other applications. There has always been a small trickle of issues relating to the Unity menus but nobody has suggested any solutions. |
As a workaround for this issue, I have a Toggle Bars plugin that hides the menu and status bars initially but allows toggling them with a keybinding. |
Looks like problem of unity-gtk*-module, which I installed just from curiousity. When I revmoved it, menu stopped disappearing. (I'm running Gnome on Opensuse). |
A simple mean could be add a keybinding only (no entry in the menu), and leave it unbound by default. That's not an awesome UI, but it's easy to do, and should prevent anyone not having explicitly opted in to the feature from losing their menubar; and I could suppose that if someone set a custom keybinding for it, they should know they did it. |
But should probably have an "are you sure" dialog, keybindings get hit accidently. |
You think? If the user "frequently" toggles the menubar, it'll be annoying, and if it's a casual thing, it's just as easy to forget. |
Maybe we are misunderstanding, but I would have thought the casual/accidental keybinding user was the one that needed the reminder. |
Tried the above solutions. Still the menu bar is invisible!! |
@vineeshvs please do not hijack other issues for your problems. This is not about invisible menus, it is an enhancement request to add the capability to hide the menu. To repeat the point I made above, Geany does not hide menus, something in your system is doing that, and its not a Geany issue. |
@elextr Sorry for that. I posted because one of the previous posts went like this. Anyway, thanks for the suggestion.
|
@vineeshvs to repeat again, its nothing Geany does, you might be better to ask on a Ubuntu forum. |
@vineeshvs try running Geany from the terminal like |
To hide/show the menu bar takes ALWAYS a lot of time:
UPDATE: there is a perfect solution; visit #633 (comment) Suggestion: If users will lose the menu bar by accident, they could google it how to bring it back in Geany. By the way: to hide/show the menu bar was asked in August 2015. That’s nearly 5 years. |
Clearly nobody has wanted it enough to make a pull request. |
I used to hide the menubar with the geanypy plugin... then when that stopped working (b/c gtk3), I figured out how to do it with the lua plugin... Then I didn't need it anymore because I started using global menus. Recently, I found that old lua script still in the geany config folder. For anyone who wants it: geanylua-scripts |
I can't find lua script in geany config folder in Lubuntu. Could you please describe the steps to hide the menu? |
@ralf3u The package you need to install is The script basically just does what you described. Hides |
@xiota
And where should be this script? Thank you for an answer in advance. |
@ralf3u If the "Lua Script" plugin is enabled and |
@xiota OK, "Lua Script" plugin is enabled, and I created the folder "geanylua" in "~/.config/geany/plugins". But I don't know how to program a script. So my two questions: |
Here a step-by-step description for Debian/Ubuntu (when Geany was installed with
After every restart of Geany, the menu bar will not be there. In this example one can toggle show/hide menu bar with the shortcut F12. If you want that after every restart of Geany the menu bar is visible at the beginning, then change in the document init.lua the line For more information visit https://github.com/xiota/geanylua-scripts In case you don't want the feature any more, here two possibilities: |
The lua script solve the issue. But I would like to ask how the developers think about this now. Love Geany good 'old open source simplicity and customizability but this only issue prevented me of this discovery for years passing from one text editor to the next. Less distraction is esencial for me. |
Just to give some examples Thunar uses ctrl+m to hide menu bar, cherrytree F12, gimp has an option in preferences to use it as context menu. Even a various preference like the scroll bar would suffice. The lua plugin seem unmaintained. |
From various discussions over years most of the Geany devs are not in favour of menu hiding mostly because of the "hidden by accident and can't find how to get it back" and the "not everything can be performed from the keyboard" problems. So they are not going to make a PR, and nobody else has. |
An informed preference with keyboard shorcut would be great for both prevent accidents and extend customizability in my opinion. Just my two cents. |
It is not true that no one ever made a pull request to include the feature. See #2972 and geany/geany-plugins#1138. Core Geany devs appear to simply not want menubar hiding to be included in Geany. |
One of the things I like more about open source is the simplicity needed for maintain something without income for a long period of time. That for me means that you can´t think of all use cases but that you share your own and leave it open to others to contribute if needed. I read #2972 and for me everything that needs to be said had been. A View menu option with a warning and a keyboard shorcut, or/and an informed preference setting with reference in the manual or the faq or even an unsetted keyboard shorcut option would be amazing. Again, in my opinion. Thanks anyway. |
@asoymos It's been a while since I looked at that patch, but everything you mention is in that patch except for having the option in the menu itself (because the user might not know how to restore the menubar if it was hidden from the menubar). A major sticking point with core devs is the menu state when Geany is restarted. They seemed to want the option to keep the menu hidden to be removed, which in my opinion, defeats the purpose of having the ability to hide the menu in the first place. |
Oh well, #2972 didn't show in my search because it is closed, and I didn't look for plugins.
Most don't, so clearly those are not going to work on it, and since the PR was only open for a month none of those who might accept it had time to look at it. (I guess its Murphys law that the ones who might accept it are those with least time available for Geany :-) Not sure what the availability of the plugin collection maintainer is, but I'm sure its not great, so if nobody else tried, tested, and supported the plugin it is likely they didn't spend any effort on it. |
You, yourself, participated in discussion in that PR. I closed the PR because we had reached an impasse that made it highly unlikely that the PR would be accepted. |
I would also prefer that the state is preserved, but this could be an informed preference. No 'View' menu option instead 'Hide/Show menu bar' and 'preserve state' preferences with a note that a keyboard shorcut could be set. What do you think @xiota? |
So? That doesn't mean I remember it, thats why I searched.
Well, thats what happens when all requests for changes are rejected. I just re-skimmed it and those involved seem to be trying to address the concerns they have so it can be accepted. But the sticking points seem to be:
|
There's also a link to that PR on this page, just above the message before asoymos' first post.
I did make changes to address the purported concerns.
Unconditional hide on startup was provided as an option. The default was to restore state. That wasn't good enough. Devs didn't want the option to be present at all. This is the only point I was unwilling to compromise on, that the option remain. Everything else you mention is easily resolved. For instance, Ctrl+M is commonly used across many applications to hide/show the menubar and could be listed in the manual. Regardless, I now believe the feature would be better implemented as a plugin. That way core geany devs get what they want (that the feature not be part of geany), and users get what they want (the ability to hide the menubar). For now, it can be done with the GeanyLua plugin. |
If I recall, that was provided as a user-selectable option, with the default to preserve state.
I have no problem with that, and believe it is already partially implemented in that PR. But, that PR is dead. I now believe that this feature would be better provided as a plugin. For now, it can be done with the GeanyLua plugin. |
Ok, I withdraw "all", but note that some changes were still not addressed as you yourself said.
Nonetheless some devs did engage with #2972 and try to have it address their concerns, but as you said, you would not accept some of the requested changes (which is your right), so the PR was not merged (which is their right). Somebody else could of course provide a PR that addressed the devs concerns.
Yes thats the simplest solution for users who want the capability whilst that plugin continues to work. But Geanylua has no maintainer (although it gets occasional contributions), and depends on an old version of Lua, so no idea how long it will last. |
I'm willing to write a plugin dedicated specifically to this feature provided I have minimal assurances it will be addressed by devs within a reasonable time frame. (reasonable = I'm flexible. Give me a timeline and stick to it. It can be years if that's all that can be managed, as long as I am told ahead of time that it hasn't been forgotten.) The code has pretty much already been written.
I have personally attempted to keep that plugin working, partially because of this feature. Progress wasn't as fast as I would have preferred, but I believe I was successful.
Something to deal with when it comes to pass... |
I apologize for likely coming across as antagonistic about this. This is a sore spot for me. I feel that I made reasonable attempts to address core dev concerns. Yet it seems we have fundamental differences of opinions regarding providing users with options. I wanted to provide users with the option to be able to hide the menu bar on startup (the default would be to restore the previous state from shutdown), but devs appeared to unconditionally reject allowing users to have this choice. |
Thats not really assurable for a project with all volunteer contributors who do not have scheduled guaranteed time available to address any Geany effort. All devs have very little time, and will spend it on things they are interested in adding, they would have to volunteer themselves that they are interested and if they have time available. And several devs have not been heard from for some time, in the current world I hope they are ok.
No need to apologise, nothing was taken personally, and as you said next, the disagreement is about the idea not individuals.
Correct, because although some may like them, providing options that can cause problems for other users may be a net loss for the overall Geany ecosystem and so some options are not accepted until they can be reasonably protected. Since it might be somewhat obscured from the looooong discussion on #2972 let me explain. The issue with the unconditional hide on startup is that so far the PR has no unconditional and documentable way of reversing that. So someone inexperienced, trying stuff out, can suddenly find themselves without a menu, and no discoverable way of getting it back to reverse the setting. Whilst Geany is not exactly a beginners tool, it does try not to set traps (at least not ones it knows about). That is also why the toggle menu keybinding is required to be unbound by default, so fumble fingers can't trigger it without users having to choose a binding, ie having to opt-in. This is the same as vscode where the hide menubar item is unbound by default and in any case the menubar can be made visible by (AFAIK) fixed key |
The sentence sounds for me as if there would be no google. Just type there for example |
This isn't a problem with the option to hide the menubar "unconditionally" on startup. Restoring the previous menubar state has the same problem. If a user hides the menubar without knowing how to restore it, Geany would still open with the menubar hidden and no obvious way to restore it (if the status window is hidden). Hiding the menubar in that PR does have conditions that need to be met. The menubar will not be hidden if no keybinding is set, no matter what any other setting says. Then to make sure the user is able to restore the menubar, whenever the menubar is hidden, including at startup, a status message is displayed with the current keybinding. The same message could also be sent to stderr for users who do not have the status window visible. Also, as ralf3u points out, the default keybinding for preferences is ctrl+alt+p. From there, the option could be unchecked and the keybinding could be looked up. This procedure would be easy to add to the manual.
That shouldn't be difficult to implement. Just another hard-coded keybinding. But then alt is used in other keybindings, and it could be annoying to some users to have the menubar reappearing. So I would want another option to turn it off, creating yet another likely point of disagreement. (Modern versions of Firefox hide the menubar by default. Alt and alt+__ show the menubar. There is an option to prevent the menubar from being shown when alt alone is pressed.) |
It seems to me that all the hard work had been done, and parties are willing to meet an agreement. As I understand it one side wants the option for the menu bar not to return and the other not want it to be mistakenly vanished. A middle ground could be a a View menu option to hide it and a preference setting to preserve the state with the info about a settable keyboard shorcut. That way experimenting newbies would be adverted, with the menu again after reboot. Advaced users would have an always hidden menu bar (restored hidden state without keyboard shorcut is the same as always hidden no?). And middle users like me who wants sometimes to have it and sometimes not can set the keyboard shorcut. What do you think? |
The only agreement so far is that this feature is better implemented as a plugin.
#2972 already does what you suggest. There is no "middle ground" because, as far as I can tell, Geany devs want the startup setting to be entirely removed from the PR. Even if I address every concern to their satisfaction, they could simply not accept it. For any or no reason. There are open PRs going back years. Hiding the menubar is unlikely to be added to Geany. The most likely way it would happen is if it is forced by GTK, like if some version of GTK4 deprecates the menubar and GTK5 removes it. Then they would have no choice but to find an alternative. But that would be a decade away.
Motivated users can hide the menubar with GeanyLua and some scripts. Or compile Tweaks-UI. Or even write their own script or plugin. Some have even edited the glade file, though I would discourage that approach. If you don't like GeanyLua, peasy is another scripting plugin you could try. It supports both Lua and Python. You would need to compile it yourself though. |
Yes, why not. At least it would be easier than to do the step-by-step-description #633 (comment). |
I already did write a plugin (geany/geany-plugins#1138) that addresses this and some other open issues. It was ignored for six months. I just don't care enough about these issues to try to get devs attention and get scolded. So I closed it for lack of interest. There is a record on this page of those PRs existence, so users who are motivated enough are free to compile the plugin or use the Lua scripts. But if not even one dev is willing to say, "I won't ignore you. It's okay to |
Would it be possible to add an option to hide the menu bar? At least until the Alt key is pressed, like some other applications do (Firefox for example). Currently only the toolbar can be hidden.
I know it's not much, but it would save a few more pixels of vertical space and make it look less cluttered for those who have the need.
The text was updated successfully, but these errors were encountered: