Details and Options
ResourceFunction["StyleInheritanceSummary"] includes additonal details explaining how the results are gathered along the stylesheet inheritance order.
ResourceFunction["StyleInheritanceSummary"] always opens a new window:
The provided information is organized into three separate interfaces:
"Stylesheet Inheritance Graph" shows the connectivity between the stylesheets in the inheritance:
The
DirectedGraph uses the stylesheet names as vertices. The
DirectedEdge points from the child stylesheet to the parent stylesheet that the child stylesheet inherits from.
A stylesheet can inherit from multiple parents. In that case the
Graph displays multiple edges with the top-most parent displayed to the left.
Only the stylesheet names are displayed. A
Tooltip provides the full path to the stylesheet file.
If the starting stylesheet is a private stylesheet then it is labeled as "Private".
If the starting stylesheet's name cannot be determind then it labeled generically as "Stylesheet".
The options are organized in alphabetical order by option name.
The button "Copy table data to clipboard" extracts the resolved options as they are currently displayed.
"Options Inheritance" is the default interface.
The top of the "Options Inheritance" interface provides controls to modify the information displayed in the summary table:
The steps of the inheritance algorithm are hidden by default to reduce the size of the table.
If showing the inheritance steps then the table is read from the bottom to the top:
There may be multiple
StyleData in the inheritance algorithm. The active
StyleData is highlighted in
GrayLevel[0.8] while the individual steps above it are highlighted in
GrayLevel[0.94].
Specific options can be suppressed to reduce the size of the summary table:
A specific scope can be suppressed.
To see a single option, first press the "All" button to hide all options, then press the specific option to display.
The "Clear" button returns the summary table to displaying all options.
The summary table area displays the gathered results:
The button "Copy table data to clipboard" extracts the summary table's data as it is currently displayed.
Any suppressed options and scopes are not copied to the clipboard.
The inheritance algorithm steps are never included in the copied data.
The summary table is organized into two columns, "Stylesheet and StyleData" on the left and "Options" on the right.
If including the inheritance algorithm steps then they span the table as a single column.
The options are in alphabetical order by option name.
A legend describes why some options are highlighted in the summary table:
Pink | The exact option value is duplicated. |
Orange | The option is the same except RuleDelayed is replaced by Rule. |
Yellow | The option value uses Association inheritance and cannot be fully resolved. |
Darker[Yellow] | The option value uses Association inheritance and is overridden by a List. |
Lighter[Blue, 0.7] | The option value is overridden. |
ResourceFunction["StyleInheritanceSummary"] takes the following options:
When resolving
StyleData["Style", "Env"] there are additional
StyleData that contribute to the full set of resolved options. Such contributions include
StyleData["Style"],
StyleData["Notebook"], and
StyleData[All, "Env"]. If
"Strict" → True then only the specified
StyleData is returned and any additional contributions are ignored.
The created interface does not include options coming from
Private stylesheets are automatically included at the start of the inheritance chain.
A child stylesheet can inherit from a parent stylesheet if the child contain cell expressions of the form
Cell[StyleData[StyleDefinitions → parent]] where
parent can be any stylesheet such as
"Default.nb" or
"Core.nb". When searching for
parent the
FrontEnd first searches the
NotebookDirectory[] of the child stylesheet before searching
StyleSheetPath. If
"SearchStyleSheetPathOnly" → True then only
StyleSheetPath is searched.