Limit some setting values to sensible ranges