StScrollBar trough paging animation doesn't respect animations-enabled setting
Cinnamon version: 6.6.7
Problem
When animations are disabled in System Settings → Effects (which sets org.cinnamon.desktop-effects-workspace to false), most UI animations are correctly suppressed. However, clicking on the scrollbar trough (the empty area above/below the handle) still animates smoothly when paging, because StScrollBar's trough paging animation in C code does not check StSettings.animations-enabled.
Many users intentionally disable animations system-wide (for accessibility, reduced motion preference, performance, or personal preference) and expect consistent behavior:
| Action |
Animates when disabled? |
| Window map/close effects |
❌ Correctly off |
| Workspace switching |
❌ Correctly off |
| JS popup menus |
❌ Correctly off |
| Scrollbar trough click paging |
✅ Still animates (unexpected) |
Steps to reproduce
- Go to System Settings → Effects
- Disable "Desktop and window effects" (or set
org.cinnamon.desktop-effects-workspace to false)
- Open the main menu and click on the empty area of the applications list scrollbar
- Observe that the scroll still animates with easing curve
Root cause
In src/st/st-scroll-bar.c, function trough_paging_cb (around line 430), the code reads slow-down-factor from StSettings but never checks animations-enabled:
settings = st_settings_get ();
g_object_get (settings, "slow-down-factor", &slow_down_factor, NULL);
/* FIXME: Creating a new transition for each scroll... */
transition = g_object_new (CLUTTER_TYPE_PROPERTY_TRANSITION,
"property-name", "value",
"interval", clutter_interval_new (G_TYPE_DOUBLE, value, new_value),
"duration", (guint)(PAGING_SUBSEQUENT_REPEAT_TIMEOUT * slow_down_factor),
"progress-mode", mode,
"remove-on-complete", TRUE,
NULL);
st_adjustment_add_transition (priv->adjustment, "value", transition);
Meanwhile, animations-enabled is properly set on StSettings in js/ui/main.js:
function updateAnimationsEnabled() {
let settings_enabled = global.settings.get_boolean("desktop-effects-workspace");
animations_enabled = (!software_rendering) && settings_enabled;
St.Settings.get().animations_enabled = animations_enabled;
}
The JS layer consistently respects this flag via adjustAnimationTime(), but the C-level scroll bar never checks it.
Proposed fix
In trough_paging_cb in st-scroll-bar.c, before creating the transition, check if animations are enabled. If not, use st_adjustment_set_value() directly instead:
settings = st_settings_get ();
g_object_get (settings,
"slow-down-factor", &slow_down_factor,
"animations-enabled", &animations_enabled,
NULL);
if (!animations_enabled) {
st_adjustment_set_value (priv->adjustment, new_value);
return ret;
}
This would also make the behavior consistent with other scroll actions:
- Handle dragging →
set_value() (no animation)
- Mouse wheel →
set_value() (no animation)
- Trough click with animations off →
set_value() (no animation — currently broken)
- Trough click with animations on → animated transition (unchanged)
Additional context
- The
trough_paging_cb function internally uses CLUTTER_EASE_OUT_CUBIC, CLUTTER_EASE_IN_CUBIC, and CLUTTER_LINEAR easing modes depending on the phase (first press, repeated press, sustained hold).
- The
scroll-start and scroll-stop signals are still emitted correctly during trough paging.
- This affects all
StScrollBar instances in Cinnamon (menu, popup menus, notifications, etc.), not just the main menu.
StScrollBartrough paging animation doesn't respectanimations-enabledsettingCinnamon version: 6.6.7
Problem
When animations are disabled in System Settings → Effects (which sets
org.cinnamon.desktop-effects-workspacetofalse), most UI animations are correctly suppressed. However, clicking on the scrollbar trough (the empty area above/below the handle) still animates smoothly when paging, becauseStScrollBar's trough paging animation in C code does not checkStSettings.animations-enabled.Many users intentionally disable animations system-wide (for accessibility, reduced motion preference, performance, or personal preference) and expect consistent behavior:
Steps to reproduce
org.cinnamon.desktop-effects-workspacetofalse)Root cause
In
src/st/st-scroll-bar.c, functiontrough_paging_cb(around line 430), the code readsslow-down-factorfromStSettingsbut never checksanimations-enabled:Meanwhile,
animations-enabledis properly set onStSettingsinjs/ui/main.js:The JS layer consistently respects this flag via
adjustAnimationTime(), but the C-level scroll bar never checks it.Proposed fix
In
trough_paging_cbinst-scroll-bar.c, before creating the transition, check if animations are enabled. If not, usest_adjustment_set_value()directly instead:This would also make the behavior consistent with other scroll actions:
set_value()(no animation)set_value()(no animation)set_value()(no animation — currently broken)Additional context
trough_paging_cbfunction internally usesCLUTTER_EASE_OUT_CUBIC,CLUTTER_EASE_IN_CUBIC, andCLUTTER_LINEAReasing modes depending on the phase (first press, repeated press, sustained hold).scroll-startandscroll-stopsignals are still emitted correctly during trough paging.StScrollBarinstances in Cinnamon (menu, popup menus, notifications, etc.), not just the main menu.