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

Tab bars scroll buttons, double-click creates new empty tab #72313

Closed
duianto opened this issue Jan 29, 2023 · 8 comments · May be fixed by #77883
Closed

Tab bars scroll buttons, double-click creates new empty tab #72313

duianto opened this issue Jan 29, 2023 · 8 comments · May be fixed by #77883

Comments

@duianto
Copy link

duianto commented Jan 29, 2023

Godot version

v4.0.beta16.official [518b9e5]

System information

Windows 10 22H2, Compatibility, Geforce GTX 550 Ti

Issue description

When the tab bars scroll buttons are double-clicked, then they create a new empty tab.
Expected: Scroll the tab bar twice.

Steps to reproduce

The right side of the tab bar shows two buttons: scroll tabs left and scroll tabs right
when there are more tabs than fit on the tab bar.

When Godot is maximized on a display with a resolution of 1920x1080,
then the tab bar shows the tabs, from: scene_name - Copy (10) to: scene_name - Copy (15)

The project has 16 tabs, hopefully, that's enough to fill the tab bar on larger resolutions.
But if the person that tests this has a large enough resolution to show all tabs,
then the tester needs to either:
unmaximize Godot and possibly shrink Godot's width, until the tabs don't fit
or create and save additional scenes to overfill the tab bar

  • to the right of the last scene tab: scene_name - Copy (15),
    click on the button to scroll the tab bar to the left

Godot_v4 0-beta16_win64_CDrkLktPB3

now the tab bar shows the tabs from: 9 to: 14

  • click the scroll tab bar left button twice within 1 second

Expected

The tab bar should scroll to the left twice, and show the tabs from: 7 to 12

Observed

Godot_v4 0-beta16_win64_MeC6aij5kd

A new [empty] scene tab was added to the right of scene 15,
the tab bar scrolled to the rightmost position,
and it now shows the tabs from 11 to 15 followed by an [empty] tab.

The same thing happens when the button: scroll tab bar to the right, is pressed twice within 1 second.

This means that it isn't possible to scroll the tab bar quickly, by pressing the scroll tab bar buttons quickly.

A possible cause

Double-clicking on an empty area of the tab bar, to the right of the rightmost tab, creates a new [empty] tab.

If the scroll tab bar buttons don't have a specific double-click action,
then maybe the double-click event is picked up by the tab bar, behind the scroll tab bar buttons.

This is possibly confirmed by the fact that the double-click action,
also happens when the scroll tab bar buttons are disabled.

The scroll tab bar right button is disabled when the rightmost tab is focused.
The scroll tab bar left button is disabled when the leftmost tab is focused.

Minimal reproduction project

issue, next or prev tab buttons, double click adds empty scene.zip

@Calinou
Copy link
Member

Calinou commented Feb 1, 2023

double-click creates new empty tab

This is intentional behavior, but it was recently discussed to remove it as it's obscure and rarely used.

@gelvinp
Copy link
Contributor

gelvinp commented Mar 31, 2023

To add my two cents, I "use" this feature all the time, but always accidentally when I'm just trying to navigate through tabs, which has caused me to compile my own version of the editor with this feature specifically removed. Especially since the "add new" tab button is right next to the arrow buttons anyways, I'd love to see this removed officially.

@djrain
Copy link

djrain commented Jun 5, 2023

Ah, so that's what I've been experiencing all this time. I was wondering where all those new tabs were coming from. I also thought it was just incredibly buggy.

The whole scrolling arrows thing is terrible UX in the first place, and personally I'm making a plugin to replace the scene tabs entirely. But yeah this should be removed asap.

@Calinou
Copy link
Member

Calinou commented Jun 5, 2023

On a similar note, the ability to change scenes by scrolling the mouse wheel on the list of tabs was removed in 4.1 by #70800. It was often accidentally triggered.

The whole scrolling arrows thing is terrible UX in the first place

What do you propose instead?

@djrain
Copy link

djrain commented Jun 5, 2023

What do you propose instead?

I'm still experimenting to find the set of features that is really best, and I'll make a proper proposal once I'm confident. But just having the tabs as Buttons inside a ScrollContainer is a massive improvement. As in VS Code for example.

@gelvinp
Copy link
Contributor

gelvinp commented Jun 5, 2023

I am honestly completely confused by removing the ability to change scenes by scrolling and not even making it an option. If I have to use the two arrow buttons to scroll but I also have to take my time and carefully make sure I don’t click either of them too quickly to count as a double press so I don’t unintentionally make a new scene instead, I’m going to completely stop using the official builds and patch that back in myself. I consider that a usability nightmare.

@Calinou
Copy link
Member

Calinou commented Jun 5, 2023

I am honestly completely confused by removing the ability to change scenes by scrolling and not even making it an option. If I have to use the two arrow buttons to scroll but I also have to take my time and carefully make sure I don’t click either of them too quickly to count as a double press so I don’t unintentionally make a new scene instead, I’m going to completely stop using the official builds and patch that back in myself. I consider that a usability nightmare.

Unfortunately, options that are disabled by default suffer from poor discoverability. They often end up being dead weight in terms of maintenance, as we have to maintain something that will not be used often (and may be buggy for several months if not years).

@djrain's solution should make it easier to switch between large amounts of scene tabs while avoiding the usability pitfall of accidental scrolling. You can also rely on the Quick Open Scene dialog (Ctrl + Shift + O) to open scenes without having to use the mouse.

@kitbdev
Copy link
Contributor

kitbdev commented Oct 25, 2023

Fixed by #79852

@akien-mga akien-mga added this to the 4.2 milestone Oct 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants