[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#5721: Feature request: Function that returns absolute coordinates
From: |
YAMAMOTO Mitsuharu |
Subject: |
bug#5721: Feature request: Function that returns absolute coordinates |
Date: |
Fri, 16 Jul 2010 09:35:54 +0900 |
User-agent: |
Wanderlust/2.14.0 (Africa) SEMI/1.14.6 (Maruoka) FLIM/1.14.8 (Shijō) APEL/10.6 Emacs/22.3 (sparc-sun-solaris2.8) MULE/5.0 (SAKAKI) |
>>>>> On Thu, 15 Jul 2010 12:56:38 +0200, Jan Djärv <jan.h.d@swipnet.se> said:
>> It seems to be difficult to reach agreement about absolete unscaled
>> vs. absolute scaled. Fortunately, that doesn't matter for X11
>> currently, and we agree with the necessity of a special function
>> that returns absolute unscaled coordinates to pass to an external
>> program. Why don't we start discussing the specification of that
>> special function, letting absolute unscaled vs. absolute scaled
>> aside for now?
>>
>> My proposal was to make it parallel to posn-at-x-y, as I mentioned.
>>
>> (posn-at-x-y x y &optional frame-or-window whole)
>>
> Sure. Please check the ifdefs in the window absolute functions I
> made to see the various differences w.r.t tool bar and menu bar.
I don't think such ifdefs are necessary. The strategy I'm thinking of
is:
1) Convert window coordinates to frame coordinates if the third
argument is not a frame. This should be similar to the code in
pos-at-x-y.
2) Call a terminal-specific function that converts frame-relative
coordinates to absolute coordinates. That can be done by the
following "idiom".
x += f->left_pos + FRAME_OUTER_TO_INNER_DIFF_X (f);
y += f->top_pos + FRAME_OUTER_TO_INNER_DIFF_Y (f);
on X11 and
ClientToScreen (FRAME_W32_WINDOW (f), &pt)
on W32, I guess.
By the way, window-(inside-)absolute-pixel-edges doesn't seem to take
account of title bar height. Is that correct?
YAMAMOTO Mitsuharu
mituharu@math.s.chiba-u.ac.jp
- bug#5721: Feature request: Function that returns absolute coordinates, (continued)
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/15
- bug#5721: Feature request: Function that returns absolute coordinates,
YAMAMOTO Mitsuharu <=
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/16
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/16
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/16
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/16
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/16
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/16
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/17
- bug#5721: Feature request: Function that returns absolute coordinates, Jan Djärv, 2010/07/17
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/17
- bug#5721: Feature request: Function that returns absolute coordinates, YAMAMOTO Mitsuharu, 2010/07/15