From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id KOwtJ/qqw153WwAA0tVLHw (envelope-from ) for ; Tue, 19 May 2020 09:46:34 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id gMToIvqqw17sbAAAbx9fmQ (envelope-from ) for ; Tue, 19 May 2020 09:46:34 +0000 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 42369940712 for ; Tue, 19 May 2020 09:46:34 +0000 (UTC) Received: from localhost ([::1]:42890 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jaypV-000650-8L for larch@yhetil.org; Tue, 19 May 2020 05:46:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33528) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jayoq-00062g-EE for emacs-orgmode@gnu.org; Tue, 19 May 2020 05:45:52 -0400 Received: from mail-pl1-x62b.google.com ([2607:f8b0:4864:20::62b]:42783) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jayop-00015J-3H for emacs-orgmode@gnu.org; Tue, 19 May 2020 05:45:52 -0400 Received: by mail-pl1-x62b.google.com with SMTP id k19so5383816pll.9 for ; Tue, 19 May 2020 02:45:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:message-id:in-reply-to:references:subject :mime-version; bh=PsywpoxoXuyjIKOqg2SB61nc89mBPI1ephP7vFhH5RI=; b=Td+W4y5PqB/n+L4Q8mOCNE7ryOwpxTM7Gpt/UQn0XouiMlgvmcfpROsXWtHThePeRZ 12pvDAOv2KazDadCr5IvjkDfpsTqRqgJUgLXxISBPz/ucTYEYi777yuka6NuCp4qW53C 7UA4qITdL6CBo6SaXz+pMLFaWWa5gYDoQWcGpSx/SZJq2X0MX00vKwKriV+b395ysrJj LO2M8UvmW041WQdPkbtyRQXKYeSCvShO3XKtKDAUVYi4T4jvy5NiwPbuwaLJEof7Mivz DE7JFXy+6llDFbFMlYyYjYT3PoPXpmYxDh4nMJq160f/WeFVaWsOSJy/+3tukR/HV0+E cGhQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:message-id:in-reply-to :references:subject:mime-version; bh=PsywpoxoXuyjIKOqg2SB61nc89mBPI1ephP7vFhH5RI=; b=hBUG8oACJlxOxiFlmkZpUQtTwRPskQYjsErrdDib5g9VtjTDi1Nyf7NK2ddZlgAwKc ev2UqsVlgatCY0fGSuB6W9OCNr3huyqUlSWMKHVFxEOhbmjgFaOt0M4RN5diEY/M0hLx zv18wG4cgYiphmNLRc3Bva2D5GSFmyOGKcsluCRj5k0qZGUNmEuhz3SYVJcPPuKadXlC NYy4U/+qA/Z93V6kP4iMB2m/txVHg3dZxYoz/g/QAUeZlEyoRnhxvHiL+42KKR6fUGgO AxWT0n8GzFuO6uOMCAO711fd7xCH42v0hoKHA6M7jx1nt8TcVBfGg8Z8kr/OP9exwAgr gu+g== X-Gm-Message-State: AOAM533sMn5HR4ErXbutwSPhcpj9eGvNSWaaqw+p6EaL9kfPcRAgmXV3 SKn/pNzAeXRLMB9FKM+xBQw= X-Google-Smtp-Source: ABdhPJwlLw9Z++M2o8liks1hRj427Nn3WOdFBMNAUOdI8HEst5YJMzf51ohv6HxSyJLO3jI+GRjYyg== X-Received: by 2002:a17:90a:23ab:: with SMTP id g40mr4126370pje.224.1589881549636; Tue, 19 May 2020 02:45:49 -0700 (PDT) Received: from tranquillity (180-150-91-8.b4965b.per.nbn.aussiebb.net. [180.150.91.8]) by smtp.gmail.com with ESMTPSA id z23sm3757190pga.86.2020.05.19.02.45.47 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 19 May 2020 02:45:49 -0700 (PDT) Date: Tue, 19 May 2020 17:45:45 +0800 From: Timothy To: Nicolas Goaziou Message-ID: <0FCF5857-A6CB-45AB-ADF5-944E974630E0@getmailspring.com> In-Reply-To: <87eergjmbn.fsf@nicolasgoaziou.fr> References: <87eergjmbn.fsf@nicolasgoaziou.fr> Subject: Re: (Feature Request) have org-edit-special work inside non-environment LaTeX blocks, i.e. \( \) and \[ \] X-Mailer: Mailspring MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="5ec3aac9_6cad228c_8ce" Received-SPF: pass client-ip=2607:f8b0:4864:20::62b; envelope-from=tecosaur@gmail.com; helo=mail-pl1-x62b.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, HTML_MESSAGE=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-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "=?utf-8?Q?emacs-orgmode=40gnu.org?=" Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=Td+W4y5P; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: -0.50 X-TUID: Eo1ALwu3FXIJ --5ec3aac9_6cad228c_8ce Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Nicolas, > It sounds like you took the opposite route. I suggested to first write = a function, =60org-edit-latex-fragment'. I wanted to see how it would fit in first =C2=AF=5C=5F(=E3=83=84)=5F/=C2=AF= > Once done, you can insert it in =60org-edit-special', but it boils down= to adding a line there, right below (=60inline-src-block ...): =46or that to work though, i.e. adding something of the form (latex-fragm= ent ...) I'd want a =60latex-fragment type to be returned from org-elemen= t-at-point wouldn't I=3F At the moment running (org-element-at-point) inside =5C( =E2=80=A6 =5C) y= ields paragraph. Can I really get away without modifying anything more than org-edit-speci= al and writing org-edit-latex-fragment =3F Timothy On May 19 2020, at 5:39 pm, Nicolas Goaziou wr= ote: > Timothy writes: > With your comments in mind I started by looking at or= g-edit-special, > and managed to get as far as org-element--current-eleme= nt: but at this > point I'm stumped. It sounds like you took the opposite= route. I suggested to first write a function, =60org-edit-latex-fragment= '. Once done, you can insert it in =60org-edit-special', but it boils dow= n to adding a line there, right below (=60inline-src-block ...): (=60late= x-fragment (org-edit-latex-fragments)) You really don't need to mess with= =60org-element--current-element' for this task. > I'll look into getting= =46S=46 papers signed, it sounds like they may come > in handy :) Great=21= --5ec3aac9_6cad228c_8ce Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline
Nicolas,

<= div>> It sounds like you took the opposite route. I = suggested to first write a function, =60org-edit-latex-fragment'.<= /span>
I wanted to see how it would fit in first =C2=AF=5C=5F= (=E3=83=84)=5F/=C2=AF

> Once done, you= can insert it in =60org-edit-special', but it boils down to adding a lin= e there, right below (=60inline-src-block ...):

=46or that to work though, i.e. adding something of the form (latex-fragment ...) I'd wan= t a =60latex-fragment&nb= sp;type to be returned from org= -element-at-point wouldn't I=3F
At the moment runni= ng (org-element-at-point) inside =5C( =E2=80=A6 =5C) yi= elds paragraph.
Can I really get away without modifying anything more than org-edit-special and writin= g org-edit-latex-fragment =3F

Ti= mothy
<= /div>
On May 19 2020, at 5:39 pm, Nicolas Goaziou = <mail=40nicolasgoaziou.fr> wrote:
Timothy wri= tes: > With your comments in mind I started by looking at org-edit-spe= cial, > and managed to get as far as org-element--current-element: but= at this > point I'm stumped. It sounds like you took the opposite rou= te. I suggested to first write a function, =60org-edit-latex-fragment'. O= nce done, you can insert it in =60org-edit-special', but it boils down to= adding a line there, right below (=60inline-src-block ...): (=60latex-fr= agment (org-edit-latex-fragments)) You really don't need to mess with =60= org-element--current-element' for this task. > I'll look into getting = =46S=46 papers signed, it sounds like they may come > in handy :) Grea= t=21
--5ec3aac9_6cad228c_8ce--