From 5f809c021a5db8371c799e13f8c633e313748593 Mon Sep 17 00:00:00 2001 From: Jonathan Wilkes <jon.w.wilkes@gmail.com> Date: Mon, 13 Feb 2017 23:43:10 -0500 Subject: [PATCH] fix #254: add l2ork version to [pdinfo] --- pd/src/x_interface.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/pd/src/x_interface.c b/pd/src/x_interface.c index 52faf175c..140ab816f 100644 --- a/pd/src/x_interface.c +++ b/pd/src/x_interface.c @@ -859,6 +859,15 @@ void pdinfo_version(t_pdinfo *x, t_symbol *s, int argc, t_atom *argv) info_out((t_text *)x, s, 3, at); } +void pdinfo_l2ork_version(t_pdinfo *x, t_symbol *s, int argc, t_atom *argv) +{ + char buf[MAXPDSTRING]; + t_atom at[1]; + sprintf(buf, PD_L2ORK_VERSION " " PD_BUILD_VERSION); + SETSYMBOL(at, gensym(buf)); + info_out((t_text *)x, s, 1, at); +} + void pdinfo_print(t_pdinfo *x) { info_print((t_text *)x); @@ -930,6 +939,8 @@ void pdinfo_setup(void) gensym("samplerate"), A_GIMME, 0); class_addmethod(pdinfo_class, (t_method)pdinfo_version, gensym("version"), A_GIMME, 0); + class_addmethod(pdinfo_class, (t_method)pdinfo_l2ork_version, + gensym("l2ork_version"), A_GIMME, 0); class_addmethod(pdinfo_class, (t_method)pdinfo_print, gensym("print"), 0); -- GitLab