The updateProfile command can be used to update the current document view's profile.
updateProfile [ all ]
all | Use the optional parameter all to indicate that you want to update the profiles of all of the document views that are currently open. Note that if updateProfile has never been issued for a document view, issuing updateProfile all will not affect that document view. |
The status parameter is not affected by this command.
The updateProfile command is normally issued when a document view is created, but it may be issued at any time to allow the document view to reflect changes to the profile.
The following is the sequence of events that occur when the updateProfile command is issued against a document view:
- The readonly parameter is set to off.
- The includedClasses parameter is set such that all classes are included.
- The excludedClasses parameter is set such that no classes are excluded.
- Any registered classes are deregistered.
- The style characters set by the styleAttributes parameter are cleared.
- The popup parameter is reset to default.
- The expandTabs parameter is reset to default.
- The fields parameter is reset such that there are no editing fields.
- The tabs parameter is reset to default.
- The base profile is set to the value returned by current.updateProfile.baseProfile.
- If the base profile is ispf, seu, or xedit, then:
Otherwise:
- prefixArea is set to on
- prefixProtect is set to off
- if sequence numbers starting in column 1 are set in the document, then prefixAreaText is set to sequenceNumbers, and hideSequenceNumbers is set to on; otherwise, the hideSequenceNumbers parameter is reset to default.
- prefixArea is reset to default
- prefixProtect is set to on
- the hideSequenceNumbers parameter is reset to default
- any lines excluded by prefix commands in a previous base profile are shown.
- If the base profile is vi, then:
Otherwise:
- commandLine is set to off
- autoCheck is set to off.
- commandLine is reset to default
- autoCheck is set to on.
- All of the show elements for this view are deleted.
- The style parameter for the current view's view of all of the document's elements is reset.
- The elementClasses parameter for the current view's view of all of the document's elements is reset.
- The color palette is set to the value returned by current.updateProfile.palette.
- The built-in styles are assigned style attributes based on the values returned by current.updateProfile.paletteAttributes.style.palette, where style is substituted for each of the built-in styles and palette is the value returned by the palette parameter. Refer to the styleAttributes parameter for information on the built-in styles.
- All of the keys settings are cleared.
- All of the mouseEvents settings are cleared.
- All of the actions settings are cleared.
- New keys settings based on baseProfile are set.
- New mouseEvents settings based on baseProfile are set.
- New actions settings based on current.updateProfile.userActions are set.
- Additional keys settings based on current.updateProfile.userKeyActions are set.
- Additional mouseEvents settings base on current.updateProfile.userMouseActions are set.
- All of the commands settings are cleared.
- New commands settings based on current.updateProfile.userCommands are set.
- The user profile from current.updateProfile.userProfile is issued.
- If the current view has a parser, the resetParser method of the LpexParser interface is issued, and the parser is discarded.
- The parse pending list is cleared.
- If current.updateProfile.noParser is set to off, the new parser name is retrieved from current.updateProfile.parser.
- If the parser name is associated, the parser name is retrieved from the current.updateProfile.parserAssociation.extension parameter.
- The parser class is retrieved form current.updateProfile.parserClass.parserName.
- An instance of the parser is created.
- The totalParse method of the LpexParser interface is issued.
- If the document has a name, the readonly attribute of the file is queried. If the file is readonly, the readonly parameter for this document view is set to on.
- If there are any LpexViewListener objects listening to this view, the updateProfile method is issued.
The updateProfile command must be issued after any change to one or more of the updateProfile.parameter parameters in order to have the change reflected in any of the active document views.
Note that if you are constructing your own LpexView object and you customize it by adding actions, commands, key settings or mouse event settings, the updateProfile command will eliminate these settings unless you perform customizations of this sort within the updateProfile method of an LpexViewListener.
updateProfile allThe following sequence changes the base profile of the current document view to xedit:set updateProfile.baseProfile xedit updateProfile
load command
parse command
actionClass parameter
actions parameter
autoCheck parameter
baseProfile parameter
class parameter
classes parameter
commandClass parameter
commandLine parameter
commands parameter
elementClasses parameter
expandTabs parameter
fields parameter
hideSequenceNumbers parameter
keyAction parameter
keys parameter
mouseAction parameter
mouseEvents parameter
name parameter
palette parameter
parser parameter
popup parameter
prefixArea parameter
prefixAreaText parameter
prefixProtect parameter
readonly parameter
sequenceNumbers parameter
show parameter
style parameter
styleAttributes parameter
tabs parameter
setParser action
Default editor commands