Tuning the graphene band gap by thermodynamic control of molecular self-assembly on graphene