San Francisco police have arrested a man in the killing of a woman in her Russian Hill apartment last week.

Gary Scott Holland, 43, of San Francisco was charged Friday evening with homicide in the death of Kathleen "Kate" Horan, 46, who police say was robbed and fatally bludgeoned around 7 p.m. on Oct. 29. The man posed as a utility worker searching for a gas leak to gain entry to the apartment, authorities said.

Holland was taken into custody just after 10 a.m. Friday after a passer-by and three officers saw him lying near a sidewalk at Sutro Heights Park in the outer Richmond District.

"We happened by and went to check on his well-being first," said Capt. Richard Corriea. "Quite honestly, from a distance it seemed like someone who could use our help." Police had earlier said the suspect might have a moderate to severe injury on his left hand.

Corriea and two other officers detained Holland after finding out he was on parole for a previous conviction of attempted murder in Fresno County.

"We were able to put the pieces of interest together," said Assistant Chief Jeff Godown, adding that Holland had spent 11 years in prison and was released in April.

Horan was slain in her second-floor apartment at 900 Chestnut St., and the man suspected in the slaying was seen outside the building about 45 minutes earlier, apparently trying to get in.

Her body was found early the next morning when someone concerned about her safety contacted police. Authorities have not said what caused her death, but sources with knowledge said Horan was bludgeoned.

"He posed himself as a utility worker. He got into the building. That's how this all started," Cmdr. David Lazar of the investigations bureau said earlier Friday. "The suspect knocked on several doors under the guise of checking for a gas leak."

The man wore a black tool belt and was carrying a yellow-and-gray toolbox. Police released images showing the style of clothing he wore and items he was carrying.

Holland was seen about 6:15 p.m. on Oct. 29 outside the building at Chestnut and Leavenworth streets, Lazar said.

Police recovered all or most of the valuables near or at the building that were apparently taken from Horan's apartment, Lazar said.

Horan worked as a publicist in the fashion world and had just returned from a trip to Argentina with her mother.

Investigators would not elaborate on whether he had a connection with Horan, Godown said.