info for you
A trigger job can combine polishing of the engagement surfaces as well as lightening of the mainspring weight. For weight to be removed from the trigger, you have to remove friction as well as spring weight.
Now with all that said, sometime you have to adjust screws as on a Remington type rifle trigger and sometimes you have to polish the sear and hammer engagement surfaces as on most revolvers and pistols. I also lob off the back of the sear to lessen the amount the sear has to move before the hammer falls on most of the revolvers and pistols that I work on.
It can be done by the average guy if he fully understands what he is doing. One thing that you can do is polish up the surfaces of the hammer and sear and make them have less drag or friction. You can do this without actually shortening their engagement. Make sure that you keep the flats flat and not round over any edges.
I would let a smith do your trigger work if any of this makes you scratch your head and wonder. Some pistols are striker fired which will change up all that you might know about pistols that are hammer fired. I believe the XD40 you have will fall under this catagory. It is usually best to leave it as it comes and use a trigger pull that only lets the trigger go forward enough to recock the gun. This will make for a lighter pull and keep the gun firing much quicker and easier. Good luck with it.