$window (remote)

From Scriptwiki
Revision as of 14:41, 9 October 2014 by NaNg (talk | contribs) (special windows.)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Returns information about a window.

$window(N|window name|@WID)
  • Takes either the position of the window (if N=0, returns the number of windows), the name/wildtext of the window, or the window's Window ID. If wildtext is specified, a second N property can be specified ($window(wildtext,N))
  • If no property is given, returns the window name or number of windows (For N=0)
  • Special windows use negative numbers as follow:
    • -1 = Desktop
    • -2 = mIRC window
    • -3 = MDI window
  • There are several properties for $window:
    • .x Returns the window's top left corner X coordinate (Relative to mIRC)
    • .y Returns the window's top left corner Y coordinate (Relative to mIRC)
    • .w Returns the window's width in pixels
    • .h Returns the window's height in pixels
    • .dx Returns the window's top left corner X coordinate (Relative to the desktop)
    • .dy Returns the window's top left corner Y coordinate (Relative to the desktop)
    • .dw Returns the window's text display area's width.
    • .dh Returns the window's text display area's height.
    • .bw Returns the width of the bitmap in a graphic window
    • .bh Returns the height of the bitmap in a graphic window
    • .mdi returns $true if the window is inside the mdi, in other words, if it is a child window of mIRC or on the desktop.
    • .state returns the windows state: minimized, maximized, hidden or normal
    • .title returns the text in the title of a window. Can be set using titlebar
    • .font returns the window's current font name
    • .fontsize returns the window's current font's size
    • .fontbold returns $true if the window's current font is bold.
    • .fontcs returns the window's current font's character set.
    • .logfile returns the full path for the window's log file, or $null if there is none.
    • .icon returns on or off, depending on whether or not the window's icon is visible
    • .ontop returns $true if this window is set to be always on top.
    • .type Returns the window type, such as "channel" "status" or "custom"
    • .anysc Returns $true if created with window -i (Set to be associated with the active server, always).
    • .wid Returns the window ID.
    • .cid Returns the connection ID.
    • .sbtext Returns the text for this window on the switchbar button.
    • .sbcolor Returns the highligt color for this window as shown on the swichbar
    • .sbstate Returns the state for this window on the switchbar
    • .tbstate Returns the state for this window on the treebar