From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?B?Sm/Do28gVMOhdm9yYQ==?= Newsgroups: gmane.emacs.devel Subject: Re: feature/icomplete-vertical Date: Mon, 5 Oct 2020 12:58:07 +0100 Message-ID: References: <20200912133311.6ujtgczj6wyclufy@Ergus> <20200920130435.heye7bk73pm252km@Ergus> <83sgbczj0i.fsf@gnu.org> <83lfh4zfml.fsf@gnu.org> <838sd4z6lz.fsf@gnu.org> <20201001164804.mqqyxtet4ttweuyv@Ergus> <83blhhdy3w.fsf@gnu.org> <87d01xghmt.fsf@gmail.com> <83sgatc8er.fsf@gnu.org> <83mu11c78j.fsf@gnu.org> <87tuv9eygk.fsf@gmail.com> <87imbogb6k.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000d1c2e505b0eb32b5" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17496"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii , Juri Linkov , Ergus , Yuan Fu , emacs-devel To: Gregory Heytings Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Oct 05 13:59:03 2020 Return-path: Envelope-to: ged-emacs-devel@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 1kPP8x-0004R2-KH for ged-emacs-devel@m.gmane-mx.org; Mon, 05 Oct 2020 13:59:03 +0200 Original-Received: from localhost ([::1]:43844 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kPP8w-0001mv-NH for ged-emacs-devel@m.gmane-mx.org; Mon, 05 Oct 2020 07:59:02 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:55018) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kPP8K-0001LW-Fz for emacs-devel@gnu.org; Mon, 05 Oct 2020 07:58:24 -0400 Original-Received: from mail-io1-xd2e.google.com ([2607:f8b0:4864:20::d2e]:37479) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kPP8H-0001ml-Oa; Mon, 05 Oct 2020 07:58:24 -0400 Original-Received: by mail-io1-xd2e.google.com with SMTP id y13so8796276iow.4; Mon, 05 Oct 2020 04:58:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=kYINIbvlic95WVHI8HOx0/UZ+AGcu1Q+7NMK/jfUR6E=; b=XQEs4nT+0WNYP0gZwP+6yd8RRPvMq5S5IY4nacUwbZEUpbsqFCX/PAYAQwAahH7i7w idIIhjwMdWDwIH9tBjVrAKqXjFDQrGx2zyriRad8oHzbok2jpmsY8HcBH4UeJ2rD9miv wc1IExXheI1p7BDPSOxFCLMfo08b/OOJpMetl+8LJZ20c70bgwx7wEhPPXeQDMsZGCsu WV2MrY2XelqT/vVbsn9eYnHMurUgLy0YdN6ya+vFubxrNcKoICCCTPeUSaqrVYmptIIF JQZCBCDmOozSCFFPo4mK4kJ2f0slWigZyn5vmWy0oYf4fMRwUtJG4jJ49OYv/OlnhLIa bCKA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=kYINIbvlic95WVHI8HOx0/UZ+AGcu1Q+7NMK/jfUR6E=; b=pC1C7HgUjm0m48n7cVjCNK9sLWamB93JtRH8BlTVwpTldFhzGsV3sLuU1AR5u/Xl51 v1rDCPgl4HmufWaaiO05jA0J5cHNYRhrFm2nYEaJfGMXPpLa6T2NADei8IULUy+te4qi Fh+aNAq32CDnu7pJkubUMl/7YBQegh7E+l0v+NYMmwDltVoMYCTCbYvOJdsiLUyTwj5i q+Yi9vMBDsFhJhJ1KJDz/ynBikpaHQCpHcIl5rZmr8SwkvyYddmcNPP402UBIiSLosUS 1BrG/GBe04wZ4uOQ2kNjp40prSMi6ZcxwwQgVcCMojeqrjz4xbKTWBbDCktq4EHTxhrJ kNYg== X-Gm-Message-State: AOAM53310geo7oWR5i4rO0KomcskKx1EHPyA5qLUn4JduBKoBWY6FW42 hnSmujguNQd+Asixl3pcVWxmVr4jT5H94RSkiAE= X-Google-Smtp-Source: ABdhPJwRUf0oS+zXcIA8MneIz1BbfjeB1wJgnvKNm6msh0nYWN/47LNASLILZqrSIGwQPNbRg1cWUW6Ey2L/t+eBwi4= X-Received: by 2002:a02:6952:: with SMTP id e79mr12657732jac.24.1601899099962; Mon, 05 Oct 2020 04:58:19 -0700 (PDT) In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::d2e; envelope-from=joaotavora@gmail.com; helo=mail-io1-xd2e.google.com X-detected-operating-system: by eggs.gnu.org: No matching host in p0f cache. That's all we know. X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:257114 Archived-At: --000000000000d1c2e505b0eb32b5 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Mon, Oct 5, 2020 at 12:54 PM Gregory Heytings wrote: > > >> This is feasible, but IMHO very (and needlessly) difficult. Basically > >> you need to work with pixel dimensions, and recalculate everything > >> manually: first calculate the (maximal) size of the miniwindow (given > >> the user preferences, in particular max-mini-window-height), then > >> calculate the size of its contents with window-text-pixel-size. You > >> should add one character (or line) at at time, and recalculate the new > >> size each time. > > > > Yes, as far as I understand, in the general case, it must be one > > character at a time, since each character might have a different pixel > > width. At some point there is a cutoff and things are not displayed > > anymore. I was hoping that that knowledge, which is held somehere in > > the system at some point, could be imparted to the application. > > > > Anyway, whatever the mechanism (notification or painstaking > > calculation), we should first write a function that does this. That is > > the bugfix in my opinion. Then we can work on simplifying that > > function's implementation, if it turns out to be slow or problematic. > > > > There is no need to calculate anything with the > "start-display-at-beginning-of-minibuffer" solution I sent a few hours > ago. Emacs does everything for you, at no cost. > > Or is there something that you need (e.g. for Eldoc) and that this > solution does not do? I suppose not, but I take it that that solution is a non-starter because of Eli's and Stefan's objections to it. Maybe you somehow placate those objections. Jo=C3=A3o --000000000000d1c2e505b0eb32b5 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
On Mon, Oct 5, 2020 at 12:54 PM Gregory Heytings <ghe@sdf.org> wrote:
>
> >&g= t; This is feasible, but IMHO very (and needlessly) difficult.=C2=A0 Basica= lly
> >> you need to work with pixel dimensions, and recalculat= e everything
> >> manually: first calculate the (maximal) size = of the miniwindow (given
> >> the user preferences, in particul= ar max-mini-window-height), then
> >> calculate the size of its= contents with window-text-pixel-size.=C2=A0 You
> >> should ad= d one character (or line) at at time, and recalculate the new
> >&= gt; size each time.
> >
> > Yes, as far as I understand, = in the general case, it must be one
> > character at a time, since= each character might have a different pixel
> > width.=C2=A0 At s= ome point there is a cutoff and things are not displayed
> > anymo= re.=C2=A0 I was hoping that that knowledge, which is held somehere in
&g= t; > the system at some point, could be imparted to the application.
= > >
> > Anyway, whatever the mechanism (notification or pain= staking
> > calculation), we should first write a function that do= es this.=C2=A0 That is
> > the bugfix in my opinion.=C2=A0 Then we= can work on simplifying that
> > function's implementation, i= f it turns out to be slow or problematic.
> >
>
> Ther= e is no need to calculate anything with the
> "start-display-at-= beginning-of-minibuffer" solution I sent a few hours
> ago.=C2= =A0 Emacs does everything for you, at no cost.
>
> Or is there = something that you need (e.g. for Eldoc) and that this
> solutio= n does not do?

I suppose not, but I take it that t= hat solution is a non-starter
because of Eli's and Stefa= n's objections to it. Maybe you
somehow placate those ob= jections.

Jo=C3=A3o
--000000000000d1c2e505b0eb32b5--