The New York attorney general announced an agreement that would require Xcel Energy, a builder of coal-fired plants, to disclose to investors the financial risks of global warming.