From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Pip Cet Newsgroups: gmane.emacs.devel Subject: Re: Ligatures Date: Sat, 23 May 2020 14:37:18 +0000 Message-ID: References: <20200517165953.000044d2@web.de> <83mu6481v3.fsf@gnu.org> <75a90563-51b4-d3b8-4832-fc0e2542af0d@gmail.com> <83blmi7hys.fsf@gnu.org> <837dx55qff.fsf@gnu.org> <834ks95cmz.fsf@gnu.org> <4faa291f-f2df-36d1-73d5-332b93a9b6d8@gmail.com> <83wo544hx5.fsf@gnu.org> <831rnc43ih.fsf@gnu.org> <83ftbs2jr5.fsf@gnu.org> <83lflj16jn.fsf@gnu.org> <83eerb145r.fsf@gnu.org> <831rnb0zld.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="123951"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Eli Zaretskii , emacs-devel@gnu.org, cpitclaudel@gmail.com, alan@idiocy.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 23 16:38:42 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 1jcVIQ-000WAm-81 for ged-emacs-devel@m.gmane-mx.org; Sat, 23 May 2020 16:38:42 +0200 Original-Received: from localhost ([::1]:55194 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jcVIP-0008Pz-Ai for ged-emacs-devel@m.gmane-mx.org; Sat, 23 May 2020 10:38:41 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33932) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jcVHg-0007yK-Rh for emacs-devel@gnu.org; Sat, 23 May 2020 10:37:56 -0400 Original-Received: from mail-oi1-x231.google.com ([2607:f8b0:4864:20::231]:40840) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jcVHg-0001Jv-3o; Sat, 23 May 2020 10:37:56 -0400 Original-Received: by mail-oi1-x231.google.com with SMTP id v128so11909239oia.7; Sat, 23 May 2020 07:37:55 -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=UKXT+xq+ka8+nESJ10asEUgNP8BtRTLeAPw/A9e6BV4=; b=PRTTa1qNKIy1uc0mK4AfOU/nZF+xPsFJUWkBBrfZjHsKKhJAW+N5zokeThQUbBzjFb lvF0sS64XpKE49uC1HCBsfFcKHavTtY8rYnZtfSlq7nrw3rNuk+a5cTEhywIXlOXi7fE N0hXU5RT9nchcgcDzNRhZoipotx1eqnIfDsKQt2Jy3jI/I+9vySi76orYFzZKw3VoaWG 7VXxUZW4AFLM4I5Vh3MUJIHy7jAxSfg1SsIeEAXb/g2u3mibKM2GujNsx0Dzk0bq2Sht 4fsmWtWsd61FP6ft79/QyOvmU88EyYzEAPA3tUyA6k0Y9iHKtUNFGG1FZ7TP0uZElU9P GuaQ== 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=UKXT+xq+ka8+nESJ10asEUgNP8BtRTLeAPw/A9e6BV4=; b=glL9uKp5sLkMu6/rNCclLapQ6SqmZkOC0zHXqv4Yz2KJ8sMGt7AYohZsZ88mschP2a qgsTUY1ocUZXQFnpR2Xepq+C6L/FM+7jvdaguDwdBOUSx+NLp7vMNL9m5rXmesN2Hsbs qYY4+56dCh3fFPhSidh9wNUEKqEWsAIxeK4WECpVx1coERpjdtS2pC6x9rqdEEGdJ0Hq LUYdCycWfI7m5y8cForN/7RL4oxihkC4YUVck5BORHhVn5hwgAXVP5ED27YH6PPk8wX7 oSbJrdueHsvUbEvJ/cdtUssY4vPQKyu7VzF1XI+OUtE5UTOvNOAjv58RwdD5Ylrxgatw LnPQ== X-Gm-Message-State: AOAM533BS2ZF5sJknBiAl2sorMy7dUjv41M2T6gNCSmqHHNM755duviK QN5zu6MMDE7EyQeXvPonZlIPXp7CKfO1UhK8zyI= X-Google-Smtp-Source: ABdhPJzT6mVOuvYfbqwbivGdIMSZkKAtRBAwaMuEsOxbsamYRwBtmQ3YcAIpdG07AayL6SR+f4LZzGVeKc66HiS7rE0= X-Received: by 2002:aca:b708:: with SMTP id h8mr4572238oif.122.1590244674728; Sat, 23 May 2020 07:37:54 -0700 (PDT) In-Reply-To: Received-SPF: pass client-ip=2607:f8b0:4864:20::231; envelope-from=pipcet@gmail.com; helo=mail-oi1-x231.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, RCVD_IN_DNSWL_NONE=-0.0001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN 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:251278 Archived-At: On Sat, May 23, 2020 at 12:48 PM Stefan Monnier wrote: > > The crucial problem is that we currently perform layout decisions one > > grapheme cluster at a time, whereas what HarfBuzz people say is that > > we should basically do that one screen line at a time. > > I wonder how it is supposed to work and it works in other applications: That's why I'd like us to use a more advanced internal API rather than the limited HarfBuzz API, one that asynchronously requests information about preceding/following codepoints, incrementally informing us of the minimum width already reached, until it can reach a decision. It should be easy enough to put in some heuristics that work in practice until a better shaper comes along... > Do current applications use a heuristic like "ligatures won't reduce the > size by more than a factor 2, so estimate the lower bound on the final > size to be at most half of what the font metrics say", so they will send > up to twice as much text to be shaped as needed, and then they throw > away the left overs? I don't know.