Height pairings on Shimura curves and p-adic uniformization