From 98703008d1b38a619934e5caf93dac04a73b7518 Mon Sep 17 00:00:00 2001 From: Hugo Villeneuve Date: Fri, 3 Dec 2021 13:38:00 -0500 Subject: [PATCH] Conversion du titre en majuscule --- gtx2tex.pl | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/gtx2tex.pl b/gtx2tex.pl index d4cc438..0744e01 100644 --- a/gtx2tex.pl +++ b/gtx2tex.pl @@ -319,11 +319,16 @@ sub directive{ } if ( $output eq "pdf" ) { print TEX "\\pdfdest name {$_} fith \\pdfoutline goto name {$_} {$_}" } - print TEX "\\begin{center} \\section*{$_}\\end{center}\n"; - $define=""; - print TEX "\\index{$_}"; + $song_title = $_; - $verbose && print TEX "\\typeout{$_}"; + if ( $uppercase ) { + $song_title = uc($song_title); + } + + print TEX "\\begin{center} \\section*{$song_title}\\end{center}\n"; + $define=""; + print TEX "\\index{$song_title}"; + $verbose && print TEX "\\typeout{$song_title}"; }elsif ( /{subtitle:|{st:/ ) { s/(\{.*:)(.+)(\})/\2/; print TEX "\\index{$_!$song_title}"; -- 2.20.1