Ising models on the plane square lattice with an arbitrary variation o
f the bond strengths, J(parallel-to)(z) and J(perpendicular-to)(z), wi
th one of the two axial coordinates, z, are considered. The total entr
opy is exactly represented as a functional of contributions epsilon(q)
(z) to the local energy density arising from the Onsager fermions with
wave vector q parallel to the layer axis, y. The resulting explicit l
ocal expression provides an effective, variational principle for the f
ree energy and energy-density profiles. In the scaling limit the probl
em reduces to a set of independent second-order differential equations
for each epsilon(q)(z). The power of the method is demonstrated by ap
plication to an interface between two uniform but distinct regions; th
is includes the problem of a wall with a surface field, h1, as a speci
al case. Previous results for the bulk and surface exponents and for t
he energy-energy correlation function are easily recovered. Near criti
cality the method yields, in addition, universal, scaled energy-densit
y profiles, epsilon(z;T), which exhibit rich crossovers and nonmonoton
ic variation with z.