See Styles for more information.
See also Preferences for information about the 'GRacket:default-font-size preference.
The base-style argument must be a style within this style list.
(send a-style-list find-or-create-style base-style delta) → (is-a?/c style<%>) base-style : (is-a?/c style<%>) delta : (is-a?/c style-delta%)
The base-style argument must be a style within this style list. If base-style is not a join style, if it has no name, and if its delta can be collapsed with delta (see collapse in style-delta%), then the collapsed delta is used in place of delta, and the base style of base-style is used in place of base-style; this collapsing and substitution of base styles is performed recursively.
The key argument is the value returned by notify-on-change.
→ (or/c (is-a?/c style<%>) #f) i : exact-nonnegative-integer?
If name is already being used, then like-style is ignored and the old style associated to the name is returned. Otherwise, a new style is created for name with the same characteristics (i.e., the same base style and same style delta or shift style) as like-style.
The like-style style must be in this style list, otherwise the named style is derived from the basic style with an empty style delta.
Often, a change in one style will trigger a change in several other derived styles; to allow clients to handle all the changes in a batch, #f is passed to f as the changing style after a set of styles has been processed.
The callback f replaces any callback for which it is equal?, which helps avoid redundant notifications in case of redundant registrations. The callback f is retained only weakly (in the sense of make-weak-box), but it is retained as long as any value that f impersonates is reachable; for example, if f represents a function with a contract applied, then f is retained for notification as long as the original (pre-contract) function is reachable. The callback f is also retained as long as the opaque key produced by notify-on-change is reachable.
→ (or/c exact-nonnegative-integer? #f) style : (is-a?/c style<%>)