IN VIRGINIA, A REPUBLICAN governor and a GOP-dominated legislature have joined forces with Democrats to enact the first long-term increase in transportation funding since the Reagan administration — and the state’s biggest tax increase in nearly a decade. That is a signal achievement, and one that will stamp Robert F. McDonnell’s governorship as a long-term success.

By generating a minimum of $880 million annually for roads, rails and bridges, the state’s lawmakers rescued a buckling infrastructure network, laid the groundwork for future prosperity and bucked the pernicious influence of anti-tax ideologues who delayed a deal for years by insisting that highways could magically be built without new revenue.

The Virginia deal, grounded in pragmatic thinking, is a credit to the leadership of Mr. McDonnell and House Speaker William J. Howell (Stafford), Republicans who elevated problem-solving above partisan orthodoxy, and to Democratic leaders who hammered away at the issue for years while remaining open to compromise.

The fundamentals of the deal have long been evident: Republicans would have to bend by allowing substantial new taxes; Democrats would have to bend by permitting some money for roads to be cannibalized from existing spending on schools and other public services.

But until Mr. McDonnell explicitly endorsed that approach last month, Republicans, especially in the House of Delegates, were loath to go along. While the governor’s plan was substantially revised, the basic idea — raising taxes and shifting existing revenue for roads — survived.

In addition to the new statewide money, the transportation bill authorizes Northern Virginia and Hampton Roads, the two most traffic-clogged parts of the state, to generate hundreds of millions of dollars annually in local revenue for local projects. That departs from the principle that transportation funding is mainly a state obligation. But there is logic in expecting richer, urban regions of the state to address their own problems, while at the same time ensuring that the additional taxes be used close to home.

It took Richmond 27 years to devise a new funding system for its transportation network. The plan that emerged isn’t perfect — it may be too small and might have to be revisited after a decade or two. But for now, Virginia’s most critical problem, relegated to the back burner since 1986, finally has a solution.