From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.devel Subject: Re: x-display-pixel-width/height inconsistency Date: Fri, 5 Jul 2013 00:32:10 +0200 Message-ID: References: <83vc6tcqss.fsf@gnu.org> <83haibdipo.fsf@gnu.org> <837gj7co0l.fsf@gnu.org> <8338tvcjlp.fsf@gnu.org> <83wqr7b3h6.fsf@gnu.org> <51D12678.5090806@gmx.at> <51D2ADAA.9000805@gmx.at> <51D2D180.6050002@gmx.at> <51D3EE69.9080808@gmx.at> <51D41CA2.8000206@gmx.at> <51D541B6.1000908@gmx.at> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: ger.gmane.org 1372977176 1271 80.91.229.3 (4 Jul 2013 22:32:56 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 4 Jul 2013 22:32:56 +0000 (UTC) Cc: YAMAMOTO Mitsuharu , Emacs developers To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Jul 05 00:32:57 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Uus5B-00082i-25 for ged-emacs-devel@m.gmane.org; Fri, 05 Jul 2013 00:32:57 +0200 Original-Received: from localhost ([::1]:43318 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uus5A-0005xP-KF for ged-emacs-devel@m.gmane.org; Thu, 04 Jul 2013 18:32:56 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48847) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uus56-0005xI-SA for emacs-devel@gnu.org; Thu, 04 Jul 2013 18:32:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uus56-0005l7-1H for emacs-devel@gnu.org; Thu, 04 Jul 2013 18:32:52 -0400 Original-Received: from mail-ea0-x229.google.com ([2a00:1450:4013:c01::229]:36327) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uus55-0005kw-Rv for emacs-devel@gnu.org; Thu, 04 Jul 2013 18:32:51 -0400 Original-Received: by mail-ea0-f169.google.com with SMTP id h15so1119223eak.28 for ; Thu, 04 Jul 2013 15:32:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=h4NCDWW8BrT341kCQdg8VIvKkqnErLFZn7yOju3HC90=; b=vtoJDOhy5jPtXQuA78UDrqd+QmoDhReoZ9V5tSb2EEU9gMolbTljJPIrj+1Ah40xR7 b2i3BJ9HX/OvNLH7xI/+/QEuefZRIs6IFPy2hMctg2XUecWwPE2sveXIgHpUo31JP4c9 zQO3AnsxhXhGEadRxzuCSZ62sL9ahtMTk7nA2f/atz/+++bVoqur0/tb47ci3JImWZyU f5w/5/1R52YwzyRLgaQv5LCqSxqcpAAOIBp6yJmpHTOskFo9RZMTzYUdSttbgHnycu0d d8Bd7EKHCWlT1pxJwD7JRVAvbLitVLyDjAHbf44Xq8vwWijsYQV/7KJ0vYdUXEHCYPko pzAw== X-Received: by 10.15.36.133 with SMTP id i5mr9071272eev.52.1372977171091; Thu, 04 Jul 2013 15:32:51 -0700 (PDT) Original-Received: by 10.14.142.4 with HTTP; Thu, 4 Jul 2013 15:32:10 -0700 (PDT) In-Reply-To: <51D541B6.1000908@gmx.at> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4013:c01::229 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:161541 Archived-At: > On Windows frame and client rectangle include the toolbar. So I'm not > sure how to generalize this conveniently. Oh. Anyway, backtracking a bit in this thread... We were talking about multi-monitors and client sizes, etc. because someone proposed to automatically detect when desktop is restoring frames in a different display/monitor configuration and make sure that the frames were visible. But, OTOH, it is entirely possible that the user is saving the desktop with some frames only partially visible. If you have many, and some of them are less used, you can set them aside so only a fraction of the frame is shown, which makes them accessible without taking too much screen space. So, IMO, the only thing that makes sense is to move/resize a frame while restoring when that frame is entirely outside the current viewing area. Or, perhaps, when the caption is (because in many/most/all? window managers, you can mouse-drag a window only from its caption). Of course, there's no way to know the caption height (in pixels) from inside Emacs, I think, so in the end it's all an ugly heuristics: the top of the frame is some arbitrary number of pixels inside the viewing area. Or is there a better way? J