[BUGFIX] Fluid paginate widget wrong number of links

If the maximumNumberOfLinks configuration option is set to 8
the widget will render 10 links.

Solved the problem by changing a plus to a minus in the calculation
of the display range end and added unit tests for several cases.

Resolves: #53458
Releases: 6.2, 6.1, 6.0
Change-Id: Ic1c55b0bf925b546d119c67433f63e662493a08b
Reviewed-on: https://review.typo3.org/25537
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters