Observation of pairs of charmed particles produced by high-energy photons in nuclear emulsions coupled with a magnetic spectrometer