Changes in the spline interpolation system and the curves widget

* Improved the spline interpolation system
- Added different extrapolation modes in all subclasses
- Added different boundary conditions in the cubic interpolator
* Improved the curves widget, now more versatile and generic
- Separated the paint logic in delegates
- Added level curves paint delegate for using in the Curves image filter