AROS icon indicating copy to clipboard operation
AROS copied to clipboard

OpenScreenTags

Open rolsen74 opened this issue 8 months ago • 0 comments

Summary:

When calling OpenScreenTags() with SA_LikeWorkbench, TRUE, any manually specified SA_Font is silently overridden on AROS, whereas on AmigaOS 3.2 the font is respected. This causes unexpected font behavior when attempting to set custom screen fonts on AROS.

scr = OpenScreenTags(NULL, SA_LikeWorkbench, TRUE, // SA_SysFont, -1, // Trick to make AROS use my Font SA_Font, &TOPAZ80, // This is ignored on AROS TAG_END);

On AROS, the font is overwritten, apparently due to logic in intuition/openscreen.c where sysfont is hardcoded when SA_LikeWorkbench is TRUE:

if (GetTagData(SA_LikeWorkbench, FALSE, tagList)) { [CUT .. more code here] sysfont = 1; sharepens = TRUE; /* not sure */ }

Proposed Fix:

Modify the logic to only set sysfont = 1 if the user has not specified SA_Font:

if (GetTagData(SA_LikeWorkbench, FALSE, tagList)) { [CUT .. more code here] if (!GetTagData(SA_Font, 0, tagList)) { sysfont = 1; } sharepens = TRUE; }

rolsen74 avatar May 11 '25 22:05 rolsen74