From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stefan Kangas Newsgroups: gmane.emacs.bugs Subject: bug#41737: 26.3; (window-text-pixel-size) in console Date: Wed, 12 Aug 2020 18:01:31 -0700 Message-ID: References: <87a71g1hv1.fsf@logand.com> <83eeqs873k.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="15309"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: 41737-done@debbugs.gnu.org, Tomas Hlavaty To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Aug 13 03:02:14 2020 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1k61dF-0003nm-D4 for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 13 Aug 2020 03:02:13 +0200 Original-Received: from localhost ([::1]:60072 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1k61dE-000315-Ea for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 12 Aug 2020 21:02:12 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35548) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1k61d5-0002w2-5v for bug-gnu-emacs@gnu.org; Wed, 12 Aug 2020 21:02:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:34627) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1k61d4-0004G4-RO for bug-gnu-emacs@gnu.org; Wed, 12 Aug 2020 21:02:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1k61d4-0003LP-LU for bug-gnu-emacs@gnu.org; Wed, 12 Aug 2020 21:02:02 -0400 Resent-From: Stefan Kangas Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Thu, 13 Aug 2020 01:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 41737 X-GNU-PR-Package: emacs Mail-Followup-To: 41737@debbugs.gnu.org, stefan@marxist.se, tom@logand.com Original-Received: via spool by 41737-done@debbugs.gnu.org id=D41737.159728050111860 (code D ref 41737); Thu, 13 Aug 2020 01:02:02 +0000 Original-Received: (at 41737-done) by debbugs.gnu.org; 13 Aug 2020 01:01:41 +0000 Original-Received: from localhost ([127.0.0.1]:46169 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k61ci-00034v-UU for submit@debbugs.gnu.org; Wed, 12 Aug 2020 21:01:41 -0400 Original-Received: from mail-yb1-f193.google.com ([209.85.219.193]:40491) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1k61cf-0002xn-Lx for 41737-done@debbugs.gnu.org; Wed, 12 Aug 2020 21:01:39 -0400 Original-Received: by mail-yb1-f193.google.com with SMTP id q3so2383981ybp.7 for <41737-done@debbugs.gnu.org>; Wed, 12 Aug 2020 18:01:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:in-reply-to:references:user-agent :mime-version:date:message-id:subject:to:cc :content-transfer-encoding; bh=jn/Av0rHSNhRcao60oTJ9eerA2mvUToV6j26zd53Rik=; b=jdbu1rGSK9GR/QVNqEPCwOEtsZC8NnVTa2kN2O8UfUOtHEOm8SkCqjPht4Rl88gE22 cF9zyryRTDnJtuk7sF+iSMu4N+K/hfELOyQdut5pjapMrP2UODdd2cmSeaplsfXoQoES rxbyXKrwjvIs0qRxQsjGiJNTh3BgaV9t6BXWgArDsjCNSmjbUvLBKcXL1EUOf/Nv0T7B Pw5f0TzeZz8Scm0Ukr0BY2xKA4/JRcymEN6NRrkv9sAJyCwtrR5np0wREW/P0JtDD01Y a2KL/iz9VMKXs94aqgx6Bdc10aSBRQNrTx2YGENh5va1AorYlUj+Ni3QhPNpZvREfpXn Inwg== X-Gm-Message-State: AOAM530JRqJPhIxdQCeQtzpIm5bZU2vC+9Fb/NT7OgMY0pk7thQZlOVE Uiuquu+XfgYxc2SITu4XX0fjZaD2z9wt6l9ZC3sJqjJU5P8= X-Google-Smtp-Source: ABdhPJyAN640TC3cNcafhQNo/Fd7g2uc5PA7M+c7uN0WZ9gMBsTxfZLh60LLMO2fIqUTak5eVwV2RFn1YIvU3hl6Iv4= X-Received: by 2002:a25:9843:: with SMTP id k3mr3132399ybo.466.1597280492151; Wed, 12 Aug 2020 18:01:32 -0700 (PDT) Original-Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Wed, 12 Aug 2020 18:01:31 -0700 In-Reply-To: <83eeqs873k.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 06 Jun 2020 19:57:51 +0300") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:184914 Archived-At: Eli Zaretskii writes: >> From: Tomas Hlavaty >> Date: Sat, 06 Jun 2020 14:47:14 +0200 >> >> (window-text-pixel-size) in console seems to be wrong. > > I don't think it's wrong, I think the doc string needs clarification > (which I just did). > >> The width seems to the width of the (visible) window. > > If the text is as wide or wider than the window, then by default this > is what is expected, yes. > >> The height seems to be number of lines in a file. > > On a TTY frame, yes. > >> However, when evaluated in notmuch thread, the cdr of the return >> value is a number which I cannot interpret (it is not number of >> lines in the buffer and it is now height of the visible window). > > I'd need to see an example to respond to that. But maybe using the > new doc string (below) you will be able to understand what happens in > that use case as well. > >> Return the size of the text of WINDOW=E2=80=99s buffer in pixels. WI= NDOW >> must be a live window and defaults to the selected one. The return >> value is a cons of the maximum pixel-width of any text line and the >> maximum pixel-height of all text lines. >> >> I suppose that pixel in console is one character. > > Yes, that is a general rule in TTY frames. > >> the maximum pixel-width of any text line >> >> but this does not seem to be true. I have file with long line but it >> still returns number of visible columns. > > Right, by default text beyond window's width is ignored. It was not > immediately clear from the doc string; I hope it is more clear now. > >> maximum pixel-height of all text lines >> >> It is not clean, what does that mean and the returned number doesn't >> seem to be useful for anything. > > I clarified that as well. That was 9 weeks ago, and, given the lack of updates since, it seems like all issues here are resolved. I'm therefore closing this bug report. Best regards, Stefan Kangas