From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id GF3lJ9P1v2T4qwAASxT56A (envelope-from ) for ; Tue, 25 Jul 2023 18:18:27 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id CBwZJ9P1v2SdyQAAG6o9tA (envelope-from ) for ; Tue, 25 Jul 2023 18:18:27 +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 1747663267 for ; Tue, 25 Jul 2023 18:18:26 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=Ic4LAi7X; 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=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1690301907; 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=A4GpiszprV04ko4Q2tFDVAMf/Y/OW6AYQZl5RXD1RxA=; b=LFuY3+kKCG1TLpGNWhQbuzRn+l9XFwBjFQvSpzLBlJEvFFQhVSDL5hJGmQLJKrWwD2O2pK lihnw/8qO3VK8IqPU3VI3L7suAd6fizMn28sUPbWtRsDgqxwGATHbgzm3Dgz0BwkhoafXo Az7zuJDQM9JpNC9vycZ3NOIdB/Yq3ewYQBunPFnGFW7oFjrNqvqazZaKFwGqJTqS3HOR5n iFPXfEQTW4+0a0HkG0QTUacl6QZVg8LiUZGNfvE0pLB6FvRaG2zmWFVh3KEjQCVunrnl/d fg4wJ6PghnbWS38V6zehZq/gpU8MiLOHCK/nlQvuM03S0O7an4gihTpK1NwZqg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20221208 header.b=Ic4LAi7X; 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=gmail.com ARC-Seal: i=1; s=key1; d=yhetil.org; t=1690301907; a=rsa-sha256; cv=none; b=hIEvDbVwLngVg87U1eWrdFsK5Ch2euucvg4UOT/nLL5sIJMNbRE+2WCkVKLtX9g6cwUGGw 81iYRC+uAXSf242trL/8uxUFaGJu5WX3fqK+7W32PyIS4OZIG0DokxE10Vchl6az0fWnfG +FLyE+ukwEIJ4MIM6L+wa25fXRGkE6YW98kF7bzK86hpRGSrzr5wKTpKJznugxpG/zKU+f Mf17Yk4DrWN39xb/tSm5zUfGdmp8MHA+Js4Wzmo1kukDKuYdk8R+HzdW8tUbmIrzW9yob9 PGyS4T7yH9pv4S27vtsOjf2je3r6NIPTldEYhCdwP1Rh4tSVIXvsN3UPSt7+uQ== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qOKik-0008Ay-JX; Tue, 25 Jul 2023 12:17:10 -0400 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 1qOKii-0008AV-TW for emacs-orgmode@gnu.org; Tue, 25 Jul 2023 12:17:08 -0400 Received: from mail-pf1-x432.google.com ([2607:f8b0:4864:20::432]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qOKig-0002MD-Rc for emacs-orgmode@gnu.org; Tue, 25 Jul 2023 12:17:08 -0400 Received: by mail-pf1-x432.google.com with SMTP id d2e1a72fcca58-6689430d803so3448258b3a.0 for ; Tue, 25 Jul 2023 09:17:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1690301824; x=1690906624; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=A4GpiszprV04ko4Q2tFDVAMf/Y/OW6AYQZl5RXD1RxA=; b=Ic4LAi7X20j/LyWGt4s3SuNypzJsFLPWLSf0v33tzmZjlSC9d9HhDl+r5wo9qG9Qaw IqSqlVwbh6HUgtKuPvnqr8PkhkuP554DsjtIKO2Jlb6R4dtoB4XwzTntZtt9+nNwcFTO aIIOTBLVil2IRWzObgRwsMYKOiKlvH+2BN+7MpBQYFToUkkKfbRdOX9IkubEK5jLZIHb zU4KROjHwbi956l4G60ib+u3cv26YdWgTf8/QDBUusbrRexfHaMpzr/CH/orH74Ro8gC VHMdpoSna04ktY/72hQt7uK/DjwiOX8OYNMDVPnXUnEGb07j3NXTK8g/WeVPI/0ZO0xT 6nCg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1690301824; x=1690906624; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=A4GpiszprV04ko4Q2tFDVAMf/Y/OW6AYQZl5RXD1RxA=; b=FULXkYQJjpMUEOGU3WTyyfq2gRZtF+SjADJoGtCWOnh6nXqmF8v7zp8hBIPYX7cdxl UoGlP81y2iMzReJ3yMBm6XsreKcKAfp1dl6729LisEabyIvN9LP000bOzTlFXNq5tRfQ kX0y1auTcFbANUTw9tG3wJeGX8mysHQwDPknKaW1+PHUeieA2wry5khzTUCtf9psHMIF 4TkU6g35xeupN2fV0kK3hRuflsbam5pvV/+DkoyMVx9u9APl28wWnLkdC616J3jPgpPR kOlg8hNZPcNHcLORDacbIEXLIXLLbfhvU0rBciIzyvrrwzZYYwpOVQhEhg7hI7stdf0t R/1g== X-Gm-Message-State: ABy/qLY38p8TeNW6x3KzJfcupqYVYTUnIISiLckzPiXUqfnw2duoiD9e zUrE3nE0BRbtbjVsIrgUTr1GUPVX0TE1HyAmBG4= X-Google-Smtp-Source: APBJJlFWmhaA9sAU2RN7N8DU1swMiKTgtRK+Ep7k9oXuHBAPCGW/X2e6UBkHniR+y1IhSvF+hwnoohb+7VtHCT6ONXU= X-Received: by 2002:a17:90a:bc86:b0:268:2b45:e606 with SMTP id x6-20020a17090abc8600b002682b45e606mr3503125pjr.38.1690301824226; Tue, 25 Jul 2023 09:17:04 -0700 (PDT) MIME-Version: 1.0 References: <87bl9rq29m.fsf@gnu.org> <875yzzilq0.fsf@cnrs.fr> <871ram4x83.fsf@web.de> <87a5w15jur.fsf@localhost> <87fs5svjqb.fsf@autistici.org> <87a5w0yvhf.fsf@localhost> <87ilam3bv1.fsf@autistici.org> <877cr2id09.fsf@localhost> <87zg3uxyba.fsf@autistici.org> <87sf9lv9ta.fsf@localhost> <878rbchyt9.fsf@autistici.org> <87edl3xdhe.fsf@localhost> <87tttyjw6b.fsf@autistici.org> <878rb990n5.fsf@localhost> <87r0p1pk2y.fsf@autistici.org> <87jzus8ive.fsf@localhost> In-Reply-To: <87jzus8ive.fsf@localhost> From: Henrik Frisk Date: Tue, 25 Jul 2023 18:16:52 +0200 Message-ID: Subject: Re: [BUG] WORG example for ob-lilypond is no longer working as described (was: Moving some lisp/ob-*.el files to org-contrib - your advice?) To: Ihor Radchenko Cc: Jonathan Gregory , "Dr. Arne Babenhauserheide" , "Victor A. Stoichita" , emacs-orgmode@gnu.org Content-Type: multipart/alternative; boundary="000000000000cbdba70601520f53" Received-SPF: pass client-ip=2607:f8b0:4864:20::432; envelope-from=frisk.h@gmail.com; helo=mail-pf1-x432.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, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, 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-Flow: FLOW_IN X-Migadu-Country: US X-Spam-Score: -9.52 X-Migadu-Queue-Id: 1747663267 X-Migadu-Spam-Score: -9.52 X-Migadu-Scanner: mx0.migadu.com X-TUID: yr5nwFZKtUi5 --000000000000cbdba70601520f53 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, I have been struggling with the same issues to but have completely missed this thread. I haven't tried the patch of ob-lilypond but testing the file https://git.sr.ht/~bzg/worg/tree/6f69d212f41bc372426dc9b4df286638fe8f2a92/i= tem/org-contrib/babel/examples/lilypond.org I'm getting cropped output with pdf, but not png (generates full page). Also, omitting the paper stuff I still get the same cropped output wit pdf: #+begin_src lilypond :file ionian.png \version "2.24.1" \relative c' { c d e f g a b c b a g f e d c d e f g a b c b a g f e d c1 } #+end_src Adding #(ly:set-option 'crop #t) to the file gives a cropped output in the file 'ionian.cropped.png' but the ionian.png is still fullpage. I was looking in ob-lilypond to change the outputfile name but the easy solution is to just give the cropped name as the :file argument: :file ionian.cropped.png Then the file is shown inline in the #+RESULT: block. This works for other file formats two, like pdf and eps. Here's a short version: #+begin_src lilypond :file ionian.cropped.png \Version "2.24.1" #(ly:set-option 'crop #t) \relative c' { c d e f } #+end_src /Henrik Den l=C3=B6r 22 juli 2023 kl 10:13 skrev Ihor Radchenko : > Jonathan Gregory writes: > > > On 21 Jul 2023, Ihor Radchenko wrote: > > > >> The png is still a full page on my side. > > > > That's not what I get. You're probably missing the paper settings: > > > > #+begin_src lilypond :exports none > > \version "2.20" > > \paper { > > indent=3D0\mm > > tagline=3D"" > > line-width=3D170\mm > > oddFooterMarkup=3D##f > > oddHeaderMarkup=3D##f > > bookTitleMarkup=3D##f > > scoreTitleMarkup=3D##f > > } > > #+end_src > > I feel confused. Isn't you patch aiming for auto-sizing the resulting > page to fit the music fragment? > > >> Also, I am getting > >> > >> Processing `/tmp/babel-xQweBZ/lilypond-WGdEvi' > >> Parsing... > >> /tmp/babel-xQweBZ/lilypond-WGdEvi:1: warning: no \version > >> statement found, please add > >> > >> \version "2.24.0" > >> > >> which does not look necessary. > > > > What is not necessary? The warning is expected. Other than that > > everything looks fine. > > I guess I do not fully understand what your patch is trying to achieve. > I thought that the patch would make it not necessary to write some extra > boilerplate code, like \version or specifying the page size. > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at . > Support Org development at , > or support my work at > > --000000000000cbdba70601520f53 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,

I have been struggling w= ith the same issues to but have completely missed this thread. I haven'= t tried the patch of ob-lilypond but testing the file https://git.sr.ht/~bzg/worg/tree/6f69d21= 2f41bc372426dc9b4df286638fe8f2a92/item/org-contrib/babel/examples/lilypond.= org I'm getting cropped output with pdf, but not png (generates ful= l page). Also, omitting the paper stuff I still get the same cropped output= wit pdf:

#+begin_src lilypond :file ionian.png
=C2=A0\version "2.24.1"
=C2=A0 =C2=A0 \relative c'= {
=C2=A0 =C2=A0 =C2=A0 c d e f
=C2=A0 =C2=A0 =C2=A0 g a b c
=C2= =A0 =C2=A0 =C2=A0 b a g f
=C2=A0 =C2=A0 =C2=A0 e d c d
=C2=A0 =C2=A0 = =C2=A0 e f g a
=C2=A0 =C2=A0 =C2=A0 b c b a
=C2=A0 =C2=A0 =C2=A0 g f = e d
=C2=A0 =C2=A0 =C2=A0 c1
=C2=A0 =C2=A0 }
#+end_src
=

Adding=C2=A0 #(ly:set-option 'crop #t) to the file = gives a cropped output in the file 'ionian.cropped.png' but the ion= ian.png is still fullpage. I was looking in ob-lilypond to change the outpu= tfile name but the easy solution is to just give the cropped name as the :f= ile argument:

:file ionian.cropped.png
<= br>
Then the file is shown inline in the #+RESULT: block. This wo= rks for other file formats two, like pdf and eps.

= Here's a short version:

#+begin_src lilypond := file ionian.cropped.png
=C2=A0 \Version "2.24.1"
=C2=A0 =C2= =A0 #(ly:set-option 'crop #t)
=C2=A0 =C2=A0 \relative c' {
= =C2=A0 =C2=A0 =C2=A0 c d e f
=C2=A0 =C2=A0 }
#+end_src

=
/Henrik


Den l=C3=B6r 22 juli 2023 kl 10:= 13 skrev Ihor Radchenko <yantar92= @posteo.net>:
Jonathan Gregory <jgrg@autistici.org> writes:

> On 21 Jul 2023, Ihor Radchenko wrote:
>
>> The png is still a full page on my side.
>
> That's not what I get. You're probably missing the paper setti= ngs:
>
> #+begin_src lilypond :exports none
> \version "2.20"
> \paper {
>=C2=A0 =C2=A0indent=3D0\mm
>=C2=A0 =C2=A0tagline=3D""
>=C2=A0 =C2=A0line-width=3D170\mm
>=C2=A0 =C2=A0oddFooterMarkup=3D##f
>=C2=A0 =C2=A0oddHeaderMarkup=3D##f
>=C2=A0 =C2=A0bookTitleMarkup=3D##f
>=C2=A0 =C2=A0scoreTitleMarkup=3D##f
> }
> #+end_src

I feel confused. Isn't you patch aiming for auto-sizing the resulting page to fit the music fragment?

>> Also, I am getting
>>
>> Processing `/tmp/babel-xQweBZ/lilypond-WGdEvi'
>> Parsing...
>> /tmp/babel-xQweBZ/lilypond-WGdEvi:1: warning: no \version
>> statement found, please add
>>
>> \version "2.24.0"
>>
>> which does not look necessary.
>
> What is not necessary? The warning is expected. Other than that
> everything looks fine.

I guess I do not fully understand what your patch is trying to achieve.
I thought that the patch would make it not necessary to write some extra boilerplate code, like \version or specifying the page size.

--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,=
or support my work at <https://liberapay.com/yantar92>

--000000000000cbdba70601520f53--