emilk / emilk/egui

Slider improvements

Open
#7,338 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
Rust
Stars
30.6k
Forks
2.1k
Avg merge
1d 9h
Merged PRs (30d)
72

Description

**Is your feature request related to a problem? Please describe.**

There is no easy method of determining if the slider value has changed. Checking if the value has changed requires addition variables to store old and current values and a conditional statement.

**Describe the solution you'd like**

Slider should have a method such as ```was_changed```. Currently there are ```custom_formatter``` and ```custom_parser``` methods that allow changes to be post-processed. ```was_changed``` should allow for computations based upon the old stored value and the new (current) stored value.

**Describe alternatives you've considered**

Alternatives seem to be messy old and new value computations, perhaps in a separate helper function.

Contributor guide

Open the contributing guide

Research direction

Start by locating the Slider implementation and reviewing the existing custom_formatter and custom_parser methods. Define how a was_changed method would expose the old and current stored values, then verify that callers can use it for change-dependent computations without keeping duplicate state.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.