Yanno.......................if I ever had to go to court, there is a very good chance that the judge would address me as "Mr. M.....".
But, I'm retired military, and have earned the right to be called by my military title. Matter of fact, in regular, as well as official correspondence, I can write "R..... M....., PO1, USN (Retired)", as that is now my official title since I've served long enough to have been officially retired from the Navy. Would I think it was wrong for a judge to address me as "Mr. M......." instead of "Petty Officer M........"? Not really, because I'm both.
It's silly to be upset at the judge for not calling Trump "President Trump". Matter of fact, that would be wrong of her to call him that because he's no longer the president. If she wanted to be formal and use his actual title, it should be FORMER President Trump.