4
$\begingroup$

In Blender 2.80, you have options now to set a file template with it's own set of workspaces. Is there a way to rename, or better yet create a new file template?

NewFileWindow

$\endgroup$
7
$\begingroup$

You can add your own App Template by using the Operator Search F3 to find Install Template from File.... The underlying operator PREFERENCES_OT_app_template_install allows you to install a zipped App Template.

If you don't have a zip file you can copy and modify one of the existing templates. You can find the location of the template files by switching to the scripting workspace and typing the following code into the python console:

for x in bpy.utils.app_template_paths():
     print(x)

This will print the path(s) where the build in application templates are stored.

Each template consists of a folder containing a startup.blend and a init.py. The former is the default project that is loaded. The latter is a Python script that contains a callback function / handler that is executed once the startup.blend is loaded. This allows to perform additional configurations. The folder name is the name of the template. Below you see the basic structure of such an init.py.

import bpy
from bpy.app.handlers import persistent

@persistent
def load_handler(dummy):
    pass


def register():
    bpy.app.handlers.load_factory_startup_post.append(load_handler)


def unregister():
    bpy.app.handlers.load_factory_startup_post.remove(load_handler)

The load_handler() is the function that will be registered once you select the app template in Blender and then executed once the project is loaded. When you create your template you can add whatever additional Python code you like here. If you copy an existing template to create your own, you may want to edit this function or replace it's content with pass to make it do nothing.

Now in order to create your own template you need to do three things:

  1. Either copy an existing template or create your own directory with a startup.blend and init.py
  2. Open the startup.blend and adjust the UI to your liking
  3. Open the init.py and modify the load_handler. (If you're unfamiliar with software development simply copy and past the example given above, which does nothing.)

Your new template should be available right away when you restart Blender, if you've created the files in the directory where the other templates are stored. Otherwise you will either have to copy it there or create a zip file of the directory and install it by using Install Template from File... as described at the beginning.

| improve this answer | |
$\endgroup$
4
$\begingroup$

They are located in Blender's installation folder: C:\Program Files\Blender Foundation\Blender\2.80\scripts\startup\bl_app_templates_system\ on Windows

You can see a few folders:

enter image description here

You can delete them or copy one of them, give it another name and save an empty startup.blend file with whatever UI you like.

| improve this answer | |
$\endgroup$
  • $\begingroup$ Thank you! For others wondering, on a mac right click on blender, show package contents, 2.80, scripts, startup, bl_app_templates_system. $\endgroup$ – Corbomite Sep 13 '19 at 20:48
3
$\begingroup$

Here is another way for OSX:

  1. Go to Blender.app > Contents > Resources > 2.80 > scripts > startups > bl_app_templates_system (here you can find all startup files)
  2. Duplicate the one that closely resembled the look you needed, and duplicate that folder
  3. Go inside that folder, open up the blend file inside and changed it to whatever you need
  4. Compresses that folder to a .zip file
  5. Back in Blender, hit F3 and type Install Template from File...
  6. Select the .zip file created and re-start Blender
| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.