New Approach on Quantification of Porosity of Thin Films via Electron-Excited X-ray Spectra