“I am 25 years old,” he wrote. “I went to nursery, kindergarten, then I finished primary school, junior high school and, ultimately, high school. Simple mathematics shows that for more than half of my life, for five days a week, I spent most of the day under the care of teachers. It is thanks to the people I met at school that my life’s path has gone the way it has.”

But leading figures in the government have been mostly dismissive of the teachers’ plight, reflecting the fact that they are generally not considered a part of the party’s constituency.

Krzysztof Szczerski, President Andrzej Duda’s chief of staff, appeared to suggest during a recent interview with state-owned radio that teachers should have more children if they want to earn more money.

“Teachers are not obliged to live in celibacy,” Mr. Szczerski said. “Those transfers that are made today, for example for Polish families, including 500 Plus, they also apply to teachers,” he said, referring to a government benefits program.

Patryk Jaki, a deputy justice minister who lost his bid to become Warsaw’s mayor, compared the teachers’ methods to those of the armed forces of Nazi Germany when he said on Tuesday that the tactics of the strikers in the city of Sosnowiec — where a line of striking teachers awaited those who were not stopping work — were “just like the Wehrmacht.”

“I do not wish them to ever teach my child or any other children,” he said. “This is humiliating people, ostracism, which personally is unacceptable to me. People who have made this column should never be teachers.”

But Jaroslaw Kaczynski, the leader of Law and Justice and the most powerful politician in Poland, has mostly steered clear of the subject of teachers in the past weeks. Instead, he has tried to keep the focus on cultural and social issues, seeking to portray his government as a defender of Christian values under siege from the secular West.