From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: "Herring, Davis" Newsgroups: gmane.emacs.devel Subject: Re: Variable-width font indentation Date: Tue, 6 Mar 2018 14:18:29 +0000 Message-ID: References: <87inaiss6l.fsf@web.de> <6FCF6ACA-4F29-4B6B-BE9D-D7130C6E9495@gnu.org> <87fu5moe4c.fsf@web.de> <877eqyocro.fsf@web.de> <83zi3uz4nb.fsf@gnu.org> <0b1dd3fa-e0b0-ed20-a256-dd92d1c1826f@dancol.org> <8bc3c4c7-dfc7-987a-95e7-bd309e2326c6@cs.ucla.edu> <03118DC0-39DA-4AB5-980E-A33809B9A5EE@raeburn.org> <83vaeas8uz.fsf@gnu.org> <83lgf6s3aa.fsf@gnu.org> <64ad488a4aa74c37b9711bf89d1d8abb@lanl.gov>, NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1520345925 6414 195.159.176.226 (6 Mar 2018 14:18:45 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 6 Mar 2018 14:18:45 +0000 (UTC) Cc: Paul Eggert To: =?iso-8859-1?Q?Cl=E9ment_Pit-Claudel?= , "emacs-devel@gnu.org" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Mar 06 15:18:40 2018 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1etDQE-0008CZ-2X for ged-emacs-devel@m.gmane.org; Tue, 06 Mar 2018 15:18:30 +0100 Original-Received: from localhost ([::1]:56107 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1etDSG-0002Wi-Mx for ged-emacs-devel@m.gmane.org; Tue, 06 Mar 2018 09:20:36 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33169) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1etDRJ-0002S6-7k for emacs-devel@gnu.org; Tue, 06 Mar 2018 09:19:42 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1etDRF-0005vq-VW for emacs-devel@gnu.org; Tue, 06 Mar 2018 09:19:37 -0500 Original-Received: from proofpoint7.lanl.gov ([204.121.3.46]:36756) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1etDRF-0005vH-Ne for emacs-devel@gnu.org; Tue, 06 Mar 2018 09:19:33 -0500 Original-Received: from pps.filterd (proofpoint7.lanl.gov [127.0.0.1]) by proofpoint7.lanl.gov (8.16.0.21/8.16.0.21) with SMTP id w26EGkfH182066; Tue, 6 Mar 2018 07:18:29 -0700 Original-Received: from mailrelay1.lanl.gov (mailrelay1.lanl.gov [128.165.4.101]) by proofpoint7.lanl.gov with ESMTP id 2gftydphb6-1; Tue, 06 Mar 2018 07:18:29 -0700 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by mailrelay1.lanl.gov (Postfix) with ESMTP id 806F413D2292; Tue, 6 Mar 2018 07:18:29 -0700 (MST) X-NIE-2-Virus-Scanner: amavisd-new at mailrelay1.lanl.gov Original-Received: from EXG16-P-MBX03.win.lanl.gov (exg16-p-mbx03.win.lanl.gov [128.165.106.183]) by mailrelay1.lanl.gov (Postfix) with ESMTP id 6A0E713D2289; Tue, 6 Mar 2018 07:18:29 -0700 (MST) Original-Received: from EXG16-P-MBX03.win.lanl.gov (128.165.106.183) by EXG16-P-MBX03.win.lanl.gov (128.165.106.183) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.1415.2; Tue, 6 Mar 2018 07:18:29 -0700 Original-Received: from EXG16-P-MBX03.win.lanl.gov ([fe80::c837:e407:296a:c173]) by EXG16-P-MBX03.win.lanl.gov ([fe80::c837:e407:296a:c173%2]) with mapi id 15.01.1415.002; Tue, 6 Mar 2018 07:18:29 -0700 Thread-Topic: Variable-width font indentation Thread-Index: AQHTtMCarybDDX1nBU2EqFCt7t9t9aPCbIL+gAE+vAD//5L8IQ== In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [128.165.106.201] X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2018-03-06_08:, , signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=896 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1711220000 definitions=main-1803060161 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] [fuzzy] X-Received-From: 204.121.3.46 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:223326 Archived-At: > match opt with > | [] -> [] > | x :: t -> x :: f t >=20 > You'd want to scale the spaces according to the line *below*, not ebove, As per your other message, that's a problem regardless of tab handling. Ye= t more heuristics suggest themselves (in this case, looking for text shared= between two adjacent lines to guide the alignment), but of course those ar= e becoming a mess. > and even then you'd have to account for the fact that 'x ' isn't as wide = as '[]'. Maybe I misunderstand -- how is this a problem? If the number of spaces is= correct, it identifies the correct character to match against. > Smart Tabs are also not very good for languages like ELisp with variable = indentation depths. Which cases are hard? I just see several places where you would use only s= paces (_): (progn >-(foo) >-(bar)) (and _(foo) _(bar)) (and (foo) _____(bar)) > If anything, I think this is more of an argument in favor of > elastic tabs (http://nickgravgaard.com/elastic-tabstops/). Those are certainly interesting, but they have their own ambiguities (e.g., int>-x>-=3D 1, >-y>-=3D2; doTheFoo();>-// it's true doTheBar();>-// so far where there should not be a "column block" 4 lines tall). They also of cou= rse do not play well with existing rendering (monospace or otherwise). Davis=