From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.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 qOCeMtf9TGO0MgEAbAwnHQ (envelope-from ) for ; Mon, 17 Oct 2022 09:01:43 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id ODO9Mdf9TGO/SQAAG6o9tA (envelope-from ) for ; Mon, 17 Oct 2022 09:01:43 +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 7E7A83C300 for ; Mon, 17 Oct 2022 09:01:43 +0200 (CEST) Received: from localhost ([::1]:35954 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1okK86-0006SV-Fr for larch@yhetil.org; Mon, 17 Oct 2022 03:01:42 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:47254) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1okJzM-0001h3-2P for emacs-orgmode@gnu.org; Mon, 17 Oct 2022 02:52:41 -0400 Received: from mail.choca.pics ([80.67.172.235]:34860) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1okJzJ-0004Rp-1y for emacs-orgmode@gnu.org; Mon, 17 Oct 2022 02:52:39 -0400 Received: from localhost (localhost.localdomain [IPv6:::1]) by mail.choca.pics (Postfix) with ESMTP id 3B6F1181942A4 for ; Mon, 17 Oct 2022 08:52:26 +0200 (CEST) Received: from mail.choca.pics ([IPv6:::1]) by localhost (mail.choca.pics [IPv6:::1]) (amavisd-new, port 10032) with ESMTP id rRZW6jy8wjrz for ; Mon, 17 Oct 2022 08:52:25 +0200 (CEST) Received: from localhost (localhost.localdomain [IPv6:::1]) by mail.choca.pics (Postfix) with ESMTP id B2525181942B3 for ; Mon, 17 Oct 2022 08:52:25 +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 EtZeynAfaWKJ for ; Mon, 17 Oct 2022 08:52:25 +0200 (CEST) Received: from localhost (153.226.95.79.rev.sfr.net [79.95.226.153]) by mail.choca.pics (Postfix) with ESMTPSA id 6807F181942A4 for ; Mon, 17 Oct 2022 08:52:25 +0200 (CEST) From: Damien Cassou To: emacs-orgmode@gnu.org Subject: Need for dedicated kinds of paragraphs Date: Mon, 17 Oct 2022 08:52:24 +0200 Message-ID: <8735bn2b87.fsf@cassou.me> MIME-Version: 1.0 Content-Type: text/plain 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=1665990103; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=yX2aA18uAQZARNjbCPMKh11ghcOMZCUJtDvoCNm6tsY=; b=kF7ZhzRG5g48XQsonX+A4W1uC2Ielf8m15MK++uVQno1KjFGkkyMOmlV4xvmNFSRhfqUIX ftCYrjhKK+Ur6j9xslk0RTEZYRRgH5QkAX4xNz6/geWGhXm03M0A7EybjoUFSFEHJsmkqv NRALnl2ncD5EPxhWvgVokDjrR7jIuDaFfpmeoCRuZWKRqrWardY1KQMVhJ4QPBEF98YcKI JPhA0iZcAHp+rO2jVT4Ail1TwvghqU6q6Hvi+z9Gr5QVGyS5ilVLNUpdT6Or2i9vXyZnd1 JA5v+3+QWAZ8JT+yc6YgrHpKxHBNuXPmZAFDcf9SS/Smbp32kqp7fzxC5yDgwQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1665990103; a=rsa-sha256; cv=none; b=G0MOfljm7YIObtJLwBPW8uczlYbg/W2pFNExoAqWeU1ZisYZK2iTXI2OBpnhw8l/Ax+ASX twYURIfPIpAIjAEiMbCcyCGyda7CtLhjMKr2f5mF8enRzuuB6tzm8UVrl3GdXFtH9G2tZt JGTINtAWlSnLS4QX3ImBoSo4UaxzAT8SGmtUHV/xaQUK1EF7ZiM6FTJCdZudmH4C6YV59F ILtSeMQZVA0JyPvlBJwGJhUlj2Bp8jqeElXA4dcbXpddLuO7U8RpQVy+u9oFRIzR/cDPqJ 0bEzd5pNl07pYiRARs5bf43pQ2fhLPSeFizDSignonOewn0LKxULQXHsSlBLiA== 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: -3.02 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: 7E7A83C300 X-Spam-Score: -3.02 X-Migadu-Scanner: scn0.migadu.com X-TUID: N6Wmlriq729r Hi, I'm implementing an odt-based exporter for a French magazine named GNU/Linux Magazine. This magazine defines several kinds of boxes, which are small paragraphs of a certain type among "Default", "Attention", "Warning" and "PAO". When published, the magazine will change the background of these boxes depending on the type (e.g., using red color for warning boxes). I'm not sure what kind of markup to use nor how to transcode that markup. I tried with: #+BOX: attention This text will appear with a red background Does that make sense? Do you have a better suggestion? >From Worg's org-syntax.html file [1], I understand that this is an "affiliated keyword" and that it must be declared in `org-element-affiliated-keywords' but this variable is a `defconst' so I'm reluctant to change it in my exporter. I have an `ox-linuxmag--paragraph' transcoder for the `paragraph' type but I don't know how to get the value of the "BOX" keyword. Do you have any suggestion? If I have a look at how org-odt transcodes paragraphs, I see this function: (defun org-odt-paragraph (paragraph contents info) "Transcode a PARAGRAPH element from Org to ODT. CONTENTS is the contents of the paragraph, as a string. INFO is the plist used as a communication channel." (org-odt--format-paragraph paragraph contents info (or (org-element-property :style paragraph) "Text_20_body") "OrgCenter" "Quotations")) Could I use the :style property? What would the markup be like to make that work? Thank you so much for Org! [1] https://orgmode.org/worg/dev/org-syntax.html#Affiliated_Keywords -- Damien Cassou "Success is the ability to go from one failure to another without losing enthusiasm." --Winston Churchill