IMAGINE WHAT candidate Ronald Reagan would have said about a Democratic president who boasted in widget-making states that he was stepping up sales of badly needed widgets to the Soviet Union. A stern denunciation of subsidizing the communists, a properly righteous attack on cynical politics, a scathing review of the long history of failed foreign policy -- nobody could do it like Mr. Reagan. There is, however, little possibility of a denunciation by Mr. Reagan of a very similar campaign tactic this fall. We are speaking of his announcement that the United States is offering to sell Moscow up to 23 million tons of grain.

The announcement, broadcast on a special hook- up of farm-state radio stations, had to it the obvious aspect of a ploy to win votes in the economically ailing Great Plains states. But from a foreign policy standpoint, the timing was atrocious: the Polish government had just abolished Solidarity. Mr. Reagan says that the Russians should not take his action as acquiescence in what they have had done in Poland. How should they take it?

The grain decision indicates a dismal view of the political process. Mr. Reagan is showing that he believes farmers are more concerned about selling wheat than they are about the dangers of appearing to prop up Soviet-sponsored repression. He is, furthermore, overemphasizing the importance of the issue in the elections: there are only a handful of House seats and perhaps one or two Senate seats seriously contested in places where grain is central to the local economy. Mr. Reagan, you will recall, used to charge the Democrats with viewing the electorate as a collection of special interests to be bought off with government largess.

If the political gains of Mr. Reagan's announcement are likely to be petty, the policy implications are not. Even if we receive hard currency from the Soviets for the grain, the grain is worth more to the Soviets than the oil and gas -- or gold -- they sell to the West to raise the cash. On the stump, Mr. Reagan ignores this bit of elementary economics. But back in the Oval Office, the president may want to reflect on this episode. It has something to teach him about the difficulties of maintaining any embargo that does not rest on a firm international consensus regarding security. Beyond that, the president's own refusal to offend American farmers may assist him in comprehending other governments' reluctance to abandon the Soviet gas pipeline.