Week 5: Curves Merged, Gradient Widget Begins
This is a weekly update from my Google Summer of Code 2026 project with KDE, improving effect widgets in Kdenlive, a free and open source video editor.
MR !887 merged
The Curves widget MR got merged to master this week and will ship in the Kdenlive 26.08 release. Final change before merge was replacing blockSignals(true/false) pairs on the point spinboxes with QSignalBlocker objects, which auto-unblock when they go out of scope cleaner and safer than manual pairs.
Gradient widget skeleton
Started work on the Gradient widget, targeting the gradientmap MLT filter. The filter already supports up to 32 color stops via stop.N parameters (e.g. stop.1="#ff000000 0.0"), but Kdenlive's existing XML only exposed 2 stops with the wrong parameter type.
Built a new GradientEditWidget in src/assets/view/widgets/ with:
- Draggable color stop handles on a live
QLinearGradientpreview bar - Left-click on empty area adds a stop with an interpolated color
- Right-click on a handle removes it (minimum 2 stops enforced, max 32)
- Serializes to/from the MLT
stop.Nformat via a newParamType::GradientEditorwired throughAssetParameterModel - Project save/reload round-trips correctly
Added gradienteditwidgettest.cpp with 8 assertions covering serialization round-trips, add/remove stops, min/max enforcement, and position snapping. All passing.
What's next
Julius Künzel suggested the widget be designed for potential upstreaming to KDE Frameworks, and pointed to Qt-Color-Widgets as a reference; it has a GradientEditor class with a polished UX. Investigating whether to wrap that instead of maintaining a custom implementation. Will update once there's more clarity on the direction.
Both the Gradient widget MR and the Qt-Color-Widgets investigation are in progress; more next week.