:dd.Matches preceeding or next pattern (a|b, c|d, abc|d). Only one character will be used as pattern unless grouped together using {} or ().
:dt.:hp2.*:ehp2.
:dd.Match zero or more occurances of preceeding pattern. Matching is greedy and will match as much as possible.
:dt.:hp2.+:ehp2.
:dd.Match one or more occurances of preceeding pattern. Match is greedy.
:dt.:hp2.@:ehp2.
:dd.Match zero or more occurances of preceeding pattern. Matching is non-greedy and will match as little as possible without causing the rest of the pattern match to fail.
:dt.:hp2.#:ehp2.
:dd.Match one or more occurances of preceeding pattern. Matching is non-greedy.
:dt.:hp2.{ }:ehp2.
:dd.Group patterns together to form complex pattern. ( {abc}, {abc}|{cde}, {abc}?, {word}?)
:dt.:hp2.( ):ehp2.
:dd.Group patterns together to form complex pattern. Also used to remember the matched substring which can be used for substitution operation. Up to 9 can be used.
:edl.
:p.
:hp2.Replace Operators&colon.:ehp2.
:dl compact tsize=8 break=all.
:dt.:hp2.\:ehp2.
:dd.Causes the next character to lose it's special meaning.
:dt.:hp2.\n:ehp2.
:dd.Inserts a 0x0A (LF) character.
:dt.:hp2.\r:ehp2.
:dd.Inserts a 0x0D (CR) character.
:dt.:hp2.\t:ehp2.
:dd.Inserts a 0x09 (TAB) character.
:dt.:hp2.\#:ehp2.
:dd.Recalls stored substring from matched pattern ()'s. (\1, \2, \3, to \9)
:dt.:hp2.\0:ehp2.
:dd.Recalls entire matched pattern.
:dt.:hp2.\u:ehp2.
:dd.Convert next character to uppercase
:dt.:hp2.\l:ehp2.
:dd.Convert next character to lowercase
:dt.:hp2.\U:ehp2.
:dd.Convert to uppercase till \E or \e
:dt.:hp2.\L:ehp2.
:dd.Convert to lowercase till \E or \e
:edl.
.br
:h1.Search and Replace
:i1 id=search.Search and Replace
:p.
:hp2.Search and Replace Commands&colon.:ehp2.
:p.
:dl compact tsize=8 break=all.
:dt.:hp2.Find:ehp2.:dd.Search for text w/options.
:dt.:hp2.FindReplace:ehp2.:dd.Search and replace text w/options.
:dt.:hp2.FindRepeat:ehp2.:dd.Repeat last search/replace operation
:dt.:hp2.FindRepeatReverse:ehp2.:dd.Repeat last search/replace operation in opposite direction
:dt.:hp2.FindRepeatOnce:ehp2.:dd.Repeat last search/replace operation only once.
:dt.:hp2.MatchBracket:ehp2.:dd.Search for matching bracket
:dt.:hp2.IncrementalSearch:ehp2.:dd.Search incrementally for text.
:dt.:hp2.Search:ehp2.:dd.Search for text
:dt.:hp2.SearchB:ehp2.:dd.Search for text backwards
:dt.:hp2.SearchRx:ehp2.:dd.Search for regexp
:dt.:hp2.SearchReplaceRx:ehp2.:dd.Search and replace using regexp
:dt.:hp2.SearchAgain:ehp2.:dd.Search for text again
:dt.:hp2.SearchAgainB:ehp2.:dd.Search for text again backwards
:dt.:hp2.SearchReplace:ehp2.:dd.Search for text and replace
:dt.:hp2.SearchReplaceB:ehp2.:dd.Search and replace backwards
:edl.
:p.
If :hp2.WSStyleSearch:ehp2. is set to 1, search/replace string and options
are entered at separate prompts. Otherwise they must be separated by a '/'
(slash) and any slash or backslash in search/replace string must be escaped
by '\' (backslash), except when using regular expressions (double
escaping is not necessary).
:p.
For example (when WSStyleSearch is off)&colon.
:xmp.
foo/bar/agn replace all foo with bar globally without prompting
:exmp.
:hp2.Search and Replace Options:ehp2.
:p.
:dl compact tsize=8 break=all.
:dt.:hp2.a:ehp2.:dd.Search for all occurances
:dt.:hp2.b:ehp2.:dd.Search in block only
:dt.:hp2.g:ehp2.:dd.Search through entire file/block (globally).
Commands affected by :hp2.DefFindOpt:ehp2. mode setting&colon.
:ul compact.
:li.:hp2.Find:ehp2.
:eul.
:p.
Commands affected by :hp2.DefFindReplaceOpt:ehp2. mode setting&colon.
:ul compact.
:li.:hp2.FindReplace:ehp2.
:eul.
:p.
Commands affected by :hp2.MatchCase:ehp2. mode setting&colon.
:ul compact.
:li.:hp2.IncrementalSearch:ehp2.
:li.:hp2.Search:ehp2.
:li.:hp2.SearchB:ehp2.
:li.:hp2.SearchRx:ehp2.
:li.:hp2.SearchReplaceRx:ehp2.
:li.:hp2.SearchReplace:ehp2.
:li.:hp2.SearchReplaceB:ehp2.
:eul.
:p.
Commands affected by :hp2.WSStyleSearch:ehp2. mode setting&colon.
:ul compact.
:li.:hp2.Find:ehp2.
:li.:hp2.FindReplace:ehp2.
:li.:hp2.FindRepeat:ehp2.
:li.:hp2.FindRepeatReverse:ehp2.
:li.:hp2.FindRepeatOnce:ehp2.
:eul.
.br
:h1.CMode Smart Indentation
:i1 id=cindent.CMode Smart Indentation
:hp2.Settings for CMode smart indentation:ehp2.
:p.
:dl compact tsize=8 break=all.
:dt.:hp2.C_Indent:ehp2.:dd.Basic C indentation level
:dt.:hp2.C_BraceOfs:ehp2.:dd.Brace '{' offset
:dt.:hp2.C_CaseOfs:ehp2.:dd.Offset of case and default statements
:dt.:hp2.C_CaseDelta:ehp2.:dd.Offsets of statements following case/default.
:dt.:hp2.C_ClassOfs:ehp2.:dd.Offset of public, private and protected
:dt.:hp2.C_ClassDelta:ehp2.:dd.Offset of statements following public, private, protected
:dt.:hp2.C_ColonOfs:ehp2.:dd.Offset of labels
:dt.:hp2.C_CommentOfs:ehp2.:dd.Offset of comments
:dt.:hp2.C_CommentDelta:ehp2.:dd.Offset of second line of comments
:edl.
:p.
Example 1&colon.
:xmp.
class line {
public&colon. // C_ClassOfs = 0
line(); // C_ClassDelta = 4
~line();
};
int main() {
int x = 1;
/* // C_CommentOfs = 0
* check value // C_CommentDelta = 1
*/
puts("main"); // C_Indent = 4
if (x)
{ // C_BraceOfs = 0
switch (x) {
case 1&colon. // C_CaseOfs = 0
puts("ok"); // C_CaseDelta = 4
break;
}
}
end&colon.
return 0;
}
:exmp.
:p.
Example 2&colon.
:xmp.
class line {
public&colon. // C_ClassOfs = 2
line(); // C_ClassDelta = 2
~line();
};
int main() {
int x = 1;
/* // C_CommentOfs = 2
** check value // C_CommentDelta = 0
*/
puts("main"); // C_Indent = 4
if (x)
{ // C_BraceOfs = 0
switch (x) {
case 1&colon. // C_CaseOfs = 4
puts("ok"); // C_CaseDelta = 4
break;
}
}
end&colon.
return 0;
}
:exmp.
.br
:h1.Performance Tips
If you want to achieve top performance (necessary for
some text editing tasks), here are some tips&colon.
:ul compact.
:li.Disable Tab Expansion
:li.Disable ShowMarkers
:li.Disable Undo
:li.Use PLAIN hilit mode
:eul.
:h1.History of Changes
:i1 id=history.History of Changes
:ul compact.
:li.0.37:ul compact.
:li.Status line can now be hidden. Also changed it's look.
:li.Changed the syntax of keyboard bindings. Now it is possible to better emulate the wordstar two-key behavior. See documentation for details. It is also possible to define different commands for gray/white keys.
:li.MENU shortcuts now work.
:li.New command&colon. FileWriteTo
:li.Fixed crash when trying to center nonexistant line in file.
:li.Changing folds now modifies the file.
:li.When CursorTroughTabs was set to 0, certain movement commands would behave incorrectly.
:li.S-Ins will perform Paste operation in prompts.
:li.New Command&colon. WinResize <delta> and WinClose. Windows can be also resized by a mouse.
:eul.
:li.0.36:ul compact.
:li.Fixed when editor would crash when saving a folded file, but no folds
:li.When checking for file modification time of last change is now used instead of the time of last access.
:li.Wildcard support for file loading.
:eul.
:eul.
:li.0.23
:ul compact.
:li.1995/06/04
:ul compact.
:li.Ctrl+C and Ctrl+Break are now disabled.
:li.Ctrl+S and Ctrl+C keys are now again recognised in Windowed mode.
:li.Fixed problem when spawning a subprocess in Windowed mode.
:li.New command&colon. ShowEntryScreen
:li.ListRoutines in CMode only shows functions not their prototypes.
:li.New setting&colon. SysClipboard - if set to 1, editor will automatically use system clipboard.
:li.New command&colon. ToggleSysClipboard.
:li.Minor bug fix in PM clipboard support.
:li.New commands&colon. BlockPasteStream, BlockPasteColumn and BlockPasteLine. BlockPaste command will now always paste in current block mode, not in the last Copy/Cut mode.
:li.More than 4 commands can be bound to a key (actually this worked since 0.18, but was not documented).
:li.New command&colon. FileReload.
:li.Editor will now check if file has changed on disk before saving it.
:eul.
:eul.
:li.0.22
:ul compact.
:li.1995/05/28
:ul compact.
:li.But fix in regular expressions (nested +#*@).
:li.Changes in regular expression syntax.
:li.New function&colon. ListRoutines. Shows functions in current buffer.
:li.New setting&colon. RoutineRx
:eul.
:eul.
:li.0.21
:ul compact.
:li.1995/05/21
:ul compact.
:li.REXX mode smart indentation.
:li.KillWord &. KillWordPrev commands now actually work.
:li.Pressing Ctrl+Enter to begin Search will toggle case sensitivity of search.
:li.New option 'Trim' and commands 'ToggleTrim', 'LineTrim'. Removes whitespace from end of lines.
:li.New option 'ShowMarkers' and command 'ToggleShowMarkers'. Shows end of line and end of file markers.
:li.Bug fix in PERL highlighting (caused lockups)
:li.Bug fixes and improvements in regular expressions.
:eul.
:eul.
:li.0.20
:ul compact.
:li.1995/05/18
:ul compact.
:li.Major bug fixes in word wrap.
:li.New commands&colon. MovePrevTab, MoveNextTab.
:li.Bug fixes in BlockIndent and BlockUnindent (stream/line mode)
:eul.
:eul.
:li.0.19
:ul compact.
:li.1995/05/16
:ul compact.
:li.Function names in REXX are now highlighted.
:li.WordWrap can be set to 0 - disabled, 1 - wrap line at right margin and 2 - wrap paragraph continously. Function ToggleAutoWrap renamed to ToggleWordWrap.
:li.New way to set left/right margin (SetLeftMargin, SetLeftMargin)
:li.Minor fix in PERL highlighting.
:eul.
:eul.
:li.0.18
:ul compact.
:li.1995/05/13
:ul compact.
:li.PERL Syntax Higlighting.
:li.Memory allocation problem in tab expansion.
:li.Wordwrap now strips all spaces on beginning of line (except on the first line of the paragraph).
:li.Tabs can be set to any number between 1 and 32.