multimonitor (again & again) Thread last updated on 2003-09-19 22:40:05

Posted by member 7223 on 2003-09-15 03:18:45

Hi multimonitor user, here am I again with some questions...

In short:
- I've just found that some modules that support real negative coords (rainmeter, layercut, lsdynamic). Should I expect these modules to work correctly on your multimonitor system ?
- In the case they works right, the following stuff should allow moving every modules (those who don't have multimonitor support) in the right place. Am I right ?
*dyn linear straightgoto
*dyn ~linear

*dyn macro straightgoto
*dyn move 0 10 straightgoto
*dyn ~macro

; !move
; \1: class
; \2: caption
; \3: x pos
; \4: y pos
;
; note: coordinates are converted to real negative, if needed


*script bang !move
*script exec !ifeval ("%{\3}" &lt "0") |execute [!varmul \3 -1][!varset \3 ~%{\3}]
*script exec !ifeval ("%{\4}" &lt "0") |execute [!varmul \4 -1][!varset \4 ~%{\4}]
*script exec !dynchangemovement straightgoto dest %{\3} %{\4}
*script exec !straightgoto "%{\1}" "%{\2}"
*script ~bang


In this example, you only need lsdynamic.dll.
To move something, simply call:
!move "Class" "Caption" x y

If there's no caption, use "*"

@DeViLbOi: I still need to replace "lessthan" if I don't want my post to be troncated...

Posted by member 1 on 2003-09-15 06:18:08 link

what are "real negative coords"?

nothing I can do about it...it thinks you want to make an HTML command.

Posted by member 37809 on 2003-09-15 07:37:10 link

try < for less-than. if that doesn't work, try <

Posted by member 7223 on 2003-09-15 07:53:14 link

@DeViLbOi: real negative coordinates allow you to place stuff outside the left/top side of the screen.

@tnl: thanks; it works !

Posted by member 1 on 2003-09-15 11:00:44 link

and why would you want to put something out of visible range?

Posted by member 1783 on 2003-09-15 13:41:12 link

to animate something coming out from the left/top side of the screen for example ;)

Posted by member 7223 on 2003-09-15 13:52:56 link

@DeViLbOi: to drag boxes partially outside the screen... but this is not the purpose of this post.

I just want to know if the above script allow people to put (and optionally drag) stuff where they want on their multimonitor system.

Posted by member 99 on 2003-09-15 19:44:12 link

Some modules (some of mine at least) also support real negative coordinates via "0%-200", which might allow you to do without the if.

Anyway, for the most common dual-monitor system (ie, second monitor on the right), this should always work.

For the general case, it depends where the module's origin is. Some modules always place the origin at the top, left corner of the desktop, in which case negative coords will always be off screen. Most modules make no adjustment (or incorrect adjustments) that make life difficult.

I think the most common is to use the top, left corner of the primary monitor when on top and the top, left corner of the desktop when on bottom. In this situation, there is no way to tell what coordinates will be off screen when they're on top with regular builds of litestep.

Unfortunately, I don't know what lsdynamic uses.

(and for another reason to place stuff outside of visible space, RabidVWM doesn't generate OnRepaint events when hidden, so if you want to use them but hide the VWM, you have to move it off screen instead)

Posted by member 7223 on 2003-09-17 00:48:27 link

Does nobody want to test the above script in order to see if it's working on multi-monitors ?

...
Hey, multimonitor user, don't comes later and complain: "boooh... there's no theme working right on my shiny multimonitor system..."

Posted by member 580 on 2003-09-18 23:49:59 link

rabidcow mentioned some of the issues with multimon, but..

real negative coords doesn't really have anything to do with multimonitors, they just avoid "wrapping" with negative values. the coordinate system used is more relevant, though with coordinates relative to the primary screen you need real negative in order to specify a position on a monitor to the left/above the primary screen. lsdynamic uses virtual screen coordinates tho, so coords are relative to top/left of the desktop (the bounding box around all monitors), ie. everywhere visible is at a positive coord and real negative is only required for coords off-screen.

so you're right, that script should let you move any module relative to the virtual screen even if the module itself uses primary screen coords. you don't really need the ifs though, unless you want to force wrapping to not occur (not necessary for multimon support in this case).

"real" multimon support would let you specify coords relative to a specific monitor, but that requires a lot more work like rabidcow's special ls-build, so support in this case only means the ability to specify a position on any monitor (not relative to the desired monitor, which is noticeable if the monitor is in a different place from what your theme assumes or you move the monitor.. better than nothing tho)

Posted by member 7223 on 2003-09-19 05:45:10 link

xnowfall: big thanks.

About negatives coords: yes, I need to put stuf offscreen. In fact, my new theme is made with boxes (not lsbox) you can drag anywhere you want. Then, I think it's a good thing to allow half-offscreen positioning.

About multimonitor support: in the case of my new theme, there's no need to specify on wich monitor stuff should appear because you can drag it. If you really can drag it from one monitor to another, then I considere the work is done (in my case; I repeat)

Posted by member 7223 on 2003-09-19 22:40:05 link

hum, just one more question:

does anyone knows if the mzscript vars %{mousex} and %{mousey} are relative to the top/left corner of the desktop (the bounding box around all monitors) or to the top/left corner of the primary monitor ?