GN4 uses global overridable variables for all defaults that have to be customized on-site. For the reference, see Global Overridable Variables.
An example: the GN4 default for kicker frame height (when adding it on Fred4) is 30000 mpt, but in your GN4 system you need it to be 24000 mpt. Or, the default name of the body element is "body", while in your Italian GN4 system you want it to be "testo". Or you want some script not to prompt you for the choice, but to predefine the choice.
In version 1.5 and in 1.4.1587.x or newer, we introduced the concept of typography-dependent global overridable variables (see Typography-dependent overridable variables for further details).
To make the changes available to GN4 client workstations after modifying EditorialConfig, make all users to log out and log back on to GN4 client software. IIS reset is not needed.
GN4 system global overridable variables are defined in various places: 1.For the system add-ins, as VB.Net properties in EdConfig class in Ted.vb, This defines the property itself and it's default value, but not the override. 2.For the custom add-ins, as VB.Net properties in CustomEdConfig class in CustomTed.vb, This defines the property itself and it's default value, but not the override. 3.As values defined under <Dict> node in the EditorialConfig. This defines the site-dependent override. To access the EditorialConfig, run EdAdmin4, click Client applications under Application Configuration, locate EditorialConfig and double-click it. The properties are available in all classes of Ted4 and Fred4. While in PageDesignerAddIn class of Page.vb and in TxtDesignerBase of Article.vb you can call global overridable variables also without the EdConfig. prefix, it is recommended to use the prefix for better readability. In other add-ins you must specify the EdConfig. prefix before the variable name, e.g. EdConfig.bodyname. |
There is one readonly property for each overridable variable. Should you need to add new variables, you must add a new properties definition for each variable in EdConfig class in Ted.vb, and then add a new value (as string) for each variable in the EditorialConfig. For each property you specify the type with As clause: String, Integer, Boolean etc. This type defines how the value, specified in EditorialConfig in <Dict> node as string, gets converted in the appropriate type. The property syntax is fairly simple and based on the GetDef custom function. Below is an example of the bodyname property.
|
To use a global overridable variable in an add-in, simply call it with its name, as shown below in the example for the bodyname variable. Dim typname As String = EdConfig.bodyname Note: in PageDesignerAddIn class of Page.vb and TxtDesignerBase of Article.vb (that inherit EdConfig) you can call global overridable variables also without the EdConfig. prefix. In other add-ins you must add the prefix. |
<Item Name="bodyname" Value="testo" /> Every value goes in its own line. See below the "Properties values in Dict node of EditorialConfig" paragraph for some examples. Specify all values as strings, no matter their type. The conversion to the appropriate type is performed by the As clause in the property script. Enclose numbers in double quotes, e.g. "30000" |
Every value goes in its own line. See below the "Properties values in Dict node of EditorialConfig" paragraph for some examples For Boolean values, use "0" for False, and "-1" for True, or use "false" and "true" words. |
For the reference, see Global Overridable Variables.