From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id oFOPCe6SUWPTRAAAbAwnHQ (envelope-from ) for ; Thu, 20 Oct 2022 20:26:54 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id kB+sCO6SUWP6+wAAG6o9tA (envelope-from ) for ; Thu, 20 Oct 2022 20:26:54 +0200 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 B9FBF286D for ; Thu, 20 Oct 2022 20:26:53 +0200 (CEST) Received: from localhost ([::1]:58722 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1olZ9q-00074H-8Z for larch@yhetil.org; Thu, 20 Oct 2022 13:16:41 -0400 Received: from [::1] (helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1olZ95-0006x1-LA for larch@yhetil.org; Thu, 20 Oct 2022 13:15:51 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:52694) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1olZ8k-0006rg-H9 for emacs-orgmode@gnu.org; Thu, 20 Oct 2022 13:15:36 -0400 Received: from mail-lf1-x129.google.com ([2a00:1450:4864:20::129]:38435) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1olZ8i-0007nU-Oi for emacs-orgmode@gnu.org; Thu, 20 Oct 2022 13:15:30 -0400 Received: by mail-lf1-x129.google.com with SMTP id g7so506153lfv.5 for ; Thu, 20 Oct 2022 10:15:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:in-reply-to:cc:to:from:references :content-language:subject:user-agent:mime-version:date:message-id :sender:from:to:cc:subject:date:message-id:reply-to; bh=ZPOv5/WUm08IqaNs/TWbqMahVSHfO6HZGZ/CLghnbww=; b=JfwDtmi8ZcD9codVK4VwFixJV/zzg6eRy+Qx4yruic22vamssgRP27lRz+K2YW158u naAxNOW5Gtbrm+MR00+FaHiZiktkTgFJGr1+Uszr/pUZAJ+Ncm9m9cQhEIQUKfEFKd/Y THi5KWsgRk38I2cSU5lTSvJrvwwif073MvP4oVTVzR27rRZte43sGLmQ4QqThmPOkZOe NIKs+UWg+o0A3zn9RKAIzrtiVeSpfLH3eR4Ic7PL/UFJdlBNCyzPd0nhtbxj+Xk62xCP 9YxBlbHXUl92SNN6VF6GudpMlfi/ZNO2po6iFpI0YJ91++zqiBA86Sz9MviaEpcc9/UR VutQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:cc:to:from:references :content-language:subject:user-agent:mime-version:date:message-id :sender:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ZPOv5/WUm08IqaNs/TWbqMahVSHfO6HZGZ/CLghnbww=; b=SVN8RPsF/7Mh3vDCDwg6GA9zf1/m+JWR3as1gxs9xYmIri/9PELtOOwNMJNX5ZoslZ kwcR6Ym+95gwG/9DxKL/L0cI0aZpx4iJfdkrQqRit1zlBC45Vfs6O0yPYfYAO0IjbrkE 33890RyXxFtt7jZ9O4OzC3eRMIiMCyUC+lRSkmdu+LHSGGiKAkZvWHsGX+/LtGyJVCA4 4sOGyyAZhvGqQph4jy+R1dc1xu2mrr3m0ww03EbKTLVFSwUnBmVm8NcCzCyAMfvA/Ilp 1TcHcnViMZsaDFX6y+wb16JboaHED3xv4X6C4RYNWSJ99vqM4vpe1URuJFpzHBdr2POj /PnA== X-Gm-Message-State: ACrzQf1qYsFuhyLkb8mOmgjVkx1kDaMq/LnIoiBxxHHGmfh/zY4GcAtG mQSYyiWfY/BmPYByz5sjNFM1BnZDilw= X-Google-Smtp-Source: AMsMyM68Nm1FVMgs94FhG8q6+pRV9VliIRiPRLXNtg8sFm7eJx64qI7OypIXDH6J+yZSe38I6fIHGg== X-Received: by 2002:a05:6512:139c:b0:48f:da64:d050 with SMTP id p28-20020a056512139c00b0048fda64d050mr4766432lfa.268.1666286126521; Thu, 20 Oct 2022 10:15:26 -0700 (PDT) Received: from [192.168.0.101] (nat-0-0.nsk.sibset.net. [5.44.169.188]) by smtp.googlemail.com with ESMTPSA id c14-20020a056512074e00b00492dfcc0e58sm2803610lfs.53.2022.10.20.10.15.25 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 20 Oct 2022 10:15:25 -0700 (PDT) Message-ID: <85e80572-33c6-aff5-2654-4f8de5fa143c@gmail.com> Date: Fri, 21 Oct 2022 00:15:24 +0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.2 Subject: Re: Line breaks and brackets in LaTeX export Content-Language: en-US References: <875ygk6a8z.fsf@posteo.net> <87a65vitbz.fsf_-_@posteo.net> <87edv6izx4.fsf@localhost> <8735bmelgu.fsf@posteo.net> <878rlecx49.fsf@posteo.net> <87h701hhjp.fsf@localhost> <875ygf9j6u.fsf@localhost> From: Max Nikulin To: Org Mode List Cc: =?UTF-8?Q?Juan_Manuel_Mac=c3=adas?= In-Reply-To: <875ygf9j6u.fsf@localhost> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Received-SPF: pass client-ip=2a00:1450:4864:20::129; envelope-from=manikulin@gmail.com; helo=mail-lf1-x129.google.com 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, NICE_REPLY_A=-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-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" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1666290414; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=ZPOv5/WUm08IqaNs/TWbqMahVSHfO6HZGZ/CLghnbww=; b=CXezdp/KvXiHepo/31ThcJYn/+U+byrsv9QzuvJgaeZZsx2VgBb/O2YOHwNo+VdGfM7pLc MmB/5yBtHqI0osHlDdr7zMNIefYMq0wCq3D0V9efZMOKt3Zd9tCRcgGgWuFImkj4p13+yh krJfUk3m4hJpLfIRg8hvqUQQu1SGq6xIQG4k6FI5shTluj8XEkVt61i7SG4jZqOr77e5F6 iesJoWmbqvjkzsuc4GhiRN2qh6pyg1Oi7FXc6CsO5y7gy85Lan6UIT6xAiYlxi3JgZFdt4 7w1tE67jsPdbpPHadnPlz9lqUoNrlNig57gZqZMxma8x3lZJM56RLPLEwGHECQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666290414; a=rsa-sha256; cv=none; b=C0Tmh5oR4r7XQqhRqaBDWZn5H6cc6hiu8/c4yFWDDqLJANA+0WOqXz/MHn7TxzdXy4C2eJ 65JxiTPn1fSp+VM+nvctotOCrbwBeHfSq+WiKa/AfNdWzDJH0xVo16ufnzqvTV1gwXVEN0 84DN1cw9c85JmfVcapmCDg4ZZX1gm3QamIooLqnQL2+lKoouixCHQnoomAFY2JuMnKR6Pt ni4D+yCJETnfpFYWYLxJq7JQj27qcYCpOWKSUEjyjo4iz37tQiNdz5ZEwghRDb8TD0yAKc sHI8gvwI+Oki+M52weKbQyZwi3Gh+SzF91r3w3QQA7m/iumT573O1KpSxFgpAQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=JfwDtmi8; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); 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" X-Migadu-Spam-Score: 6.27 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20210112 header.b=JfwDtmi8; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none); 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" X-Migadu-Queue-Id: B9FBF286D X-Spam-Score: 6.27 X-Migadu-Scanner: scn1.migadu.com X-TUID: 0coDFHIe9qY0 An argument in favor of \\[0pt] escaping. Unlike \empty, [0pt] is rather artificial, so such pattern may be removed (I hope in a safe way) by an export filter if it is not followed by a bracket or a star. On 20/10/2022 12:07, Ihor Radchenko wrote: > When transcoding children (e.g. table rows), the sibling rows can always > be accessed using org-export-get-previous-element and > org-export-get-next-element. Decision if escaping is necessary should be based on export result, not on the source element. > Max Nikulin writes: >> As another approach text properties may be used as a communication >> channel unless they are stripped by ox. > > I am not sure what you are referring to. If modifying exported string, > it will suffer from the same problems as your idea with comment. It is a brain storm idea, I still unsure it is feasible. I mean info "(elisp) Text Properties". I do not think they are usually ignored by filters. \\ substrings added by ox-latex may have some unique property. Export filter searches for occurrences of \\ to check if escaping is necessary, but it ignores particular location if the text does not have the specific property. I would prefer to mark output of export snippets with another property value and do not escape them. It is a kind of out of band communication. Unsure if text properties may be lost due to string operations in an exporter or vice versa to propagate to the source buffer.