From: John Stone (johns_at_ks.uiuc.edu)
Date: Sun Apr 22 2012 - 22:56:02 CDT

Hi,
  At present VMD doesn't have a routine for querying the OpenGL
window position. Part of the reason for this is because the host
OS window manager settings affect the real position of the window, based
on the window decorations in use.

I think the most important question is, what do you want to do once
you've got the position of the OpenGL window?

If your goal is to position other windows around it, you are quickly going
to discover that some window managers will refuse to cooperate, and will
not necessarily honor your request, even if it is valid and falls entirely
within the bounds of the target display. Some window managers don't
handle multi-display systems well at all, and do very bad things with
window positioning requests.

If you're trying to do something else, let me know what it is and we
can go from there.

Cheers,
  John Stone
  vmd_at_ks.uiuc.edu

On Mon, Apr 23, 2012 at 03:20:56AM +0000, Mayne, Christopher G wrote:
> Is there a ~consistent way on each os for which I could write and if-then to check for the os? Or is this not a well-supported feature?
>
> Chris
>
>
>
> On Apr 22, 2012, at 10:13 PM, "Axel Kohlmeyer" <akohlmey_at_gmail.com> wrote:
>
> > On Sun, Apr 22, 2012 at 11:08 PM, Mayne, Christopher G
> > <cmayne2_at_illinois.edu> wrote:
> >> I'm developing on a Mac, but would like a general solution.
> >
> > doesn't exist. if you run with the "wrong" window manager
> > (i.e. the default in several popular distributions) on Linux
> > even the display reposition command has no effect.
> >
> > and windows is an entirely different story.
> >
> > axel.
> >
> >>
> >> Chris
> >>
> >>
> >>
> >> On Apr 22, 2012, at 9:46 PM, "Axel Kohlmeyer" <akohlmey_at_gmail.com> wrote:
> >>
> >>> On Sat, Apr 21, 2012 at 3:01 PM, Mayne, Christopher G
> >>> <cmayne2_at_illinois.edu> wrote:
> >>>> VMD-L-ers,
> >>>>
> >>>> Is there a tcl command to get the current x,y position of the OpenGL display window? The VMD documentation (http://www.ks.uiuc.edu/Research/vmd/current/ug/node125.html) provides the "display reposition" command to move the window, but doesn't seem to describe how to get the current location.
> >>>
> >>> on what platform?
> >>>
> >>> there are some tricks possible on Linux machines,
> >>> but also many Linux machines have window managers
> >>> that assume that a user doesn't know what he is doing
> >>> and thus ignore or override some commands.
> >>>
> >>> cheers,
> >>> axel.
> >>>
> >>>
> >>>>
> >>>> Thanks,
> >>>> Chris
> >>>
> >>>
> >>>
> >>> --
> >>> Dr. Axel Kohlmeyer
> >>> akohlmey_at_gmail.com http://goo.gl/1wk0
> >>>
> >>> College of Science and Technology
> >>> Temple University, Philadelphia PA, USA.
> >
> >
> >
> > --
> > Dr. Axel Kohlmeyer
> > akohlmey_at_gmail.com http://goo.gl/1wk0
> >
> > College of Science and Technology
> > Temple University, Philadelphia PA, USA.

-- 
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
http://www.ks.uiuc.edu/~johns/           Phone: 217-244-3349
http://www.ks.uiuc.edu/Research/vmd/       Fax: 217-244-6078