You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
\setleadsheets{print-tags={test}}
% Gets included, as expected:\includeleadsheet{test1.tex} % has tag 'test'% Doesn't get included, as expected:\includeleadsheet{test2.tex} % has tags 'other1', 'other2'% Impossible to include now:% \setleadsheets{ ?? }\includeleadsheet{test3.tex} % has no tags\setleadsheets{print-tags= } % after this, any include will be filtered out% Doesn't get included:\includeleadsheet{test4.tex} % has arbitrary tags
This results in only the inclusion of file test1.tex.
After a tag filter has ben set, there is no way to include a song that doesn't have any tags.
I would like to be able to reset the print-tags option to the initial state where included leadsheets are not filtered by tag.
As far as I understand from reading the documentation as well as the code, this is currently not feasible without directly accessing package internals.
Setting an empty filter value would be an, in my opinion intuitive, syntax to disable the filtering. Even though I might find it intuitive, I'm aware that this probably isn't unambiguous.
Currently however, doing that sets the filter to an empty list. Consequently any included file will not match the filter and thus not be included.
Another option would be to pass a special value for that purpose. But then this value could never occur as an actual tag, which might pose complications of all sorts.
A third option would be to have a seperate command to switch the behaviour (e.g. \setleadsheets{print-all}).
After looking into the code, I believe that the relevant part in the code is this:
What follows is my attempt at how either the first or the last option mentioned above could be implemented. It seems to be possible with little effort (though I only recently learned expl3 syntax and might have overlooked something).
First option: \setleadsheets{print-tags=} (empty value to reset):
If either of this looks good to you, I would be happy if this got implemented. If you would like, I can also submit a pull request.
Thank you for providing this excellent package!
The text was updated successfully, but these errors were encountered:
Consider the following code:
This results in only the inclusion of file
test1.tex
.After a tag filter has ben set, there is no way to include a song that doesn't have any tags.
I would like to be able to reset the
print-tags
option to the initial state where included leadsheets are not filtered by tag.As far as I understand from reading the documentation as well as the code, this is currently not feasible without directly accessing package internals.
Setting an empty filter value would be an, in my opinion intuitive, syntax to disable the filtering. Even though I might find it intuitive, I'm aware that this probably isn't unambiguous.
Currently however, doing that sets the filter to an empty list. Consequently any included file will not match the filter and thus not be included.
Another option would be to pass a special value for that purpose. But then this value could never occur as an actual tag, which might pose complications of all sorts.
A third option would be to have a seperate command to switch the behaviour (e.g.
\setleadsheets{print-all}
).After looking into the code, I believe that the relevant part in the code is this:
leadsheets/leadsheets.library.songs.code.tex
Lines 774 to 776 in 6fdc9fd
What follows is my attempt at how either the first or the last option mentioned above could be implemented. It seems to be possible with little effort (though I only recently learned
expl3
syntax and might have overlooked something).First option:
\setleadsheets{print-tags=}
(empty value to reset):Second option:
\setleadsheets{print-all}
(dedicated option key):print-all .bool_set_inverse:N = \l__leadsheets_print_selected_bool ,
probably extended with the inverse key
print-selected
for completeness:print-selected .bool_set:N = \l__leadsheets_print_selected_bool ,
If either of this looks good to you, I would be happy if this got implemented. If you would like, I can also submit a pull request.
Thank you for providing this excellent package!
The text was updated successfully, but these errors were encountered: