Convergence of a discretization of the Maxwell–Klein–Gordon equation based on finite element methods and lattice gauge theory