Skip to content

Auto layouts: clean up orphaned legacy text overrides after Text Designer migration#139

Open
Krathe82 wants to merge 1 commit into
DanderBot:mainfrom
Krathe82:pr/legacy-text-override-cleanup
Open

Auto layouts: clean up orphaned legacy text overrides after Text Designer migration#139
Krathe82 wants to merge 1 commit into
DanderBot:mainfrom
Krathe82:pr/legacy-text-override-cleanup

Conversation

@Krathe82

@Krathe82 Krathe82 commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Problem

The Text Designer migration took over the built-in Name / Health / Status text. A raid auto-layout that was edited before that migration can still carry those legacy text settings (nameFontSize, healthFontSize, statusText*, …) as per-layout overrides. They're now inert — IsLegacyTextHidden hides the legacy FontStrings — so they only clutter the override list (/df overrides, the override-details panel) without doing anything.

Fix

DF:CleanupLegacyTextLayoutOverrides strips override keys categorised as Name / Health / Status Text from every raid auto-layout, reusing the existing GetOverrideTabId so the Text Designer entry itself is preserved.

Gated for safety: it only runs once the raid Text Designer has actually migrated the legacy settings (migratedFromLegacy), so the values are preserved in Text Designer first and it never strips while the legacy text is still live. Per-profile guard, idempotent; called right after the legacy migration at login and on profile switch. Stripping is visually inert — Text Designer ignores these keys — so it only declutters.

A raid auto-layout edited before the Text Designer migration could keep the
built-in Name/Health/Status text settings (nameFontSize, healthFontSize,
statusText*, …) as overrides. TD now owns that text (the legacy FontStrings are
hidden), so those overrides are inert — they only clutter the override list
beside the layout's textDesignerPreset.

DF:CleanupLegacyTextLayoutOverrides (AutoProfiles.lua) strips override keys
categorised as Name/Health/Status Text from every raid auto-layout, reusing
GetOverrideTabId so the textDesigner(Preset) entry is preserved. Gated on the
raid TD's migratedFromLegacy so it NEVER runs until the legacy values are safely
in Text Designer; per-profile guard, idempotent. Called right after
MigrateTextDesignerFromLegacy at login (Core.lua) and on profile switch
(Profile.lua). Stripping is visually inert — TD ignores these keys.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant