comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: "free" screen size
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: "free" screen size [message #51451 is a reply to message #51449] Sun, 26 November 2006 08:27 Go to previous messageGo to previous message
Dick Jackson is currently offline  Dick Jackson
Messages: 347
Registered: August 1998
Senior Member
"lory" <lore2323@virgilio.it> wrote in message
news:1164462367.533281.304210@45g2000cws.googlegroups.com...
> How can I find the "free" screen size ? I mean the size of the area
> available to display GUIs, something like the dimensions returned by
> GET_SCREEN_SIZE but subtracting the area dedicated to the task bar, if
> it is displayed.
>
> Lory

In IDL 6.3, multiple monitor support was added, along with an option for
excluding taskbar size on Windows. I wrote this function to get at the
desired info easily:


;; Handy function for getting screen size of primary monitor, optionally
;; excluding the taskbar
;;
;; Example:
;; freeSize = GetPrimaryScreenSize(/Exclude_Taskbar)
;; Print, freeSize
;; 1280 946

FUNCTION GetPrimaryScreenSize, Exclude_Taskbar=exclude_Taskbar

oMonInfo = Obj_New('IDLsysMonitorInfo')
rects = oMonInfo -> GetRectangles(Exclude_Taskbar=exclude_Taskbar)
pmi = oMonInfo -> GetPrimaryMonitorIndex()
Obj_Destroy, oMonInfo
Return, rects[[2, 3], pmi] ; w & h of primary monitor avbl. space

END


Cheers,
-Dick

--
Dick Jackson Software Consulting http://www.d-jackson.com
Victoria, BC, Canada +1-250-220-6117 dick@d-jackson.com
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: showing only variables
Next Topic: "free" screen size

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 13:16:41 PDT 2025

Total time taken to generate the page: 1.28010 seconds