From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.help Subject: Re: How do I get the window height in lines, taking in account line-spacing? Date: Mon, 04 Aug 2014 23:16:14 +0400 Message-ID: <53DFDBFE.5020902@yandex.ru> References: <53DF7885.8000907@yandex.ru> <87oaw08hlj.fsf@web.de> <86d2cg3y3x.fsf@yandex.ru> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1407179822 11625 80.91.229.3 (4 Aug 2014 19:17:02 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 4 Aug 2014 19:17:02 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: John W Higgins Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Aug 04 21:16:54 2014 Return-path: Envelope-to: geh-help-gnu-emacs@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 1XENkb-0005m7-Oc for geh-help-gnu-emacs@m.gmane.org; Mon, 04 Aug 2014 21:16:53 +0200 Original-Received: from localhost ([::1]:54246 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XENkb-00012T-9q for geh-help-gnu-emacs@m.gmane.org; Mon, 04 Aug 2014 15:16:53 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52663) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XENkH-00012I-4e for help-gnu-emacs@gnu.org; Mon, 04 Aug 2014 15:16:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XENk4-0005Mh-C4 for help-gnu-emacs@gnu.org; Mon, 04 Aug 2014 15:16:32 -0400 Original-Received: from mail-la0-x230.google.com ([2a00:1450:4010:c03::230]:40681) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XENk4-0005LT-3P for help-gnu-emacs@gnu.org; Mon, 04 Aug 2014 15:16:20 -0400 Original-Received: by mail-la0-f48.google.com with SMTP id gl10so5722647lab.21 for ; Mon, 04 Aug 2014 12:16:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=g9EN/uvRPUI2n7KaztjPL2dcSSwKgkX81zJTAT2EKlE=; b=XVPjVAl+wyMHnIEWdBxdAXAjCLXHAQj6SNWr29IZtjfDKjSp2/ZmDlJjbsws1J5GdW mYRpQkFy2yTCnzVvS6CiISQcNoJPrLDGnFGfE3I1qz910hNAw2OAzDF5XvWwbJeZ9p8i 4e5MFqyQDyL6uyRoiS7OaRs6JiKtvJte6cwV6oOPkeIfVB1KcY2hoIwhq2KVTRLfrEvY 40UhkwkqYRFmm9101RVGlPPWLcNxB7RLm2Rebbdwt+uTkkb81m+/LLIDEyqz2GSbRXDo EJWlwV0U9Dhsw7j5lGGXG7WVURVJxv8ckvyk1x9C7IbOAk6b8XhUEdAzu1SvGzRPA8/s zgdw== X-Received: by 10.112.202.69 with SMTP id kg5mr24493418lbc.33.1407179778978; Mon, 04 Aug 2014 12:16:18 -0700 (PDT) Original-Received: from [10.8.0.26] (v-2-eu19-d3962-07.webazilla.com. [78.140.151.7]) by mx.google.com with ESMTPSA id u6sm10167077laj.7.2014.08.04.12.16.17 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 04 Aug 2014 12:16:18 -0700 (PDT) User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.0 In-Reply-To: X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::230 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:99080 Archived-At: On 08/04/2014 10:43 PM, John W Higgins wrote: > It would appear for the purpose of the issue you are discussing that a > smaller number would not matter because at worst you would put the popup > above the line for 2 extra rows. True, that drawback is not critical. > That would, to me at least, be > irrelevant to solving the problem. I appreciate the need for accuracy - > but this would at least fail in a good way for you. That might be so, but I'm already solving a non-critical problem: drawing popup better for users who customized the line-spacing value, which is a relatively rare thing to do, I believe. So as long as I'm doing that, I might as well look for a good solution. > I'm assuming you have not discovered a scenario where the calculation, > for example, comes up with 50.5 lines for 49 actual visible lines. Indeed, I haven't.