world.WindowSetZOrder

MUSHclient script function (Method) — introduced in version 4.73

Sets the Z-Order for a miniwindow

Prototype

long WindowSetZOrder(BSTR WindowName, long Order);

Data type meanings

Description

Sets a Z-Order (drawing order) for the miniwindow.

Note that changes to miniwindows will not become visible until the output window is redrawn. This happens when new (visible) lines arrive from the MUD, or if you call WindowShow, or Redraw.

Parameters:

WindowName - the name of an existing miniwindow.

Order - the order to draw the window. Lower is drawn sooner. Windows with the same Z-Order are drawn in window name order. So for example, the default case of a zero Z-Order results in windows being drawn in name order.

More specifically:

* Windows with a negative Z-order are drawn first (in order, so -2 would be drawn before -1).

* Windows with a zero Z-order (the default) are drawn next, in name order (lower name first)

* Windows with a positive Z-order are drawn last, in Z-order sequence.

* If there are two (or more) windows with the same Z-order number, they are drawn in name order.

Note that being "drawn first" means that a window appears underneath a window which is drawn later.

Lua example

WindowSetZOrder (win, 20)

Return value

eNoSuchWindow - no such miniwindow

eOK - success

Return code meanings

Related topic

MiniWindows

See also

FunctionDescription
WindowArcDraws an arc in a miniwindow
WindowBezierDraws a Bézier curve in a miniwindow
WindowCircleOpDraws ellipses, filled rectangles, round rectangles, chords, pies in a miniwindow
WindowCreateCreates a miniwindow
WindowDrawImageDraws an image into a miniwindow
WindowGetPixelGets the colour of a single pixel in a miniwindow
WindowLineDraws a line in a miniwindow
WindowPolygonDraws a polygon in a miniwindow
WindowRectOpDraws a rectangle in a miniwindow