Use 'tput colors' as last resort (e.g. for TERM=screen under screen/tmux)