It is a dramatic irony because because the real queen Gertrude remarried in Real Life, with apparently no objection, after her husband died. She married her brother-in-law, Hamlet's uncle.
Explanation: As the play tend to reproduce what happened in real life to Hamlet's father, The Ghost, it's possible to identify irony in Gertrude's words “The lady protests too much, me thinks.” as they were living a huge drama, in the play, and in real life.
Although we never learn exactly what changes Hamlet asked The Players to make in their script, it is almost certain that the changes included the dumb show portion that presents the Fellow pouring poison into the King’s ear as well as the lines about fidelity and widowhood. One aspect of the irony is that Hamlet requested the changes so he could watch Claudius’s reaction: to “catch the conscience of a king.” He later tells his step-father. Dramatic irony is simply giving the audience more information than another character has. When Gertrude says this, she is speaking to the audience, not another character. She is foreshadowing any negative consequences of another character's actions.