fixing buildTextColor function