Fixes #697, #899 and possibly #341. Reduce rail width by 1px to account for rounding issues