[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
+---------------------------------+
|              MCOL               |
+---------------------------------+
MCOL([<expC>])

-----------------------------------
Returns screen or window column position of mouse pointer.
Return value - Numeric
-----------------------------------

MCOL() will return the screen column position of the mouse pointer if
the null string ("") is specified in <expC>.  The null string specifies
the screen when used in functions that return window or mouse locations
or window sizes (WCOLS(), WROWS(), WLCOL(), WLROW(), etc.).  The screen
column coordinate of the mouse pointer is also returned if <expC> is
omitted and there is no active output window.

If there is an active output window and <expC> is omitted, MCOL() will
return the mouse pointer column coordinate relative to the output
window.

If you specify a window name in <expC>, the column coordinate is
returned relative to the specified window.  In either case, MCOL()
returns a value of -1 if the mouse pointer is positioned outside of the
window.  If <expC> is the name of a Browse window or the Trace window,
note that the window borders return values between zero and the number
of window columns.  Other windows return -1 for their window borders.

The value returned by MCOL() is dependent on the current video display
mode.

If MCOL() returns a screen column coordinate, the value will range
between 0 and the maximum number of screen columns minus 1.  For
example, if the current display mode is EGA25, MCOL() will return a
value between 0 and 79.

If MCOL() returns a window column coordinate, the value will range
between 0 and the number of columns in the window minus 1 (or -1 if the
mouse pointer is outside the window).  The number of columns in a window
can be determined with the WCOLS() function.

If the mouse driver has not been loaded MCOL() always returns -1.  This
lets you test for the presence of a mouse at the beginning of a program.

Clauses
-------

<expC>
        Window name.

-----------------------------------

See Also:  COL(), MDOWN(), MROW(), ROW(), WCOLS(), WROWS()

-----------------------------------

See Also: COL() MDOWN() MROW() ROW() WCOLS() WROWS()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson