Platforms to show: All Mac Windows Linux Cross-Platform

WindowsMonitorMBS class

Type Topic Plugin Version macOS Windows Linux iOS Targets
class Windows MBS Win Plugin 11.3 ❌ No ✅ Yes ❌ No ❌ No Desktop, Console & Web
The class to query monitor details on Windows.
Example
for each m as WindowsMonitorMBS in WindowsMonitorMBS.AllMonitors
MsgBox m.DeviceName+": "+str(m.Left)+"x"+str(m.top)+" "+str(m.Width)+"x"+str(m.Height)
next
  • 15 properties
  • 7 shared methods
    • shared method AllMonitors as WindowsMonitorMBS()
    • shared method AllMonitors(monitors() as WindowsMonitorMBS) as Integer
    • shared method MonitorFromPoint(x as Integer, y as Integer, flags as Integer = 0) as WindowsMonitorMBS
    • shared method MonitorFromRect(left as Integer, top as Integer, width as Integer, height as Integer, flags as Integer = 0) as WindowsMonitorMBS
    • shared method MonitorFromWindow(win as DesktopWindow, flags as integer = 0) as WindowsMonitorMBS
    • shared method MonitorFromWindow(win as window, flags as Integer = 0) as WindowsMonitorMBS
    • shared method MonitorFromWindow(WindowHandle as Integer, flags as Integer = 0) as WindowsMonitorMBS
  • 3 constants

Constants

Constant Value Description
kDefaultToNearest 2 One of the flag constants. Return the display monitor that is nearest to the window, point or rectangle.
kDefaultToNull 0 One of the flag constants. Returns nil if no monitor matches is located at point, window or rectangle.
kDefaultToPrimary 1 One of the flag constants. Returns the primary display monitor if point, rect or window does not point to a monitor.

This class has no sub classes.

Some examples using this class:

Blog Entries


The items on this page are in the following plugins: MBS Win Plugin.


WindowsMLExceptionMBS   -   WindowsMutexMBS


The biggest plugin in space...