From: Reinhold Kainhofer Date: Fri, 11 Jun 2010 19:02:16 +0000 (+0200) Subject: Lilypond-book: Allow the snippets class to declare its own used options X-Git-Tag: release/2.13.24-1~5 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=7d4265883794cec4ad0e7312f0787d0565fe757f;p=lilypond.git Lilypond-book: Allow the snippets class to declare its own used options --- diff --git a/python/book_snippets.py b/python/book_snippets.py index 3c4f32d5d3..fa4d97ccec 100644 --- a/python/book_snippets.py +++ b/python/book_snippets.py @@ -328,6 +328,9 @@ class LilypondSnippet (Snippet): self.do_options (os, self.type) + def snippet_options (self): + return []; + def verb_ly_gettext (self, s): lang = self.formatter.document_language if not lang: @@ -529,7 +532,7 @@ left-margin-default right-margin-default)" found = 1 break - if not found and key not in simple_options: + if not found and key not in simple_options and key not in self.snippet_options (): warning (_ ("ignoring unknown ly option: %s") % key) # URGS