A group of prominent and politically well-connected Washingtonians are the stockholders in a corporation that is a principal backer of legalized gambling in the District of Columbia, court papers disclosed yesterday.

Most of the 17 stockholders in Washington Jai Alai Corp., which seeks to operate an arena here where spectators would place parimutuel bets on games, are closely identified with Mayor Marion Barry, former mayor Walter E. Washington and the late president Lyndon B. Johnson.

Among the stockholders are developer Theodore R. Hagans Jr., who was chairman of Barry's inaugural committee last year; Charles T. Duncan, who was D.C. corporation counsel in Washington's administration, and Tyler Abell, who was an assistant postmaster general in President Johnson's administration and whose wife was Lady Bird Johnson's social secretary.

The corporation, most of whose owners have never been previously identified, is one of two principal backers of the D.C. Committee on Legalized Gambling. The committee is seeking to put an initiative measure on the D.C. primary election ballot next May 6 that would authorize parimutuel betting and establish a city-run lottery.

The other principal backer of the initiative is the D.C. Retail Liquor Dealers Association.

The list of the jai alai corporation's stockholders came to light yesterday when the gambling committee went to court in an attempt to block the U.S. attorney's office from enforcing a provision of the city's initiative and referendum law that outlaws the paying of people to collect signatures on election petitions.

The committee admitted that it hired about 50 young people last August to collect signatures from voters in a futile effort to qualify the issue for the Nov. 6 ballot. The number of signatures collected fell short of the required figure.

The violation was "inadvertent and unintentional," the committee said in a document filed with U.S. District Court.

When the apparent violation was first disclosed, spokesmen for groups of black Protestant clergymen opposed to legalized gambling protested to the Board of Elections and Ethics. The board referred the question of possible prosecution to the U.S. attorney.

Assistant U.S. attorney John Polk told U.S. District Judge Louis F. Oberdorfer yesterday that prosecution is still possible, but no decisions has been made.

The Board of Elections and Ethics did not invalidate the signatures that had been collected by the paid workers. Recently it granted the gambling committee the right -- tentatively -- to count the signatures collected last August toward the total number if must submit by Jan. 6, 1980, to get onto the ballot nexy May.

Martin E. Firestone, lawyer for the gambling committee, told Judge Oberdorfer that the group must hire people again to meet the January deadline. To do this, Firestone said, the gambling committee needs an immunity against prosecution while the validity of the law against hiring signature collectors is being decided in another court suit.

Oberdorfer promised a ruling on Monday.

Until yesterday, only Firestone and another lawyer for the gambling committee, Richard K. Lyon, had acknowledged that they and their wives are stockholders in the Washington Jai Alai Corp.

Abell, in an affidavit filed in court, listed himself as treasurer of the corporation. If the gambling measure is approved by the voters, Abell said the firm would apply to the future D.C. Gaming Control Board for a franchise to operate a jai alai fronton (arena) in the city.

Jai alai, a fast-paced game popular in Latin American and played commercially in such areas as Florida and Connecticut, is a sort of cross between handball and tennis.

Other stockholders listed by Abell in his affidavit were:

Flora L. Bress, widow of former U.S. attorney David G. Bress, a Johnson appointee; Todd and Gladys Duncan, parents of Charles T. Duncan; Bryant G. Harris, a businessman; Delano E. Lewis, telephone company executive and director of Mayor Barry's transition team; Dr. Edward Mazique, a physician and early backer of Del. Walter E. Fauntroy, and Mazique's wife, Frances.

Also, Robert Grayson McGuire Jr., a funeral director and former member of the Board of Elections, and his wife Elinor; Dale Miller, a lobbyist representing Texas interests who was chairman of President Johnson's inaugural in 1965, and Miller's wife Virginia (Scooter); Flaxie M. Pinkett, a real estate broker and supporter of Walter Washington, and two without publicly reported political connections, Robert R. Smiley and Joseph Smith.