These questions have so many variables and there is not a one-size-fits-all answer. What I can tell you, from my perspective, is that it is never proper to forgo the tip, and here's why: The tip is a contract that is socially bound (regardless of the service). Although some might have you believe that it is an added extra for perfect, above and beyond service - it is not. It is the price you should always factor before deciding on what to get from the menu, and before even going out to eat. Think of it like the extra 9's at the gas pump (i.e. $2.79-99 per gallon), we all know those extra nines add a penny but they are there, aren't they - so is the tip!
The bare minimum for a tip for awful service should still be at least 10% of the entire bill (before or after tax - you decide). "I aint payin' no tip to bad service", you might be thinking to yourself (while sitting in your double-wide) - and that is fine - don't - but also don't go out to eat unless you're positive the service will be stellar because a tip should be paid at a MINIMUM of 10%. In case your wondering - I am not, nor have I ever been, a server.
This leads me to let you know what to do if you have bad service - tell a manager! If you leave and you had a bad experience not tipping just makes you look like a total a-hole and contrary to what you think that doesn't let anyone in charge know that you are not satisfied. When you do not leave a tip for bad service it also effects the others who may have served you quite well - the host, bartender, and busboy - because the tips are "pooled" together.
You know what else telling a manager will accomplish? They can "comp" you for what is certainly more than the 10% tip you might leave off - much more - and they want you to be happy so you'll come back. Great restaurants (and great managers) know that solving your problem now will save the experience and they want you to be happy.So, again - always tip at least 10% (if the service is bad) and let the numbers go up at your own pace from this point the better the service gets.
Do not listen to those who say the tip means: "To Insure Prompt Service" because it doesn't. In fact, by definition, insure something means to pay for something in advance to resolve a problem later - which is not how "tipping" works, as we all know. This little gem may have been concocted by someone who didn't realize they meant "ensure" - which means something that happens as a result (of something else).
In any case - always tip your server, even if it was not all that you had hoped for - it is a part of the whole experience and until the "rules" change and everything is one flat fee - you need to always include this very important part.