Gretchen Whitmer looked angry and pale in an ad released this month by her Republican opponent in the Michigan governor’s race. She appeared to scowl, lips pressed into a frown beside a photo of masked gunmen while the narrator accused her of extremist beliefs.

Whitmer hit back — accusing the campaign of Republican Bill Schuette of using a picture taken of Whitmer the day she revealed to colleagues in the state senate that she had been raped in college.

“That was one of the hardest days of my adult life. I was just incredulous they would take something from the most painful time of sharing my story,” Whitmer told The Washington Post. “I thought it was important to call it out. ”

Schuette’s campaign said it had gotten the image from a news article — but removed the ad from promotion on the candidate’s YouTube page and put up a new version, using different images of Whitmer.

This wasn’t the first time Whitmer has embraced her gender in the campaign. Schuette, since the primary, has compared Whitmer to former governor Jennifer Granholm — Michigan’s only female governor. Whitmer has portrayed the comparison as more about the fact that both are women than about their policies and accused Schuette of “sexist barbs.”

Whitmer’s reaction may seem unsurprising, but it is not: She is one of several women in high-profile national races this year who have broken from decades-old conventional wisdom that cautioned female candidates against complaining of sexism, lest they be painted as weak or angry or to being accused of playing what Donald Trump called “the woman card” during his presidential campaign.

“They were accused of whining about it. ... Their consultants told them not to do it,” said Celinda Lake, a Democratic pollster, of earlier female candidates. She co-conducted a survey in 2012 that found fears of a backlash against speaking up were unfounded. But not until this cycle — after Trump’s win and the subsequent #MeToo movement to out powerful men accused of sexual assault — has she seen female candidates do so in numbers.

“I think the MeToo movement really freed them,” Lake said. “They sense the change. ”

“It’s very different,” agreed Christina Reynolds, who worked as Hillary Clinton’s deputy communications director in 2016, on a presidential campaign that rarely if ever responded directly to Trump’s repeated attacks on Clinton’s “stamina. ”

“You couldn’t seem angry; you couldn’t seem defensive,” Reynolds said. “That did not wear well for women, and we were very conscious of that. ”

That thinking appears to be changing, and not only for Democrats.

“Anyone who thinks Marsha Blackburn can’t win a general election is just a plain sexist pig,” a spokeswoman for the Tennessee Republican told The Post in February, during Blackburn’s Senate primary.

The remark caught the attention of Kelly Dittmar, an assistant professor of political science at Rutgers University and a scholar at the Center for American Women and Politics, who surveyed and interviewed dozens of political strategists from both parties for her 2015 book on gender in politics.

"It is not common for a Republican woman to call out sexism,” she said, noting Trump’s popularity with the party. But this year, she said, “there’s a contingent of voters really recognizing the ways our political institutions are gendered, and how candidates do use gender in ways to hurt opponents and hurt credibility. ”

If anything, Blackburn has leaned into gender confrontations since winning the primary and moving into a tighter-than-expected general contest against the state’s former governor. Her latest campaign ad features her photo and the headline from a 1972 newspaper clip — “Book sellers end sex discrimination” — and tells the story of her early career as a salesperson in a men-only industry. When her Democratic opponent in the Senate race, Phil Bredesen, called Blackburn “a big girl” who could make decisions about missed votes, her campaign issued a statement saying he “should be ashamed for his condescension toward women.”

In the past, Dittmar said, female politicians often decided that the best way to respond to sexist attacks was to let supporters do it for them, inoculating themselves against accusations of playing gender politics. That is a point Geraldine Ferraro, the first woman to secure a major party’s vice presidential nomination, made on behalf of Clinton during her 2008 primary: “Every time you raise the issue and say ‘that’s sexist,’ you’re accused of playing the gender card.”

This year, it’s often men who have to worry about a backlash as they wage the same kind of attacks against female candidates that have proved effective for decades.

In Nevada, in the only Senate race where a Republican is defending a seat in a state won by Clinton in 2016, Republican Dean Heller ran an ad in July accusing his opponent Jacky Rosen of fabricating parts of her résumé. “No computer degree. She made it up,” the ad declared. It claimed a business Rosen had spoken of founding “didn’t exist.”

Accusations of dishonesty can be especially damaging to female candidates, according to research by the Barbara Lee Family Foundation, because many voters expect women to be more honest and ethical than men and hold them to a higher standard. But a week after Heller launched his “imaginary business” ad, Rosen turned it around on him. The campaign pointed to an official transcript for a computing degree she obtained in 1985, as well as contemporary documents indicating she worked as an independent consultant in the following decade.

“I know how hard I worked waiting tables to help get my college degree and be the first in my family to graduate college, and I know how hard I worked to build my career as a computer programmer and as an independent consultant,” Rosen told the Las Vegas Review Journal. “It’s nothing new for women running for office to have their experience baselessly dismissed or their qualifications questioned. ”

Heller’s campaign stepped back from the sweeping claims in its ad, arguing instead that Rosen had misrepresented which college she attended and “made up a story about ‘building a business.' "

But Rosen’s campaign has continued to catalogue what it calls Heller’s sexist attacks — including a Facebook ad the Republican ran last week in which Rosen’s right eyebrow was apparently Photoshopped into a high arch.

The campaign said it was an error and that it removed the ad “when it was brought to our attention."

Now, even as more female candidates seem comfortable raising such complaints, toss-up races are still littered with caricatures intended to make them look weak, angry or unserious — attacks that work especially well against women, according to the research of Dittmar, Lake and others.

In Kentucky, Rep. Garland Garland “Andy” Barr’s attack ad, the face of Amy McGrath, his Democratic challenger, is plastered with words such as “radical” and “feminist.” A video produced by the Republican Congressional Leadership Fund PAC depicts Democratic candidate Katie Hill in blue-and-pink pastels, eyelids fluttering and a phone glued to the side of her face. The Democratic Congressional Campaign Committee decided to portray Rep. Claudia Tenney (R-N.Y.) with a clip of her hunched over a lectern, appearing to rub her back, recalling the old, tired woman trope that political researchers have documented throughout modern electoral history — and that Trump evoked in his race against Clinton.

Clinton’s supporters often called him sexist, and the candidate herself attacked Trump for things he said about other women. But rarely if ever did she or her campaign complain of sexism — a conscious decision, her advisers say.

“I couldn’t figure out how to be either funny or push back without being viewed as not being able to take it, which is the kind of thing they say about women at high levels,” Clinton recalled long after she lost the election. “Or being called angry, which is another sort of dealbreaker for people.”

Whitmer said she wrestled with the same questions before she decided to accuse her opponent of sexism on live radio in the middle of the Michigan governor’s race.

“You always have to think in the back of your mind, ‘What’s it going to mean?’ ” she said. “Once we call it out, we’re talking about sexism, not drinking water or fixing the roads.”

Now that she has done it, she does not regret it. “The culture is changing so quickly right now, for the better,” Whitmer said. “It’s catching a lot of people by surprise, and lots of males engaging in it are getting caught flat-footed. ”