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

Better track coloring #347

Merged
merged 2 commits into from
Nov 11, 2024
Merged

Better track coloring #347

merged 2 commits into from
Nov 11, 2024

Conversation

tinevez
Copy link
Contributor

@tinevez tinevez commented Nov 10, 2024

Prior to this PR, the track color was determined by the position of a track in the sorted track array, based on the root labels.

In practice, for large number of tracks, this was not so great when editing tracks a lot. Indeed, the slightest track addition of link removal could completely change the order, hence the track coloring.

Here we simply use the hash of the root label of a track to determine its color, making it independent of the other ones. The color of a track now only depends on the label of its root.

Prior to this commit, the track color was determine by the position
of a track in the sorted track array, based on the root labels.
In practice, for large number of tracks, this was not so great when
editing tracks a lot. Indeed, the slightest track additon of link
removal could completely change the order, hence the track coloring.
Here we simply use the hash of the root label of a track to determine
its color, making it independent of the other ones. The color of a track
now only depends on the label of its root.
@tinevez tinevez merged commit f049c2e into dev Nov 11, 2024
1 check passed
@tinevez tinevez deleted the better-track-coloring branch November 11, 2024 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant