synchronize selection of preview with editor