Supports counting inbox, due_soon, or overdue tasks.
Fairly large code changes, including creating a new helper class.