selection and color bugfixes