  Magnetic field may distort neutron stars (NSs), but its effect has not been
robustly tested through gravitational-wave observation yet due to the absence
of a fast rotating Galactic magnetar. Part of gamma-ray bursts (GRBs) are
potential to investigate the magnetically-induced distortion since their
central objects may be millisecond magnetars. In this paper, we propose a
method to estimate the distortions of these possible magnetars under GRB
magnetar scenario. According to the case study of GRB 070521, we find a
relation between the effective magnetically-induced ellipticity, $\epsilon_{\rm
B,eff}$, and the effective dipole magnetic field strength on NS surfaces,
$B_{\rm eff}$, namely $\epsilon_{\rm B,eff}\sim 10^{-3}(B_{\rm eff}/10^{15}\rm
G)^{2}$. Furthermore, we constrain the internal magnetic-field structure of the
magnetar to be $B_{\rm eff}\sim 0.02 <B_{\rm t}>$ and $B_{\rm eff}\sim
0.1B_{\rm t}$, where $<B_{\rm t}>$ is the volume-averaged internal toroidal
field. The constraint may be used as the initial condition in modeling the
structure of NS magnetospheres. At last, the possibility of testing the method
shown in this paper through gravitational-wave observations is discussed.
