Paint is a good thing, but you can have too much of it. And the paint store will not take back extra gallons of that lovely orchid tint you selected. For a rough estimate of how much paint you'll need, measure the room's perimeter (in feet) and multiply that number by the wall height in feet. From this result, subtract 20 square feet for each door and 14 square feet for each window. Divide that number by the spreading rate listed on the paint can. That's the number of gallons you'll need.
There's an Einsteinian formula for calculating how much trim paint you'll need, but most painters just figure it will be one-fourth what is needed for the walls. The main thing to remember: If it's more than two quarts, get a gallon; it's always cheaper.