We present an x-ray diffuse scattering study of the charge-density wave (CDW) structure in the doped blue bronzes ${\mathrm{K}}_{0.3}({\mathrm{Mo}}_{1\ensuremath{-}x}{\mathrm{V}}_{x}){\mathrm{O}}_{3}$ $(x=2.8%)$, ${\mathrm{Rb}}_{0.3}({\mathrm{Mo}}_{1\ensuremath{-}x}{\mathrm{V}}_{x}){\mathrm{O}}_{3}$ ($x=1.44%$ and 0.28%), and ${\mathrm{K}}_{0.3}({\mathrm{Mo}}_{1\ensuremath{-}x}{\mathrm{W}}_{x}){\mathrm{O}}_{3}$ $(x=2%)$. At low temperature, the $\ifmmode\pm\else\textpm\fi{}2{k}_{F}$ satellite reflections are broadened in all four compounds, and shifted in V-doped compounds. Moreover, we have observed an intensity asymmetry of the $\ifmmode\pm\else\textpm\fi{}2{k}_{F}$ satellite reflections relative to the pure compound, and a profile asymmetry of each satellite reflections. We show that both effects, intensity and profile asymmetry, give access to the local properties of CDW in disordered systems, including the pinning and the phase shifts around impurities. This leads us to propose a complete scenario of the pinning in doped blue bronzes. In the V-doped compounds, we show that the profile asymmetry is due to Friedel oscillations around the charged V substituent and that the intensity asymmetry is related to the strong pinning of the CDW. In the W-doped crystal, the CDW is weakly pinned in regions containing a few tens of neutral W substituents and the CDW phase is slightly distorted around the W impurities. Exact calculations are presented to sustain these ideas.