From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Jan =?UTF-8?Q?Dj=C3=A4rv?= Newsgroups: gmane.emacs.bugs Subject: bug#5721: Feature request: Function that returns absolute coordinates Date: Thu, 15 Jul 2010 10:59:52 +0200 Message-ID: <4C3ECE08.2040604@swipnet.se> References: <4B9E4521.9030909@yahoo.co.jp> <4C2C8C02.1010906@swipnet.se> <4C2D9009.60405@swipnet.se> <4C3DD633.7040004@swipnet.se> <4C3EA59E.40300@swipnet.se> <4C3EBDAD.1040800@swipnet.se> <4C3EC17E.6060101@swipnet.se> <4C3EC863.3030803@swipnet.se> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1279184450 25396 80.91.229.12 (15 Jul 2010 09:00:50 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 15 Jul 2010 09:00:50 +0000 (UTC) Cc: 5721@debbugs.gnu.org To: YAMAMOTO Mitsuharu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Jul 15 11:00:48 2010 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OZKJA-0005JN-3H for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Jul 2010 11:00:44 +0200 Original-Received: from localhost ([127.0.0.1]:55925 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OZKJ9-0000g3-Ft for geb-bug-gnu-emacs@m.gmane.org; Thu, 15 Jul 2010 05:00:43 -0400 Original-Received: from [140.186.70.92] (port=53457 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OZKIt-0000bU-Cl for bug-gnu-emacs@gnu.org; Thu, 15 Jul 2010 05:00:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OZKIr-0005mU-HN for bug-gnu-emacs@gnu.org; Thu, 15 Jul 2010 05:00:27 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:52215) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OZKIr-0005mQ-Fx for bug-gnu-emacs@gnu.org; Thu, 15 Jul 2010 05:00:25 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1OZKIW-00088w-3X; Thu, 15 Jul 2010 05:00:04 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Jan =?UTF-8?Q?Dj=C3=A4rv?= Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 15 Jul 2010 09:00:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 5721 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 5721-submit@debbugs.gnu.org id=B5721.127918439931276 (code B ref 5721); Thu, 15 Jul 2010 09:00:04 +0000 Original-Received: (at 5721) by debbugs.gnu.org; 15 Jul 2010 08:59:59 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OZKIQ-00088P-UO for submit@debbugs.gnu.org; Thu, 15 Jul 2010 04:59:59 -0400 Original-Received: from smtprelay-h21.telenor.se ([195.54.99.196]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OZKIO-00088K-DB for 5721@debbugs.gnu.org; Thu, 15 Jul 2010 04:59:57 -0400 Original-Received: from ipb1.telenor.se (ipb1.telenor.se [195.54.127.164]) by smtprelay-h21.telenor.se (Postfix) with ESMTP id AF239E9AB4 for <5721@debbugs.gnu.org>; Thu, 15 Jul 2010 11:00:05 +0200 (CEST) X-SENDER-IP: [85.225.45.35] X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AsM1AGdrPkxV4S0jPGdsb2JhbACHcZd9DAEBAQE1Lb5IhSQEkg0 X-IronPort-AV: E=Sophos;i="4.55,207,1278280800"; d="scan'208";a="105677333" Original-Received: from c-232de155.25-1-64736c10.cust.bredbandsbolaget.se (HELO coolsville.localdomain) ([85.225.45.35]) by ipb1.telenor.se with ESMTP; 15 Jul 2010 10:59:52 +0200 Original-Received: from [172.20.199.13] (zeplin [172.20.199.13]) by coolsville.localdomain (Postfix) with ESMTPSA id 983197FA05A; Thu, 15 Jul 2010 10:59:52 +0200 (CEST) User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; sv-SE; rv:1.9.2.4) Gecko/20100608 Thunderbird/3.1 In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Thu, 15 Jul 2010 05:00:04 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:38541 Archived-At: YAMAMOTO Mitsuharu skrev 2010-07-15 10.44: >>>>>> On Thu, 15 Jul 2010 10:35:47 +0200, Jan Dj=E4rv said: >> That would require unscaled everywhere, even in pos-x-y, window >> sizes, font sizes and so on. I didin't think that was your >> suggestion. > > No, they are all frame-relative, so scaled by the scaling factor. > > The only places currently I can think of in the "absolute" category > are the frame parameters `left' and `top', and some screen parameters > such as `display-pixel-height', etc. Most of the values in Lisp are > designed as frame-relative. But many operations add and subtract from frame top, left and display=20 width/height. How many? I don't know, I just suspect that there are man= y=20 based on what I've seen when editing existing lisp files in Emacs. Not t= o=20 mention C files. > >>> Again, if we used absolute scaled coordinates to specify `left' and >>> `top' frame parameters, we could only place the frame to the >>> position whose coordinates are multiples of the scale factor. > >> As I said earlier, special functions to deal with that for those that = care. > > I don't understand. What happens if a user moved the frame to (101, > 101) using the mouse under the scale factor 2, and he checked > (frame-parameter nil 'left)? Is 101 scaled or unscaled? If scaled, left would be 101. If not scaled, left would be 50. Loss of precision? Sure, but does it ma= tter=20 in most cases? Another idea would be if Emacs had its own internal coordinate system, sa= y 0.0=20 to 1.0 or some integer based one, that already is display independent. It would fit nicely with the GnomeCanvas idea (see other thread). A bunch of work though... Jan D.