ST. PAUL, Minn. (AP) — A Democratic legislator from Minnesota swiftly apologized Tuesday for a tweet he sent that referred to Supreme Court Justice Clarence Thomas as "Uncle Thomas" following a major ruling on the nation's landmark voting rights law.

Thomas, who is black, was part of a 5-4 majority that invalidated part of the Voting Rights Act meant to deter racial discrimination in elections. The ruling makes it tougher for federal officials to prevent states and localities, primarily in the South, from adopting policies that add barriers to voting.

In response, state Rep. Ryan Winkler tweeted: "#SCOTUS VRA majority is four accomplices to race discrimination and one Uncle Thomas. Marriage decision may blur Court's backsliding."

"Uncle Tom" is a connotation to describe someone subservient to another and has its roots in Harriet Beecher Stowe's pre-Civil War novel about slavery, "Uncle Tom's Cabin." The latter part of the tweet refers to the high court's expected decision on gay marriage.

Winkler, who is white, deleted the tweet and told followers in his feed that he didn't understand the phrase to be a racist term. He later told The Associated Press that he was trying to make a point about institutional racism resulting from the ruling.

"I used a term that was too hot for the issue, but I didn't intend for it to be derogatory," said Winkler, who holds a history degree from Harvard.

Chris Fields, secretary of the Minnesota Republican Party, said Winkler's comments were "beyond the pale" and his apology wasn't enough. "If he had any personal integrity, he'd resign," said Fields, who is black.

Winkler, of Golden Valley, had been weighing a run for Minnesota secretary of state, whose office oversees elections. He said he ruled that out several days ago but hadn't announced it.

The four-term lawmaker represents a district that covers western Minneapolis suburbs and is an attorney. He is known for rhetorical clashes with Republicans while on the House floor and on Twitter.