Installing custom interface settings, Installing custom icons, Preference file load order – Apple Shake 4 User Manual

Page 358

Advertising
background image

358

Chapter 14

Customizing Shake

Installing Custom Interface Settings

Settings that change the interface in some way (including macro interface files) are
usually located in:

<somewhere>/include/startup/ui

These also have a .h file extension, for example:

/Users/my_account/nreal/include/startup/ui/slider_settings.h

This is referred to as the ui directory or sometimes startup/ui directory. Files inside it are
referred to as ui .h files.

Files that change additional default settings or add extra controls are in the templates
directory, which is always within a ui directory:

/Users/me/nreal/include/startup/ui/templates/defaultfilter.h

Installing Custom Icons

Just as you can create preference files, you can create your own icons. The description
of the actual icons can be found in “

Using the Alternative Icons

” on page 375. Icons can

be found in one of three locations:

<ShakeDir>/Contents/Resources/icons (<ShakeDir>/icons on non MacOS): a directory,
not to be confused with the important icons.pak file)

$HOME/nreal/icons

In any directory pointed to by $NR_ICON_PATH, set the same way
$NR_INCLUDE_PATH is set

Preference File Load Order

Within a startup or startup/ui directory, files are loaded in no specific order. If it is
important that a file is loaded before another file, this can be accomplished in a variety
of ways.

To explicitly control preference file load order, do one of the following:

m

Add an include statement at the beginning of the file. For example, if macros.h relies on
common.h being loaded before, start macros.h with:

#include <common.h>

m

Put all the files you want to load in a directory (for example include/myprefs) and create
a .h file in startup that contains only include statements:

#include <myprefs/loadmefirst.h>

#include <myprefs/nowloadthis.h>

#include <myprefs/andthistoo.h>

Include files are never loaded twice, so it is okay if two .h files contain the same
#include <somefile.h> statement.

Advertising