From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id uCcXLPRoUWNwbgAAbAwnHQ (envelope-from ) for ; Thu, 20 Oct 2022 17:27:48 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id GBIYLPRoUWNOlAAA9RJhRA (envelope-from ) for ; Thu, 20 Oct 2022 17:27:48 +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 65326339E2 for ; Thu, 20 Oct 2022 17:27:48 +0200 (CEST) Received: from localhost ([::1]:54222 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1olXSU-0002Ec-DW for larch@yhetil.org; Thu, 20 Oct 2022 11:27:46 -0400 Received: from [::1] (helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1olXR4-0007i8-C9 for larch@yhetil.org; Thu, 20 Oct 2022 11:26:20 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33446) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1olVo2-0005gV-4E for emacs-orgmode@gnu.org; Thu, 20 Oct 2022 09:41:54 -0400 Received: from mail.choca.pics ([80.67.172.235]:58694) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1olVo0-0008OG-BB for emacs-orgmode@gnu.org; Thu, 20 Oct 2022 09:41:53 -0400 Received: from localhost (localhost.localdomain [IPv6:::1]) by mail.choca.pics (Postfix) with ESMTP id 32060181942B3; Thu, 20 Oct 2022 15:41:49 +0200 (CEST) Received: from mail.choca.pics ([IPv6:::1]) by localhost (mail.choca.pics [IPv6:::1]) (amavisd-new, port 10032) with ESMTP id KV92_bhX8eZO; Thu, 20 Oct 2022 15:41:48 +0200 (CEST) Received: from localhost (localhost.localdomain [IPv6:::1]) by mail.choca.pics (Postfix) with ESMTP id 9EA98181942B4; Thu, 20 Oct 2022 15:41:48 +0200 (CEST) X-Virus-Scanned: amavisd-new at choca.pics Received: from mail.choca.pics ([IPv6:::1]) by localhost (mail.choca.pics [IPv6:::1]) (amavisd-new, port 10026) with ESMTP id 53e8G36JlkA3; Thu, 20 Oct 2022 15:41:48 +0200 (CEST) Received: from localhost (153.226.95.79.rev.sfr.net [79.95.226.153]) by mail.choca.pics (Postfix) with ESMTPSA id 4C802181942B3; Thu, 20 Oct 2022 15:41:48 +0200 (CEST) From: Damien Cassou To: Ihor Radchenko Cc: emacs-orgmode@gnu.org Subject: Re: Weird behavior of org-element-object-lex In-Reply-To: <87r0z27r8c.fsf@localhost> References: <87fsfjd3ds.fsf@cassou.me> <87v8of83oy.fsf@localhost> <87czanc9vl.fsf@cassou.me> <87r0z27r8c.fsf@localhost> Date: Thu, 20 Oct 2022 15:41:47 +0200 Message-ID: <877d0ud338.fsf@cassou.me> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=80.67.172.235; envelope-from=damien@cassou.me; helo=mail.choca.pics X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, 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=1666279668; 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; bh=n+89+A1qsKYb2l/VnMg5TAx4VKm8+3v0noY8wDBkUM0=; b=NmHuS6tdeySIRj00AOETOY/MaI5l7b6MlgA8CsShFwfvJxZ7ik+IlZ/7OWczhKYA4PbPNQ 8QW+h+Fexbq/OEL/iSPH1Gnpn3pRz92eRAh69seZv+g2tK3FfoOAeJeK4swY2YZClPmK0W aaVq+pccau61HZjBx7NgKZSF9LSN0UHtCfmvgr3vtCmwKwCgrpLEnDYKT8GZ7D7XVXRp3h fRGdFtoaNTp6H1tXShxZa9/ZctqbteWo0RBnCZWyZjGqNG2JbTtz+QY3EyvABSEaQ/UlXU wTCYTCq/S8BR1rUNzZJoX9qn4mG6LVpwMt5y2hoarzOP/MCCcuIPOSfV5ufm1Q== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666279668; a=rsa-sha256; cv=none; b=HY5ulIZo4XaQl5Y4nWGWMDQlQzKMJHFRYIMi6xiRxITRPAiO53GcWRAJwiE7WEh2QgZzyZ weyLW3rVedn0PgIR06ySANSxZ7gGLGZ3Lx4UjBL/g7UxdcCRYAX7rJaRpHbIrWyHfFuBid hdrqqwYYHlif9+NAkYnzttwAu09AUG9736d5x3ed1XOc7sObDoz2PL5wLeSuXcH1uv6Dr6 bn2KHi8glgiyY/LYCI3mn4j0yI+EHlcH+0JvGbo1VFvtRsvsl0x7ahC/E1qdDvoKC3bnVQ p3ZfxtuDYetmGMbu/lv32js402eCHCZwh2GrMwOcki+TjZ5W6zOVIe5p67CkEQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; dmarc=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: -2.73 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=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: 65326339E2 X-Spam-Score: -2.73 X-Migadu-Scanner: scn1.migadu.com X-TUID: bZno4A/myUiw Ihor Radchenko writes: > Damien Cassou writes: >> (defun ox-linuxmag--item (item contents info) >> ... >> The reason `ox-linuxmag--item` has to parse ITEM again is because >> CONTENTS contains "item 1=C2=A0;" >> which misses the initial dash "-" character: i.e., I would like "- item >> 1=C2=A0;" in the paragraph instead. > > Just use ITEM. > You can access the contents of ITEM with org-element-contents. > If you just need to append the bullet, use (org-element-property :bullet = item) I don't understand your solution. `org-element-contents` returns a paragraph element. What should I do with it? I can't just export it because that would result in a 'item 1=C2=A0;' string which misses the initial "- ". --=20 Damien Cassou "Success is the ability to go from one failure to another without losing enthusiasm." --Winston Churchill