Backports fix to #304 - background position merging.

* Background positions with more than 2 components were treated incorrectly.
Version 2.2.22.