XRD characterization of crystallinity and microstructure of pharmaceutical composites