We show that, in the x-ray magnetic resonant scattering (XRMS) of a two-dimensional array of submicron magnets, the collected intensity at each Bragg reflection is correlated to the reflected light from locations of the magnets that have the same angle of curvature. This converts XRMS in a kind of magnetic microscope capable of spatially resolving the magnetization of the small-size magnets, averaged over the magnets illuminated by the x rays. This result is used to study the magnetization of trilayer submicron disk-shaped magnets consisting of two magnetostatically coupled ferromagnetic layers, about 15 nm thick, separated by a nonmagnetic spacer. These kinds of systems are less known than the single-layer ones, despite having potentially more interesting functionalities for device applications, mainly due to the difficulty to distinguish the magnetization of each of the layers within the magnets. This problem is overcome by XRMS thanks to its chemical sensitivity and its relatively large depth probe. XRMS is also a photon-in photon-out technique that allows measuring under external magnetic fields. This permits the extraction of the local hysteresis loops at different locations of the disks. The technique demonstrates to be very sensitive to the magnetization distribution across each of the layers at any field intensity, with an estimated lateral resolution below 200 nm. This serves to detect, and also explain, chiral asymmetries in the magnetic circulation of the vortex in each of the layers.