quarto-dev / quarto-dev/quarto-cli

Code listings and "filename" cause error for PDF files

Aperta
#9,243 6 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@cscheid ci sta già lavorando.

Dal 1/4/2024.

bug crossref latex listings lua
Lingua principale
JavaScript
Stelle
6k
Fork
458
Merge medio
1g 9h
PR unite (30g)
41

Descrizione

Bug description

When setting "listings: true" for format PDF, the div parameter "filename" causes an error:

Package keyval Error: filename undefined.

See the keyval package documentation for explanation.
Type  H <return>  for immediate help.
 ...                                              
                                                  
l.151 \begin{lstlisting}[filename=Terminal]

Using "title" instead of "filename" does not throw the error. However, "title" does not produce the code listings heading in html.

Steps to reproduce
---
title: "Test Listings"

format: 
  pdf:
    listings: true
---

## Test with listings

```{.zsh filename="Terminal"}
echo "Hello World"
```

more text

Expected behavior
  • "filename" should be used as title for the code
Actual behavior
  • The PDF compilation stops with an error
Your environment
  • IDE: Version 2023.12.1+402 (2023.12.1+402)
  • Quarto: version 1.4.552
  • macOS: Sonoma 14.4.1
Quarto check output

No response

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.