We analyse a model free-energy functional of two spatially varying densities. We determine the interfacial density profiles and tensions in terms of a parameter in the functional and we locate a first-order wetting transition at a particular value of that parameter. For those states in which there is a three-phase contact line we calculate the line tension. As one of the contact angles decreases from 120° to 0° at the wetting transition the line tension increases from negative to positive values and perhaps diverges to + ∞ as the wetting transition is approached. The origin of this difference in behaviour of the line tension from that in earlier models is discussed.