Well yeah. If the want to scream about fags at a funeral and they get stomped on thats their fault. Although I wouldn't agree with any violence towards any party.
But if their hate speech is such that it will most likely incite violence, then it isn't protected speech.
Under the imminent lawless action test, speech is not protected by the First Amendment if it is likely to cause violation of the law more quickly than an officer of the law reasonably can be summoned.
So if the hate speech is so egregious as to incite violence (as in doing it beside the grave) then it is the duty of law enforcement to remove these people... they forfeited their freedom of speech at that time and place