Mensuraler F-Schlüssel im Petrucci-Stil, kann auf verschiedenen
Notenlinien benutzt werden (im Beispiel auf der dritten Linie)
@tab
-@code{petrucci-c1}, @code{petrucci-c2},@*
-@code{petrucci-c3}, @code{petrucci-c4},@*
-@code{petrucci-c5}
+@code{petrucci-f3}, @code{petrucci-f4},@*
+@code{petrucci-f5}
@tab
@lilypond[relative=1,notime]
- \clef "petrucci-c2"
+ \clef "petrucci-f3"
\override NoteHead.style = #'mensural
c
@end lilypond
@divEnd
+@divClass{column-center-middle-color3}
+@subheading Rewrite LibreOffice LilyPond Extension with Python
+
+The @uref{http://ooolilypond.sourceforge.net/, OOoLilyPond} extension
+made it possible to conveniently include LilyPond score snippets in
+OpenOffice.org/LibreOffice Writer, Draw and Impress documents while
+keeping source and image together. After many years without development
+an initial effort has started to make the extension compatible again
+with current versions of LibreOffice and LilyPond.
+
+However, as the LibreOffice ecosystem has changed substantially it is
+now possible to rewrite the extension with Python and PyQt. This will
+not only be more powerful in general but will allow the integration of
+functionality from @uref{http://frescobaldi.org, Frescobaldi}, such as
+for example syntax highlighting, entry helpers, score wizards or musical
+transformations.
+
+@strong{Difficulty:} easy/medium
+@strong{Requirements:} Python, PyQt, LilyPond basics, LibreOffice
+extension basics
+@strong{Recommended knowledge:} Familiarity with Frescobaldi code based
+or willingness to learn during bonding period
+@strong{Mentor(s):} Urs Liska, (Thorsten Behrens/LibreOffice)
+
+@divEnd
+
@divClass{column-center-middle-color3}
@subheading Automated testing and documentation for openLilyLib
Callback0_wrapper::make_smob
<Translator_group, &Translator_group::finalize> (),
UP);
- send_stream_event (ctx, "RemoveContext", 0, 0);
+ send_stream_event (ctx, "RemoveContext", 0);
}
}
}
}
/*
-Called by the send_stream_event macro. props is a 0-terminated array of
-properties and corresponding values, interleaved. This method should not
-be called from any other place than the send_stream_event macro.
+These methods should not be called from any other place than the
+send_stream_event macro.
*/
+
void
-Context::internal_send_stream_event (SCM type, Input *origin, SCM props[])
+Context::internal_send_stream_event (SCM type, Input *origin)
{
Stream_event *e = new Stream_event (Lily::ly_make_event_class (type), origin);
- for (int i = 0; props[i]; i += 2)
- {
- e->set_property (props[i], props[i + 1]);
- }
+ event_source_->broadcast (e);
+ e->unprotect ();
+}
+
+void
+Context::internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val)
+{
+ Stream_event *e = new Stream_event (Lily::ly_make_event_class (type), origin);
+ e->set_property (prop, val);
+ event_source_->broadcast (e);
+ e->unprotect ();
+}
+
+void
+Context::internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val, SCM prop2, SCM val2)
+{
+ Stream_event *e = new Stream_event (Lily::ly_make_event_class (type), origin);
+ e->set_property (prop, val);
+ e->set_property (prop2, val2);
+ event_source_->broadcast (e);
+ e->unprotect ();
+}
+
+void
+Context::internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val, SCM prop2, SCM val2,
+ SCM prop3, SCM val3)
+{
+ Stream_event *e = new Stream_event (Lily::ly_make_event_class (type), origin);
+ e->set_property (prop, val);
+ e->set_property (prop2, val2);
+ e->set_property (prop3, val3);
+ event_source_->broadcast (e);
+ e->unprotect ();
+}
+
+void
+Context::internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val, SCM prop2, SCM val2,
+ SCM prop3, SCM val3, SCM prop4, SCM val4)
+{
+ Stream_event *e = new Stream_event (Lily::ly_make_event_class (type), origin);
+ e->set_property (prop, val);
+ e->set_property (prop2, val2);
+ e->set_property (prop3, val3);
+ e->set_property (prop4, val4);
event_source_->broadcast (e);
e->unprotect ();
}
iter->quit ();
scm_remember_upto_here_1 (protected_iter);
- send_stream_event (g, "Finish", 0, 0);
+ send_stream_event (g, "Finish", 0);
debug_output (_f ("elapsed time: %.2f seconds", timer.read ()));
if (iter->ok ())
iter->process (w);
- send_stream_event (this, "OneTimeStep", 0, 0);
+ send_stream_event (this, "OneTimeStep", 0);
apply_finalizations ();
check_removal ();
}
// to distinguish \stemNeutral \grace { ... and \grace { \stemNeutral ...
if (in_grace_ != bool (m.grace_part_) && child_iter_ && child_iter_->get_outlet ())
{
- send_stream_event (child_iter_->get_outlet (), "GraceChange", get_music ()->origin (), 0);
+ send_stream_event (child_iter_->get_outlet (), "GraceChange", get_music ()->origin ());
}
in_grace_ = m.grace_part_;
Dispatcher *event_source () const { return event_source_; }
Dispatcher *events_below () const { return events_below_; }
- void internal_send_stream_event (SCM type, Input *origin, SCM props[]);
-
+ void internal_send_stream_event (SCM type, Input *origin);
+ void internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val);
+ void internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val, SCM prop2, SCM val2);
+ void internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val, SCM prop2, SCM val2,
+ SCM prop3, SCM val3);
+ void internal_send_stream_event (SCM type, Input *origin,
+ SCM prop, SCM val, SCM prop2, SCM val2,
+ SCM prop3, SCM val3, SCM prop4, SCM val4);
SCM get_definition () const { return definition_; }
SCM get_definition_mods () const { return definition_mods_; }
/* Shorthand for creating and broadcasting stream events. */
#define send_stream_event(ctx, type, origin, ...) \
- do { \
- SCM props[] = { __VA_ARGS__, 0 }; \
- ctx->internal_send_stream_event (ly_symbol2scm (type), origin, props); \
- } while (0)
+ ctx->internal_send_stream_event (ly_symbol2scm (type), origin, ##__VA_ARGS__)
SCM nested_property_alist (SCM alist, SCM prop_path, SCM value);
SCM nested_property (SCM alist, SCM prop_path, SCM fallback = SCM_EOL);