Lynn Nottage’s play “Sweat,” about the American working class, was awarded the prize for drama. And the drama critic Hilton Als of The New Yorker won for criticism.

The Pulitzers this year come as financial pressure drains many news organizations of the resources to pursue top-flight journalism. They also come in the face of a combative stance from President Trump, who has called the news media “the enemy of the American people.”

But for one day, at least, newsrooms came together in celebration, and the journalism industry’s focus was on its accomplishments and purpose, rather than its woes.

The International Consortium of Investigative Journalists, McClatchy and The Miami Herald shared the prize for explanatory reporting for their coverage of millions of leaked documents known as the Panama Papers. (The Herald also won in another category — Jim Morin was awarded the prize for editorial cartooning.)

Eric Eyre of The Charleston Gazette-Mail won the investigative reporting prize for coverage that laid bare the relentless flow of opioids into West Virginia counties with the highest rate of overdose deaths in the country. The East Bay Times of Oakland, Calif., won the breaking news reporting prize for its coverage of the “Ghost Ship” fire in December that killed 36 people at a warehouse party, chronicling the city’s failures that led to the tragedy. The prize for editorial writing was awarded to Art Cullen of The Storm Lake Times, a twice-weekly newspaper in Iowa with a circulation of 3,000, for editorials that held corporate agricultural interests accountable. The Times is owned by Mr. Cullen and his older brother.