Moduli and gauge theory on complex curves