We compute the spectral function A͑k , ͒ of a model two-dimensional high-temperature superconductor at both zero and finite temperatures T. The model consists of a two-dimensional BCS Hamiltonian with d-wave symmetry, which has a spatially varying, thermally fluctuating, complex gap ⌬. Thermal fluctuations are governed by a Ginzburg-Landau free energy functional. We assume that an areal fraction c  of the superconductor has a large ⌬ ͑ regions͒, while the rest has a smaller ⌬ ͑␣ regions͒, both of which are randomly distributed in space. We find that A͑k , ͒ is most strongly affected by inhomogeneity near the point k = ͑ ,0͒ ͑and the symmetry-related points͒. For c  Ӎ 0.5, A͑k , ͒ exhibits two double peaks ͑at positive and negative energies͒ near this k point if the difference between ⌬ ␣ and ⌬  is sufficiently large in comparison to the hopping integral; otherwise, it has only two broadened single peaks. The strength of the inhomogeneity required to produce a split spectral function peak suggests that inhomogeneity is unlikely to be the cause of a second branch in the dispersion relation, such as has been reported in underdoped LSCO. Thermal fluctuations also affect A͑k , ͒ most strongly near k = ͑ ,0͒. Typically, peaks that are sharp at T = 0 become reduced in height, broadened, and shifted toward lower energies with increasing T; the spectral weight near k = ͑ ,0͒ becomes substantial at zero energy for T greater than the phase-ordering temperature.