Start:
PUBLIC
PROC = {
changeSet: EditNotify.ChangeSet;
PointsPerInch: REAL = 1.0/0.0138370;
register the notify proc that updates the style caches when edits occur
changeSet[ChangingProp] ← TRUE;
changeSet[ChangingFormat] ← TRUE;
changeSet[MovingNodes] ← TRUE;
changeSet[NodeNesting] ← TRUE;
changeSet[InsertingNode] ← TRUE;
EditNotify.AddNotifyProc[Notify, after, high, changeSet];
initialize all the style caches
InitApplyCacheRecord[];
InitRuleCacheInfo[];
InitLooksCacheInfo[];
InitObjectCacheInfo[];
ClearCaches[TRUE];
establish the default styles wired into Tioga
defaultStyle ← Create[];
defaultFormatName ← NameSymbolTable.MakeName["default"];
rootFormatName ← NameSymbolTable.MakeName["root"];
provide some basic style attribute values in case no style gets loaded successfully
SetDefaultStyle["Cedar"]; -- wired in default
defaultStyle.name[fontFamily] ← NameSymbolTable.MakeName["Helvetica"];
SetReal[defaultStyle, fontSize, 10];
SetReal[defaultStyle, leading, 12];
SetReal[defaultStyle, tabStops, 4];
SetReal[defaultStyle, pageWidth, 8.5*PointsPerInch];
SetReal[defaultStyle, pageLength, 11*PointsPerInch];
SetReal[defaultStyle, leftMargin, 1*PointsPerInch];
SetReal[defaultStyle, rightMargin, 1*PointsPerInch];
SetReal[defaultStyle, topMargin, 1*PointsPerInch];
SetReal[defaultStyle, bottomMargin, 1*PointsPerInch];
SetReal[defaultStyle, lineLength, 6.5*PointsPerInch];
expect to find Cedar.style when Tioga is loaded
[] ← LoadStyle[defaultStyleName];
register the special handling procedures for the local style property: StyleDef
NodeProps.Register[name: $StyleDef,
reader: ReadSpecsProc, writer: WriteSpecsProc, copier: CopyInfoProc];
};