SlickFader
Fader Control based on specific requirements
DESCRIPTION
I wanted a fader with the following behaviors:
1) If you click on the thumb, the thumb is draggable.
2) If you click outside of the thumb, the thumb should automatically snap to the new position.
3) Accurate to the pixel.
Two days and four Advil later, I finished SlickFader.
If you want to change the bitmap I used, here's the steps you need to take:
-- To get 100%-pixel-resolution while you drag, you'll need to change some settings on the MultiPicture control (it can be found at the first-level within my macro):
OutputRangeY Max = [Pixel Height of bitmap]
OutputRnageY Min = 1
OutputRangeY Stepsize = 1
OutputRangeY NumSteps = [Pixel Height of bitmap - 1]
OutputRangeY MouseReso = [Pixel Height of bitmap - 1]
-- Now, you need to set the inputs to the macro with appropriate constants:
Init - Pixel-offset from the lowest thumb-position to initialize to.
cPxl - Pixel Height of bitmap
cTh - Pixel Height of thumb
cTop - Number of pixels in border at the top of the fader (i.e. number of pixels above the thumb at its topmost position)
cBot - Number of pixels in border at the BOTTOM of the fader (i.e. number of pixels BELOW the thumb at its lowest position)
------------------------------
v1.1: Added a prettier graphic; Added support for snap-values.
COMMENTS (6)