The supreme court has, however, held that federal courts can enjoin states from violating federal law, and copyright infringement is a federal offense under Title 17 of the US Legal Code.
It's all much more mundane and technical than this.
The reason that this suit originated in Texas state court is because their legal argument was based on Takings jurisprudence. It's complicated, but IIRC SCOTUS has effectively required that Takings claims against states originate in state court. They do this by way of the so-called ripeness doctrine. A federal court will invariably reject a Takings claim unless you can show that you pursued and failed to achieve a remedy through state administrative and legal processes, and as a practical matter this means pursuing a claim up to the state's supreme court.
Ripeness is not directly based on statute or the constitution. If we're being cynical, it's based on SCOTUS disliking Takings cases, particularly so-called regulatory takings (which arguably describes this case), because they involve difficult, highly contextual line drawing that don't lend themselves to clear-cut legal doctrines. So they basically punt. If we're being kind, they do this because forcing claimants to exhaust all state-based remedies provides a ton of factual evidence and legal arguments that benefits adjudicating such cases at the federal level.
If the claimant here made a simple copyright infringement claim they would have been able to go directly to federal court, and in fact it's rare not to do this. Actually, I think federal courts have exclusive jurisdiction over copyright infringement claims; the scope of 1976 Copyright Act leaves very little room, if any, for copyrights under state law. Except for pre-1976 productions anything copyright-related is basically controlled by federal copyright and therefore you're required to go to federal court.
Again, they had a novel legal argument, perhaps in an attempt to subvert federal jurisdiction, and more specifically to get around whatever Fair Use defenses the university could have made. That's just conjecture, though. I haven't read the case.
EDIT: You're not required to go to federal court for copyright claims simply because the claim is a federal issue. It's because federal statute explicitly gives federal courts exclusive jurisdiction over federal copyright claims.
After reading more recent caselaw I think, in practical terms, the reason they attempted a Takings claim is because they wanted monetary damages, whereas because of the peculiar contours of sovereign immunity jurisprudence the remedy for an infringement claim would have at best been an injunction. And apparently more recent sovereign immunity caselaw has cast doubt in some circles on the ability to even get an injunction. I'd personally be surprised it that notion was ratified by SCOTUS, but clearly I haven't been keeping up so my opinion isn't worth much.