If I recall correctly, purple Lock-tite is used by race engine builders to keep studs from coming loose without the application of fairly extreme heat. In other words they don't want them ever coming loose. I think the purple would be a poor choice on a firearm.
There have been several good suggestions, but I will mention an additional use. Some screws, especially small ones such as on certain triggers, have a habit of not staying put, but are not really subjected to a lot of stress. You can either use some fingernail polish, because it is easy to break loose when you need to readjust it or take the screw(s) out and "paint" them with blue lock-tite, allow it to air dry and then repeating the process several times. This should build up enough of a coating that the fit of the loose screw will be tighter when reinstalled even though it is not actually glued in place.