world.NotepadReadOnly

MUSHclient script function (Method) — introduced in version 4.30

Make a selected notepad window read-only

Prototype

long NotepadReadOnly(BSTR Title, BOOL ReadOnly);

Data type meanings

Description

This lets you mark a notepad window as read-only.

This might be useful for help screens or other "output-only" information.

You can specify true or false as the second argument. Under Lua, it defaults to true.

VBscript example

NotepadReadOnly "test", vbTrue

Jscript example

NotepadReadOnly ("test", true);

Lua example

NotepadReadOnly ("test", true)

Lua notes

The ReadOnly argument is optional and defaults to true.

Return value

0 = Could not do it (eg. that notepad does not exist)
1 = Changed status OK.

Related topic

Notepad

See also

FunctionDescription
GetNotepadListGets the list of open notepads - returning their titles
GetNotepadWindowPositionReturns the position and size of the specified notepad window
NotepadColourChanges the text and background colour of the selected notepad window
NotepadFontChanges the font and style of the selected notepad window