Co-doping of phosphorus and boron elements into crystalline silicon quantum dot (c-Si QD) is an effective approach for enhancing the photoluminescence (PL) performance. In this paper, we report on the preparation of hydrogenated silicon nitride (SiNx:H) thin films embedded with phosphorus-boron co-doped c-Si QDs via plasma enhanced chemical vapor deposition (PECVD) route. Mixed dilution including hydrogen (H2) and argon (Ar) is applied in the in-situ deposition process for optimizing the deposition process. The P-B co-doped c-Si QD/SiNx:H thin films exhibit a wide range of PL spectra. The emission is greatly improved especially for the short-wavelength light when compared to the SiOx:H thin film containing P-B co-doped c-Si QDs. The effects of H2/Ar flow ratio on the structural and optical characteristics of thin films are systematically investigated through a series of characterizations. Experimental results show that various properties, such as crystallinity, QD size, optical band gap and doping concentrations, are effectively controlled by tuning H2/Ar flow ratio. Based on the red-shift of QCE-related PL peak, the successful P-B co-doping into Si QDs are verified. Finally, a comprehensive discussion has been made to analyze the influence of H2-Ar mixed dilution on the film growth and impurity doping in detail in this paper.