From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id QGWNLHmh0GX/RgAAe85BDQ:P1 (envelope-from ) for ; Sat, 17 Feb 2024 13:07:21 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id QGWNLHmh0GX/RgAAe85BDQ (envelope-from ) for ; Sat, 17 Feb 2024 13:07:21 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=aaHquump; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1708171641; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=NS0OFmgomSw0ORGu3D0nV/pUce382JY2aSPo+7oOOp8=; b=ihNgYejxWhsG/qrc4LNPgtjBT6wgHfL9AXgtLKuQ6DODR+uzp4YO0LGsnphf+7xyORlRsS GMhxhD01HcwqFV1U5P7Kz9+oeN1bq1IOvORwwpx08/ofMCmvzetHHGqLCxNsvClN7WJDOD 8rBGPMf6thA+lBc8qpZpCilnJwEDhoMBeXl5Jmu8IoEEm4sF5TqL43bHrm9VqxOqSinK+O eMUeh9PWwWFxzpOPinIFRXJ6dq1ybvMjk9SOpT1Uio/5d9vzppcxmfIljaacY4mncc/uea 3BLAAp30fiSyGALtOfqPMz4E4CqHSsDLsjj2y23wGlMZSwH0IUmkJ5YN2Lummg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=aaHquump; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=posteo.net ARC-Seal: i=1; s=key1; d=yhetil.org; t=1708171641; a=rsa-sha256; cv=none; b=E7rwdekVdJHRdjg0lyvWR+BpfQoc57HaLFzzRyNiydCrlUGuDqnAV9chUKHUMqaPX7Ppgs g8/8kNv9ahetzKIkupEdS4KsLVVHP1ZvcDeSr12d+Lf3t+Ae/FmnHnL/JWbUZnN0GtXium VF6aFAo22iXV5vRAQruqH0+2xSBedVIPaoXJgcMy1zBTvyrXb8+AsWKxTslayalFBsvpny Y6iu/kLFiQpOT8P0rc8p+x5agAGJGXwFPANfVlUtzyC0q0mLEQaMyadWe7s5fxhHF7oHgG bPkAAOc1NU9jIHRrvkhWGje72mFf/+2FvhAKX8vW5FPSVRH/3UVYITgMmmYjAA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 632E16234F for ; Sat, 17 Feb 2024 13:07:21 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rbJSf-0000rQ-8x; Sat, 17 Feb 2024 07:06:29 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rbJSZ-0000pu-RC for emacs-orgmode@gnu.org; Sat, 17 Feb 2024 07:06:24 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rbJSX-0002HM-KD for emacs-orgmode@gnu.org; Sat, 17 Feb 2024 07:06:23 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 23A88240105 for ; Sat, 17 Feb 2024 13:06:18 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1708171579; bh=I6GYmX496WUpYip6zzN4ER4W+Cqv7KOkKVIXAv9O848=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=aaHquumpljFiZcp+4cfsRoF2K5aVxJq2PZQdBwlcDso6ij9TjjmGKRHorqOOkeeL/ ObHooN4ovfC98VlovF9zUKoHSFBUsiqx6h0IkaW7y+YEo4ztKFjl5vQ0u7qMtXe9U+ 1KQwrBiIgL4waBlVZK7yaV+pEWs1BsqCbDUY3tgIx6beZl0MeEgZkepICtFIyqqTF1 r/mC9umwz8yW8koMA0ZqAmp1blchGdA/5M1LuBpfa0zq8osphx/DHhKk34ScSzUcAe J2yjudPcs3yHNnZE3RYRONNPVTDNaeVL/Iw0ExNmhUuVPj5CP3fEmpeZNdOg/dHfjG 9gSFO9baSm3yg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4TcSFP6hnRz6tm8; Sat, 17 Feb 2024 13:06:17 +0100 (CET) From: Ihor Radchenko To: Tom Alexander Cc: emacs-orgmode@gnu.org Subject: [DISCUSSION] What should we do with undocumented x^(superscript inside /round/ braces) syntax? (was: Subscript with parenthesis) In-Reply-To: <875y42zi1n.fsf@localhost> References: <3cb9366e-7915-481d-be74-1953a8dd5847@app.fastmail.com> <875y42zi1n.fsf@localhost> Date: Sat, 17 Feb 2024 14:06:32 +0000 Message-ID: <87wmr3xk0n.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=yantar92@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Scanner: mx12.migadu.com X-Migadu-Spam-Score: -8.65 X-Spam-Score: -8.65 X-Migadu-Queue-Id: 632E16234F X-TUID: cMVeUN1gd+KJ Ihor Radchenko writes: > "Tom Alexander" writes: > >> Some additional things I'm noticing: >> >> - when using parenthesis, :use-brackets-p is nil, so they're not equivalent to curly braces. > > `org-element-subscript-parser' uses `org-match-substring-regexp', which > indeed allows foo_(...). This is not documented in org-syntax.org and in > the manual (12.3 Subscripts and Superscripts). Inconsistent with LaTeX syntax, Org mode not only allows x^{superscript}, but also x^(superscript) with round braces used for grouping. This does not seem to be documented in the manual and is only vaguely mentioned in the `org-use-sub-superscripts' docstring in a single example: x_{i^2} or x^(2-i) braces or parenthesis do grouping. The rest of the docstring only refers to {} or just to genetic "braces". This situation is awkward, because such subtle inconsistency between Org and LaTeX syntax can be very surprising. To demonstrate, try to export the following to pdf: # --- Direct latex code =$foo^(bar)$= :: @@latex:$foo^(bar)$@@ Org mode markup =foo^(bar)= :: foo^(bar) # --- The first line will only create superscript for "(", while the second line will make the whole "(bar)" into superscript. ----- I tentatively propose to remove the x^(2-i) example from the docstring and mark the ^(...) syntax deprecated. WDYT? -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at