From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Yuan Fu Newsgroups: gmane.emacs.devel Subject: Re: Support paragraph-local tab stops Date: Wed, 27 May 2020 12:51:06 -0400 Message-ID: References: <83a71ttn0b.fsf@gnu.org> <83v9khs5s4.fsf@gnu.org> Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.80.23.2.2\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="88571"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed May 27 18:51:44 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 1jdzHM-000Mwy-EV for ged-emacs-devel@m.gmane-mx.org; Wed, 27 May 2020 18:51:44 +0200 Original-Received: from localhost ([::1]:55734 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jdzHL-0002fk-Gu for ged-emacs-devel@m.gmane-mx.org; Wed, 27 May 2020 12:51:43 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:33410) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jdzGo-0001zo-HA for emacs-devel@gnu.org; Wed, 27 May 2020 12:51:10 -0400 Original-Received: from mail-qk1-x731.google.com ([2607:f8b0:4864:20::731]:34175) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jdzGn-0002rq-JD; Wed, 27 May 2020 12:51:10 -0400 Original-Received: by mail-qk1-x731.google.com with SMTP id f18so155164qkh.1; Wed, 27 May 2020 09:51:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=SWtNZxdRdPnyUbCsHXNyt+VJ768IgKU6bJiW/o7IKBI=; b=Sj2Gb/5nW00LKfmpgrzK/v+tYw3uZB25Lk/5xnnT+HvzjigzwZHF1eE9lzgyBTvcWE FvnHEyfgDcT02z4kTO6nE12cyeo7rXNbdXzQncmNGbUZGlXkcA0tLmh8SiOHyV9Wrw9f +8+TbcHjjWqhdwbL9Zq4zHSNEZxeVzFvG3YNYW2Xa+OChD+tbAjOkQSD3bBP0ahaHW0q rBlV/jHQHjvJzKhbwVc29Y/3Xit/qlOkROapI7O/fAX5AU2SWIRLIqHoo7IShZaAzr36 N4Kq9uglqwqKgH94XKoG47uFYex8F7mpTEfTzha0M6SlUXyfdjt2gCcbutFsaqvhMqe3 9Z2A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=SWtNZxdRdPnyUbCsHXNyt+VJ768IgKU6bJiW/o7IKBI=; b=rtC1rHYkhUbjQpNg+VdYqz1QAoFQZEBKvygEXPfZM/SYG+doiLeBpiDrhGhE1IIld+ XCO5MapaZXF8uM7arnoKupCxwTGAdfnGkv5SbxGYfrJVlFlpN9NL2sFSww68+BaUzXng oR9iqcwWcUAvA4CnawbijRzw32ZgRgbjq739vHf9hpw2Hmz3pB/8IDji8h++Hn23/Y86 pNGe3z/U14JtM0iJ0QxESSAYlxOzI1gp0GWcvtNQNuqGe2l0T31HTEGU173BZun0oXK2 nvLqsLhsoLVW9K+r0JqxuvNVDDuDOtNp04Kw0mdX/+V04jpM4o2mH1ErIvr37d9bZn3k m88Q== X-Gm-Message-State: AOAM533D0ot2cAKiQyTv551roV6HjLwF6apv91g3CE37RRcFnVZ5iq7u nPz9fRf93xeCO9ia26kwGhp7IwqtNMX63g== X-Google-Smtp-Source: ABdhPJxRlbNIhvTHduLO6HXBR/3No6En7tINiI3k3QMGMK0EyaxUSOJuJbTDOxE7tjJZkIyptH+Icw== X-Received: by 2002:a05:620a:9db:: with SMTP id y27mr5095388qky.440.1590598268079; Wed, 27 May 2020 09:51:08 -0700 (PDT) Original-Received: from [192.168.1.10] (c-174-60-229-153.hsd1.pa.comcast.net. [174.60.229.153]) by smtp.gmail.com with ESMTPSA id k138sm2675085qke.55.2020.05.27.09.51.07 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 May 2020 09:51:07 -0700 (PDT) In-Reply-To: <83v9khs5s4.fsf@gnu.org> X-Mailer: Apple Mail (2.3608.80.23.2.2) Received-SPF: pass client-ip=2607:f8b0:4864:20::731; envelope-from=casouri@gmail.com; helo=mail-qk1-x731.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:251511 Archived-At: > On May 27, 2020, at 12:26 PM, Eli Zaretskii wrote: >=20 >> From: Yuan Fu >> Date: Wed, 27 May 2020 11:48:35 -0400 >> Cc: emacs-devel >>=20 >>> IMO, TAB stops are not the right tool for the job here. You need to >>> use the :align-to display property, which allows to align text with >>> pixel granularity. >>=20 >> I think both approach are equally appropriate. And the tab-based one = aligns more closely to word processors. If we want to gradually add = WYSIWYG editor features, and enable Emacs to edit rich text, this is an = unavoidable feature. >=20 > TABs in Emacs use columns, so their resolution is more coarse. > Therefore, they fit this job less well, because they cannot handle > variable-pitch fonts. >=20 >> I just wrote a (very rough) proof-of-concept patch=E2=80=94it=E2=80=99s= much easier than I thought. With the patch you can do something like >>=20 >> (put-text-property (region-beginning) (region-end) >> 'pixel-tab-stop-list '(70 140 210 280 350 420)) >=20 > This is not TAB stops, this is a new text property that does the same > job as :align-to. Why invent a new property when we already have an > existing one that does the same? I just thought this is how TAB should work, you know, like word = processors. But of course, if this is not reasonable, I can use = :align-to.=20 Yuan