fixed histogram view not updating
fix index out of range problems in color handler