how to know 2 monitors are in use?

Richmond richmondmathewson at gmail.com
Fri Sep 28 05:40:47 EDT 2018


All well and good, in theory, but I have just been fooling around with a 
monitor that gives

me 0,0,1600,900, and then "getting its knickers in a twist" because when 
I feed the topleft

of the VDU into my calculations I get a "tried to divide 0 by 0" thing.

I suppose (?) one of the ways round this would be to change 0,0,1600,900 
to 1,1,1600,900

and live with the "tragedy" that everything would be one pixel "out of 
whack".


Richmond.


On 26.09.2018 17:37, Bob Sneidar via use-livecode wrote:
> Or you could use the recent line intersect function recently posted by Richmond on the top,left bottom,right and bottom,left and top,right of your chosen monitor and round the results:
>
> http://forums.livecode.com/viewtopic.php?f=7&t=31565
>
> Bob S
>
>
>> On Sep 25, 2018, at 18:57 , Nicolas Cueto via use-livecode <use-livecode at lists.runrev.com> wrote:
>>
>> Thank you, Paul.
>>
>> Using "screenrects" as Paul suggested, here, for future reference, is a
>> script snippet that places a stack on the right monitor:
>>
>> put the screenrects into tScrRects
>> if the environment is "development" and the number of lines in tScrRects >
>> 1 then
>>       -- CENTRE THE STACK ON THE RIGHT MONITOR
>>       put line 2 of tScrRects into tRMon -- right monitor rect
>>       put ((item 3 of tRMon - item 1 of tRMon) / 2 + item 1 of tRMon) &
>> comma & \
>>             ((item 4 of tRMon - item 2 of tRMon) / 2) into tRect
>>       set the loc of this stack to tRect
>>    else
>>       -- CENTRE THE STACK ON TE LEFT MONITOR
>>       set the loc of this stack to the screenloc
>>    end if
>> --
>> Nicolas Cueto
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list