By citing the city, Mr. Trump seemed to be reaching for a stereotype of a coarse industry town where workers would cheer the return of coal (and where they might also scoff at the comparison to Paris). But many are no longer waiting for old industry to return. And Pittsburgh has joined with international cities, Paris included, to commit to reducing its own emissions.

If anything, the city today stands to be affected more by Mr. Trump’s threats to repeal the Affordable Care Act than by his promises to revive the steel and coal industries.

“The economy looks more like Boston than it does Gary, Ind.,” said George Fechter, who was chief executive of the McGowan Center for Artificial Organ Development at the University of Pittsburgh. He called the president’s comments “absolutely outrageous,” adding “he doesn’t represent the people of Pittsburgh.”

In remaking itself, Pittsburgh has benefited from resources that a struggling city like Detroit, for example, never had: flagship universities like Carnegie Mellon and the University of Pittsburgh, which produce their own tech entrepreneurs, medical campuses and cultural events.

Pittsburgh’s transformation from a steel town to a center of “eds and meds” has been visible even on the city’s streets.

“It’s almost like I watched soot come off the buildings — the buildings turned from black to beige while I lived there,” said Richard Florida, an urban economist who has championed the emerging knowledge economy in cities like Pittsburgh. He taught at Carnegie Mellon and lived in the city from the late 1980s through the early 2000s. “It’s not the typical down-in-the-dumps Rust Belt town. It’s still in the midst of a transformation, but it looks like it has turned a corner.”

Perhaps no place has come to represent Pittsburgh’s shift from heavy industry to high tech more starkly than the East Liberty neighborhood, which has seen almost unrelenting redevelopment. The neighborhood now has a Whole Foods; Pittsburgh Google moved its office here from Carnegie Mellon University’s campus in 2010; and the Ace Hotel opened in an old Y.M.C.A. building in 2015.