Northern Virginia lawyers say Del. Floyd Bagley (D-Prince William) has dreamed of being a state judge for more than 15 years and has tried everything he can think of to make his dream come true.

A few months ago he introduced a bill to create a new judgeship and volunteered to take the job himself. Before that, Prince William County lawyers say, he would periodically send them letters extolling his judicial qualities in hopes they would nominate him for a position. Nothing seemed to work.

Now it appears that Bagley may have embarked upon an even more ambitious plan. Reports printed in Bagley's hometown newspaper and supported by legislative sources here say Bagley has agreed to back his longtime rival, H. Selwyn Smith, Virginia's secretary of public safety, for the additional judgeship that Bagley has recommended for the Prince William County Circuit Court.

In return, the sources say, Smith has promised that he will appoint Bagley to a District Court judgeship as soon as Bagley's legislative term ends.

Bagley and Smith hotly deny reports of a deal.

"I would think I'd be considered a hero for backing Selwyn Smith after what he did to me in 1974," Bagley said. Bagley said Smith, then a state senator, effectively blocked his appointment to the bench after Bagley had won the nomination of the Prince Willim County legislators, "I'm backing him because he is the only one considered by the bar to have the type of experience we need."

However, the local bar association's formal support went to the current Juvenile and Domestic Relations Court judge, Herman Whisenant, who also won the backing of the other Prince William County legislators, Sen. Charles Colgan and Del. David Brickley.

A compromise worked out between Bagley, Brickley and Earl L. Bell (D-Loudoun) led to the General Assembly's decision today to appoint Whisenant to another county circuit judgeship, which will come open Aug. 1 when Judge Arthur Sinclair retires. That position will not carry the seniority of the proposed judicial slot that, if approved by the legislature, would come open on July 1.

Because of scheduled retirements by other judges in the county, the judge -- Bagley wants it to be Smith -- who takes office on July 1 would become the county's senior judge within a few years. Senior judges fill District Court judgeship vacancies on an interim basis when the General Assembly is in recess. While such appointments are subject to confirmation by the General Assembly, the Virginia legislature seldom declines to confirm sitting judges.

Smith is now given a good chance for appointment to the new circuit judgeship -- if it is created. Some legislators say it is endangered because the bill that would create it contains wording that would grant additional power to the House and Senate courts committees.

One high legislative source called the supposed maneuvering "an abuse of the system," pointing out that Bagley failed in his most recent attempt to win support from the local bar association for a judicial appointment. "Sure it bothers me, but how are you going to stop it?" said the legislator.

Members of the Prince William County bar say there has been "bad blood" between Bagley and Smith since the mid-1960s, when Bagley fell 14 votes short of unseating then-commonwealth's attorney Smith and was required to pay the cost of a recount.

"It's very clear that a deal is the only reason [Bagley] would support him," said one, who refused to let his name be used, saying he feared he might one day find himself trying a case before an irate Judge Bagley.

Smith, who supervises the state's corrections department and state police as a cabinet member in Republican Gov. John N. Dalton's administration, acknowledged that Bagley was supporting him for a judgeship but said he had not discussed the matter with him in weeks. "I can categorically deny that any deal was made," Smith said. "It is repulsive to me that anyone would think Selwyn Smith would make such a deal."

Del. George E. Allen (D-Richmond) chairman of the powerful Courts of Justice Committee, which oversees judicial selection, acknowledged today that such a scheme was possible under current law but added, "I'm sure there's nothing to it. I haven't heard anything about it." Bagley is also a member of the committee.

Del. Vincent F. Callahan (R-Fairfax), who heads the Republican caucus, used the controversy as another opportunity to criticize as unfair a judicial selection process that is controlled by Democrats.

Under the current system, members of the majority Democratic Party meet in a closed caucus to hear local legislators present judgeship nominations for their districts. In almost all cases, the caucus endorses the nominations of the local legislators, and all members who attend the caucus are bound to support that decision in official legislative votes.