President Obama will soon sign an executive order barring federal contractors from discriminating against gays, lesbians, and others based on their sexual orientation. The gay-rights lobby has long wanted this measure.