  We discuss the equilibrium condition for a liquid that partially wets a solid
on the level of intermolecular forces. Using a mean field continuum
description, we generalize the capillary pressure from variation of the free
energy and show at what length scale the equilibrium contact angle is selected.
After recovering Young's law for homogeneous substrates, it is shown how
hysteresis of the contact angle can be incorporated in a self-consistent
fashion. In all cases the liquid-vapor interface takes a nontrivial shape,
which is compared to models using a disjoining pressure.
