I have been thinking about this lately.
When you are going to curse and you say : “Excuse my French” prior to cursing, that means you can actually STOP yourself from cursing.
But if it slips your mouth and you curse first, then it makes more sense to excuse yourself afterwards. I suggest you don’t say “excuse my French ” and then curse . Because if you can pause to excuse yourself, you might as well take the opportunity to change how you choose your words.
Here is an idea: If you are going to excuse yourself first, just don’t curse at all.