
765 So.2d 258 (2000)
James A. LEGGETT, Appellant,
v.
Michael W. MOORE, Secretary, Florida Department of Corrections, Appellee.
No. 1D99-2618.
District Court of Appeal of Florida, First District.
August 14, 2000.
*259 John C. Schaible of Florida Institutional Legal Services, Inc., Gainesville, for Appellant.
Sheron L. Wells, Assistant General Counsel, Tallahassee, for Appellee.
PER CURIAM.
Appellant seeks review of the denial of his petition for writ of mandamus. We affirm.
Appellant was incarcerated for an offense he committed on November 7, 1984. The early release law in effect on the date of his offense was section 944.598, Florida Statutes (1983). Pursuant to superseding enactments, appellant was granted 420 days of administrative gain-time pursuant to section 944.276 and 1860 days of provisional credits pursuant to section 944.277. In April or May 1998, appellant's credits were canceled. Appellant's petition for writ of mandamus seeking restoration of the credits was denied.
We reject appellant's argument that the standard of overcrowding applicable to his sentence after July 1, 1985 is "design capacity" based on the settlement agreement and February 1980 order entered in Costello v. Wainwright, 489 F.Supp. 1100 (M.D. Florida 1980). On the date of his offense, section 944.598 provided for grants of emergency gain-time at 98% of lawful capacity. "Lawful capacity" was defined to mean "the total capacity of all institutions and facilities in the prison system as determined either by the Legislature or by the courts." As noted in Gomez v. Singletary, 733 So.2d 499, 507 (Fla. 1998):
In 1983, however, the legislature had not actually determined an exact definition [of lawful capacity], nor had any court done so. As discussed above, in the early 1980s, the Department was embroiled in the Costello prison overcrowding lawsuit. According to the Costello settlement agreement, effective July 1, 1985, the definition of "lawful capacity" was determined to be 133% of total design capacity.
(Emphasis in original). We agree with the Department that from the effective date of section 944.598 until July 1, 1985, "lawful capacity" was maximum capacity. Appellant's ex post facto rights arise under section 944.598, not under the Costello agreement. Appellant could have no legitimate expectations with regard to future standards referenced in the Costello agreement. The statute established his ex post facto rights and the statute put him on notice that the definition of lawful capacity could be redefined.
Appellant's remaining arguments are without merit. The trial judge correctly determined that appellant would only be entitled to relief if the prison population exceeded the relevant threshold of 98% of maximum capacity during the time periods at issue. See Gomez v. Singletary, 733 So.2d 499 (Fla.1998); Sanford v. State, 739 So.2d 1208 (Fla. 3d DCA 1999); Grant v. Singletary, 730 So.2d 805 (Fla. 2d DCA 1999). Accordingly, the order on appeal is AFFIRMED.
BARFIELD, C.J., MINER and PADOVANO, JJ., CONCUR.
