The terminology can be confusing sometimes, indeed. The spectrum of a typical star is continuous, determined by the effective temperature of the photosphere of the star. However, there are absorption spectral lines superimposed on this continuum, because photons of some specific wavelengths are being absorbed as trying to escape through the stellar atmosphere. The absorption spectrum is determined by the composition of the atmosphere and by the level of ionization.