After Mr. Trump was elected president in 2016, a straw poll of building residents found that two-thirds of the 253 condo owners who participated wanted to remove the name, while 23 percent wanted to keep it. But a lawyer for a Trump subsidiary sent a letter promising to file suit if the board took any action.

In the letter, Mr. Trump’s lawyer, Alan Garten, said that if the condo made any effort to remove the Trump lettering, Mr. Trump would “commence appropriate legal proceedings to not only prevent such unauthorized action, but to also recover the significant amount of damages, costs and attorney’s fees.”

That was no small matter in the minds of many condo owners. Mr. Trump has a reputation as a vigorous if not always victorious plaintiff and defendant whose determination to drag out a court fight could cost a fortune.

Mr. Trump, for instance, spent 15 years fending off a class-action lawsuit over the use of 200 undocumented Polish workers at his first signature luxury building, Trump Tower. He settled the matter in 1998 in a once secret settlement in which his opponents essentially got everything they had originally asked for, $1.375 million.

Mr. Trump, however, did not admit any wrongdoing.

And the battle over the T-R-U-M-P letters at 200 Riverside may not be over. Amanda Miller, a spokeswoman for the Trump Organization, called the judge’s decision both “unprecedented” and “limited to a technical issue.”