Fix T48198: Missing plus sign to open the tool shelf in text editor

Did not happen when using screen layout saved in default startup.blend
This commit is contained in:
Julian Eisel 2016-04-19 21:01:55 +02:00
parent 37493fb9fe
commit dd423a6818
Notes: blender-bot 2023-02-14 07:58:24 +01:00
Referenced by issue #48198, Switching to Text editor, missing plus sign to open the tool shelf
1 changed files with 9 additions and 1 deletions

View File

@ -79,7 +79,15 @@ static SpaceLink *text_new(const bContext *UNUSED(C))
BLI_addtail(&stext->regionbase, ar);
ar->regiontype = RGN_TYPE_HEADER;
ar->alignment = RGN_ALIGN_BOTTOM;
/* properties region */
ar = MEM_callocN(sizeof(ARegion), "properties region for text");
BLI_addtail(&stext->regionbase, ar);
ar->regiontype = RGN_TYPE_UI;
ar->alignment = RGN_ALIGN_LEFT;
ar->flag = RGN_FLAG_HIDDEN;
/* main region */
ar = MEM_callocN(sizeof(ARegion), "main region for text");