If you leave applications running without any open windows, Mac OS X will quit the application when it goes to the background. There is no setting in the system preferences to change this behavior. Use the following command to disable automatic application termination.
defaults write -g NSDisableAutomaticTermination -bool true
Restart your Mac or logout/in to make the changes appear, or restart apps on an app-by-app basis to activate the change.
defaults write -g NSDisableAutomaticTermination -bool false