implemented selection visualization