Browse Source

allow tilde in titles and artists

pull/239/head
Oliverpool 9 years ago
parent
commit
2d790bb3ad
  1. 8
      patacrep/data/templates/songs/chordpro/latex/song
  2. 6
      test/test_book/special.tex.control
  3. 6
      test/test_song/special.tsg

8
patacrep/data/templates/songs/chordpro/latex/song

@ -8,7 +8,7 @@
\beginsong{
(*- for title in titles -*)
(( title|escape_specials('{}&#_^%~$\\') ))
(( title|escape_specials('{}&#_^%$\\') ))
(*- if not loop.last -*)
\\
(* endif *)
@ -16,7 +16,7 @@
}[
by={
(* for author in authors *)
(( author[1]|escape_specials('{}&#_^%~$\\') )) (( author[0]|escape_specials('{}&#_^%~$\\') ))
(( author[1]|escape_specials('{}&#_^%$\\') )) (( author[0]|escape_specials('{}&#_^%$\\') ))
(*- if not loop.last -*)
,
(* endif *)
@ -24,7 +24,7 @@
},
(* for key in ['album', 'copyright'] *)
(* if key in metadata *)
(( key ))={(( metadata[key]|escape_specials('{}&#_^%~$\\') ))},
(( key ))={(( metadata[key]|escape_specials('{}&#_^%$\\') ))},
(* endif *)
(* endfor *)
(* if 'url' in metadata *)
@ -39,7 +39,7 @@
(* endblock *)
(* endif *)
(* for key in metadata.morekeys *)
(( key.keyword ))={(( key.argument|escape_specials('{}&#_^%~$\\') ))},
(( key.keyword ))={(( key.argument|escape_specials('{}&#_^%$\\') ))},
(* endfor *)
]

6
test/test_book/special.tex.control

@ -134,10 +134,10 @@ guitar,
\selectlanguage{english}
\beginsong{\& \$ \% \# \_ \} \{ \textasciitilde{} \textasciicircum{} \textbackslash{}}[
\beginsong{\& \$ \% \# \_ \} \{ ~ \textasciicircum{} \textbackslash{}}[
by={
\& \$ \% \# \_ \} \{ \textasciitilde{} \textasciicircum{} \textbackslash{} },
album={\& \$ \% \# \_ \} \{ \textasciitilde{} \textasciicircum{} \textbackslash{}},
\& \$ \% \# \_ \} \{ ~ \textasciicircum{} \textbackslash{} },
album={\& \$ \% \# \_ \} \{ ~ \textasciicircum{} \textbackslash{}},
url={http://&$\%\#_~^},
]

6
test/test_song/special.tsg

@ -1,9 +1,9 @@
\selectlanguage{english}
\beginsong{\& \$ \% \# \_ \} \{ \textasciitilde{} \textasciicircum{} \textbackslash{}}[
\beginsong{\& \$ \% \# \_ \} \{ ~ \textasciicircum{} \textbackslash{}}[
by={
\& \$ \% \# \_ \} \{ \textasciitilde{} \textasciicircum{} \textbackslash{} },
album={\& \$ \% \# \_ \} \{ \textasciitilde{} \textasciicircum{} \textbackslash{}},
\& \$ \% \# \_ \} \{ ~ \textasciicircum{} \textbackslash{} },
album={\& \$ \% \# \_ \} \{ ~ \textasciicircum{} \textbackslash{}},
url={http://&$\%\#_~^},
]

Loading…
Cancel
Save