Sen. John McCain (R-Ariz.) arrives at the Capitol in June. (J. Scott Applewhite/Associated Press)

TOTALLY IN keeping with his character, Sen. John McCain (R-Ariz.) declared, one day after it was disclosed he is suffering from a serious form of brain cancer, that “unfortunately for my sparring partners in Congress, I’ll be back soon, so stand-by!” The senator also issued a toughly worded criticism of President Trump’s decision to end support for the Syrian rebels fighting the regime of Bashar al-Assad. Mr. McCain is not going quietly into the night.

We wish Mr. McCain every success as he considers his treatment options for glioblastoma, an aggressive brain tumor. It goes almost without saying that his determination and fighting spirit are legendary.

But we have another wish also: for Washington and the world beyond to pause for a moment to absorb the example that Mr. McCain sets every day. These are times of toxic, partisan warfare, where politicians will say just about anything at all, true or untrue, to gain an advantage. By contrast, Mr. McCain has been, for the most part, and more than just about any other practicing politician, true to his convictions. He is in politics not just to win but, as far as one man is able, to improve our world.

And all over this world, Mr. McCain is associated with freedom and democracy. He has championed human rights with verve and tirelessness — speaking out against repression and authoritarianism, and inviting — no, cajoling — his colleagues, both Republicans and Democrats, to bear witness with him on trips abroad. He has frequently welcomed victims of repression to the corridors of the capital, too, giving them succor and encouragement in the fight against tyranny.

Mr. McCain has displayed a forthrightness that stands out in the ugly atmosphere of disinformation, propaganda, spin doctoring and outright lying that now prevails. The senator, as a presidential candidate in 2000 and 2008, endeared himself to journalists with his openness aboard a campaign bus called the Straight Talk Express. It was refreshing and genuine.

In 2008, the presidential campaign turned nasty in the final weeks. Crowds were shouting epithets and pumping fists in anger upon hearing the name of Sen. Barack Obama, the Democratic nominee. On Oct. 10, campaigning in a suburb of Minneapolis, Mr. McCain grabbed back the microphone from an elderly woman who had begun to say that she didn’t like Mr. Obama because he is an Arab. “No, ma’am. No, ma’am,” Mr. McCain said. “He’s a decent family man, a citizen who I just happen to have serious differences with on fundamental questions.” He added, “We want to fight, and I want to fight, but we will be respectful. . . . That doesn’t mean you have to reduce your ferocity. It’s just got to be respectful.”

That’s an example for today. Basic civility and respect speak louder than name-calling, trolling, shaming and prevarication. It is not some kind of gauzy nostalgia to wish for a politics of forthrightness and decency, so lacking today and so embodied by Sen. John McCain.