EditorDoc Sections Nuprl Doc
IF YOU CAN SEE THIS go to /sfa/Nuprl/Shared/Xindentation_hack_doc.html
Display Form Models.

In

Model: <model> Attrs: <attributes> | <Formats> _______________________

the model is a term which is a example of the operator to be displayed. The terms whose display is being specified by the display-form spec are the instances of the model gotten by filling in various parts of the model; so the model serves as a kind of schema. There are two kinds of such schematic "variables" pertinent to display, namely, display templates for terms, which look like <[template]>, and display-meta-variables for strings and binding variables belonging to the operator, which are indicated by putting angle brackets around the string (but these angle brackets are not actually part of the string-value itself).

For example, if we wanted to make a simple display form for the lambda operator [var].<*>, we could use display spec whose model was <x>.<t>.

A display-meta-variable for text in a operator or binding variable may occur more than once, in which case, for a term to match the model it must also have the same strings filling those positions.

If a display-meta-variable with the null text is used in a binding position of the model, then a term will match only if the binding variable matching that position doesn't really bind anything in the instance. This way we can give different methods of display that distinguish this failure to bind.

(More kinds of model matching are significant. Not documented here yet. See Paul Jackson's manual. doc for using pauls manual)

The `adj' command.
The model can usually be created automatically by using the `adj' command. This works when either the model position is empty and the DISP object name is a "_df" extension of a verified ABS object, or else the model position is filled by an obref to a verified ABS object.

Remember: you don't have to fill all the places of the model with meta variables; you may use ordinary strings in the text-slots, and ordinary terms in the term slots, to require an exact match in those places.

HERE for review of display model edit commands.

doc for display form edit

About:
lambda
IF YOU CAN SEE THIS go to /sfa/Nuprl/Shared/Xindentation_hack_doc.html

EditorDoc Sections Nuprl Doc