WASHINGTON (AP) _ A House panel approved legislation Thursday to require that all guns be detectable by current X-ray machines and metal detectors.

The House Judiciary Committee gave voice-vote approval to the measure after defeating, 23-12, an amendment by Rep. George W. Gekas, R-Pa., that would have called for the death penalty for anyone using a ''plastic gun'' in the commission of a crime.

The legislation, sponsored by Rep. Bill Hughes, D-N.J., will ban the manufacture, sale or possession of undetectable plastic firearms.

Law enforcement agencies and gun control groups have been lobbying intensely for standards that would prevent terrorists from concealing plastic guns and slipping them past detectors.

No plastic gun has been manufactured, but a Florida company has a patent on one that it has said it will manufacture for law enforcement agencies in about two years.

Hughes, chairman of the Judiciary crime subcommittee, said the legislation will not affect existing firearms but takes aim at a new generation of plastic firearms which experts believe will be developed and perfected in the near future.

''This legislation is a fair and reasonable attempt to head off a serious law enforcement problem before it happens,'' Hughes said. ''It's apparent that plastic guns would become the weapons of choice for terrorists and other criminals if they became available.''

Under the bill, guns must contain at least 3.7 ounces of electronically detectable metal to make sure they can be picked up by magnetometer devices. It also requires that firearm components generate accurate X-ray images to assist in their detection.

The bill makes it a federal offense to knowingly manufacture, import, sell, transfer or possess a plastic firearm. It sets fines of up to $250,000 for individuals and $1 million for organizations, and up to five years in prison.

The legislation is similar to the gun control bill agreed to by the Justice Department, law enforcement groups and the National Rifle Association, which has opposed any changes in the law. That measure is expected to see quick passage in the Senate.

NRA representative Mary Kaaren Jolly applauded the House Judiciary action.

''We think it is the best piece of legislation introduced to date in either the House or Senate,'' she said.