MONTGOMERY, Ala. (AP) _ Ku Klux Klansmen must attend a course on race relations taught by civil rights leaders as part of the settlement of a federal lawsuit stemming from a 1979 attack on black marchers in Decatur.

''Our goal has always been to try and change the hearts and minds of those whose racial beliefs lead to violence against us,'' the Rev. Joseph Lowery, president of the Southern Christian Leadership Conference, said in a statement released Monday by Montgomery-based Klanwatch.

The settlement, to be filed Tuesday in U.S. District Court in Huntsville, also requires Roger Handley, former grand dragon of the Knights of the Ku Klux Klan, and nine other Alabama Klansmen to pay $11,500 in damages to the marchers.

In addition, the settlement requires several defendants to perform community service and refrain from harassing blacks or joining any Klan or white supremacist group for periods of up to five years.

''Probably the most unique aspect of this case is that seven of the defendants have to attend a race relations course,'' said Pat Clark, director of Klanwatch. ''We must find a way to change attitudes and give people an opportunity to assess their wrongdoings ... and show them the error of their ways.''

She said details of the two-hour course, which probably will be taught in Birmingham next spring, have yet to be worked out.

''It is an historic moment when the president of the group founded by Dr. Martin Luther King Jr., an ardent practitioner of nonviolence, stands before the grand dragon of the Alabama Ku Klux Klan and expresses Dr. King's message of love,'' Lowery said in his statement.

Handley, whose addresses previously have been listed as Warrior and Gardendale in suburban Birmingham, was not available for comment. There was no telephone listing for him in either city.

The federal civil suit was filed in 1980 after investigators from Klanwatch, a monitoring group operated by the Southern Poverty Law Center, uncovered new evidence which eventually prompted the Justice Department to reopen its investigation of the May 26, 1979, incident.

A group of robed Klansmen clashed with black marchers in Decatur who were protesting the conviction the year before of a 19-year-old mentally retarded black man for raping three white women. Gunfire erupted during the incident, and two Klansmen and two blacks were wounded.

Ten Klan members, including Handley, the top Klansman in Alabama at the time of the incident, were indicted in 1984 on civil rights charges. All were either convicted or pleaded guilty. Earlier this year, Handley and six of his cohorts drew federal sentences ranging from a few months to two years for their roles in the violence.

Ms. Clark said the settlement of the civil lawsuit, which came after several months of negotiations, brought the 10-year-old case to a close. The suit was filed by Klanwatch on behalf of the Atlanta-based SCLC.