Performance fix: Only update ruler on horizontal scroll