MousePosition["ScreenAbsolute"]
absolute position within the complete screen display
WindowMargins
specifies the distances from each edge of the main display screen to each edge of the notebook window.
Those descriptions are not word to word the same but also seem to be so.
My problem is that I have Win7 and my MenuBar at the left side of the screen. MousePosition
is counting from the screen edge while WindowMargins
are from the MenuBar.
After evaluating
CreateDocument["TEST",
WindowSize -> {500, 100},
WindowMargins -> {{#, Automatic}, {Automatic, #2}} & @@ MousePosition["ScreenAbsolute"]]
I got new notebook slightly shifted. I'd like it's left top corner to appear exactly on mouse position.
(yes, my menu bar is wide :))
Is this the case on Linux too?
I would like to have clean and stable solution so I don't have to think about where my MenuBar is currently positioned.
I have something in mind but it looks ugly.
Edit My idea is to create floating elements from "Frameless"
notebooks. The problem is to put them in right position.
I was digging around lately and found out that WRI has no easy fix either. It seems they are doing, what I was about to do, in Find & Replace
dialog:
As you can see, menu list alignment depends on where my Windows Manu bar is...
Well, maybe bug fits now?
CurrentValue["ScreenArea"]
but it becomes messy for multiple screens and different layouts. $\endgroup$