[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bug in set-frame-position?

From: Francis Litterio
Subject: Re: bug in set-frame-position?
Date: Tue, 18 Jan 2005 07:24:32 -0500
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/21.3.50 (windows-nt)

Mickey Ferguson wrote:

> Now what I want is to be able to specify my window (frame) to be up against
> the right-hand side of my screen.  So I thought I would use (set-frame
> position (selected-frame) -0 0).  Nope, it interprets -0 the same as 0.  The
> best I could do was -1 0, which left a little space between my window and
> the edge of the screen.  Is there any way to specify it flush-right?  Or is
> this a bug where it should interpret -0 as meaning flush-right, but it's
> not?  Or maybe there's another way to do this?

If you know the size of the small gap between the frame's right border
and the right edge of your display (say, 3 pixels), then you could do

        (set-frame-position frame -1 ypos)
        (set-frame-position frame (+ 3 (frame-parameter frame 'left)) ypos)

This may be caused by the way that function x_calc_absolute_position()
converts negative left and top frame offsets into equivalent positive
offsets for your windowing system.
Francis Litterio
franl <at> world . std . com

reply via email to

[Prev in Thread] Current Thread [Next in Thread]