Blender_theme_as_c creates a not compiling userdef_default_theme.c

Hey friends,

I tried to alter the Blender theme, and get some bad results with using the blender_theme_as_c.py file and a fresh created userpref.blend. It creates a userdef_default_theme.c file which throws warnings at compiling that this and that term is no member of btheme or themespace, and so on. And Blender then simply does not compile.

It even adds a hardcoded path now to the used Blender theme, which is just useful at the system at which it compiles at.

Is it known that the script is broken? What can i do here?
Kind regards
Arunderan

I investigated a bit deeper, and at least i know now what the problem is. Just not how to fix it.

The script grabs currently the old names from the dna_rename_defs.h file. Not the renamed ones. This affects the bTheme names and also the ThemeSpace ones.

Possible cause could be the code cleanup from 22.07.2024. I have to check at which point this problem kicks in.

Bingo. Renaming DNA_STRUCT_RENAME_ELEM to DNA_STRUCT_RENAME_MEMBER fixes it. I would have loved to attach the fixed file here. But the forum doesn’t let me :frowning:

I made it a task.