Comment 1 for bug 1645704

Revision history for this message
Egmont Koblinger (egmont-gmail) wrote :

Unfortuantely it's a big mess in the gtk3 version too :(

It seems to me like a design confusion rather than just an implementation bug. What's the desired behavior? We should decide that first.

In profile prefs there's a three-state option: Left, Right, Disabled. In the per-terminal right-click menu there's a toggle whether to show it or not. This is already problematic.

It's unclear whether the profile pref is meant to specify the default for newly opened terminals only, or be always applied for existing terminals of the same profile as well (as it is done with most of the other profile prefs, probably the only exception being encoding's default where the word "Default" makes it clear).

Currently altering this setting modifies the scrollbar immediately for existing terminals. That is, it's not just the default for terminals of the given profile, it's the actual desired value at all the times.

With this approach in mind, the per-terminal "Show scrollbar" toggle in the right-click menu probably can't be defined correctly what it should do. In order for the right-click menu's toggle to make sense, the profile pref should be the default of the terminal only, and as such, the wording should make it clear, plus toggling it shouldn't have an effect on existing terminals.

One more problem: If the profile pref defaults to Disabled (as opposed to Left or Right), and then the user enables "Show scrollbar" in the right-click menu, should it appear on the left or on the right side?

This is a bug where we first need to define the desired behavior in a consistent way, and only after that we can go ahead and fix the implementation issues.

One possibility (not sure at all if this is the best):

Rework the profile prefs: instead of the 3-state option have two 2-state options (checkbox, radiobutton, combobox -- whatever):

- Visible by default or not
- Left or right side

Left vs. right would be regular profile pref, that is, toggling it would have an effect on all the terminals immediately. "Visible by default" on the other hand, as its name implies, would only have an effect on newly opened terminals, and as such, toggling it would have no immediate effect. This way the per-terminal right-click "Show scrollbar" option could be kept.

Another possible approach: Drop the right-click "Show scrollbar" menu, and make the profile pref apply to all the terminals retroactively (as it is probably meant to be now).