Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Allow negative maximum slider values #1022
Previously, the initialization of minimum_value to 0 prevented
This fixes https://gna.org/bugs/?25618.
If someone only calls slider::set_maximum_value() and not slider::set_minimum_value(), this would obviously lead to unexpected results (previous value of 0 was probably a saner default in that aspect), but there are currently no such place in the code base. I pondered whether I should add a function for setting both the min and the max in the same call (it's somewhat awkward to be unable to set minimum unless maximum is already set), but I went for the simpler solution.
well it's just one line, so i can eaily revert it if it clashes with my work. also my visual studio has suddenly stopped working so it might take a while before progress on my work.
my original plan to fix this issue was to replace the set_mimimun/maximum_value functions with a single set_value_range function that takes 2 parameters.