]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-1.3.30
authorfred <fred>
Tue, 26 Mar 2002 22:46:34 +0000 (22:46 +0000)
committerfred <fred>
Tue, 26 Mar 2002 22:46:34 +0000 (22:46 +0000)
lily/atom.cc
lily/crescendo.cc
lily/include/atom.hh
lily/include/lily-guile.hh
lily/include/molecule.hh
lily/lily-guile.cc
lily/lookup.cc
lily/paper-outputter.cc
lily/tuplet-spanner.cc
lily/volta-spanner.cc

index f44d4d2c4e475cb876dbc6ea67fb5404900a9b8e..8b137891791fe96927ad78e64b0aad7bded08bdc 100644 (file)
@@ -1,55 +1 @@
-/*
-  atom.cc -- implement Atom
 
-  source file of the GNU LilyPond music typesetter
-
-  (c)  1997--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
-*/
-
-#include <math.h>
-
-#include "atom.hh"
-#include "lookup.hh"
-#include "global-ctor.hh"
-#include "font-metric.hh"
-
-
-#if 0
-SCM translate_sym;
-
-static void init()
-{
-  translate_sym = sly_symbol2scm ("translate-atom");
-}
-
-ADD_SCM_INIT_FUNC(atom, init);
-#endif
-
-SCM
-translate_atom (Offset o, SCM func)
-{
-  return gh_list (ly_symbol2scm ("translate-atom"),
-                 ly_quote_scm (to_scm (o)),
-                 func,
-                 SCM_UNDEFINED);
-}
-
-SCM
-translate_atom_axis (Real r, Axis a, SCM func)
-{
-  //  off_[a] += r;
-  Offset o ;
-  o[a] = r;
-  return gh_list (ly_symbol2scm ("translate-atom"),
-                 ly_quote_scm (to_scm (o)),
-                 func,
-                 SCM_UNDEFINED);
-}
-
-
-SCM
-fontify_atom(Font_metric * met, SCM f)
-{
-  return  gh_list (ly_symbol2scm ("fontify"),
-                  ly_quote_scm (met->description ()), f, SCM_UNDEFINED);
-}
index 3f0f16b637dd1423e6b70eb866188c3f200da3c0..bdf26864df3bb5b7f5358906a2580a8e58e5703e 100644 (file)
@@ -13,7 +13,7 @@
 #include "paper-def.hh"
 #include "debug.hh"
 #include "paper-column.hh"
-#include "atom.hh"
+
 
 Crescendo::Crescendo ()
 {
index c2fb413312689fd2d6b4d656c951ae20325e9c94..576dc45e1a626f286538836e36fcd3887cd9a45f 100644 (file)
@@ -10,9 +10,8 @@
 #define ATOM_HH
 
 #include "lily-proto.hh"
-#include "box.hh"
+
 #include "lily-guile.hh"
 
-SCM fontify_atom (Font_metric*, SCM atom);
 
 #endif
index b79ffbf89522d6620113c6e2d0673d5fede0bedb..8a8f4c2d020201bba21821be20c443b2c5b7a479 100644 (file)
@@ -19,6 +19,7 @@ SCM ly_str02scm (char const*c);
 SCM ly_eval_str (String s);
 SCM ly_symbol2scm (char const *);
 String ly_symbol2string (SCM);
+SCM ly_type (SCM);
 
 SCM ly_eval (SCM a);
 SCM ly_parse_scm (char const* s, int* n);
index 7342d0d406fcc72e190f80407bf88c4682a57de3..6992a2fa4241bf5b270153630f283e376061cc33 100644 (file)
@@ -75,4 +75,7 @@ public:
   bool empty_b() const;
   void print ()const;
 };
+
+SCM fontify_atom (Font_metric*, SCM atom);
+
 #endif
index ccca3060e97edf6a8ff7e262ff7c1cabd9aaaf38..09eca147be7af061886b97d7e5fdeafd8ef6d8bd 100644 (file)
@@ -339,3 +339,31 @@ scm_to (SCM s, Offset*)
   return Offset (gh_scm2double (gh_car (s)),
                 gh_scm2double (gh_cdr (s)));
 }
+
+SCM
+ly_type (SCM exp)
+{
+  char const  * cp = "unknown";
+  if (gh_number_p (exp))
+    {
+      cp = "number";
+    }
+  else if (gh_string_p (exp))
+    {
+      cp = "string";
+    }
+  else if (gh_procedure_p (exp))
+    {
+      cp = "procedure";
+    }
+  else if (gh_boolean_p (exp))
+    {
+      cp = "boolean";
+    }
+  else if (gh_pair_p (exp))
+    {
+      cp = "list";
+    }
+
+  return ly_str02scm (cp);
+}
index f1d1189b2495ec7653b19ae93c338fa37cee65b0..88bd9a753b68e612b91a7719ce21bdebd693e201 100644 (file)
@@ -26,7 +26,7 @@
 #include "afm.hh"
 #include "scope.hh"
 #include "molecule.hh"
-#include "atom.hh"
+
 #include "lily-guile.hh"
 
 
index fc5630d9ac7c95bca21f18901557a9b3eb6cfe66..b624b8ea8f2643308c9cc5109c07f2c3eed833cb 100644 (file)
@@ -26,7 +26,7 @@
 #include "scope.hh"
 #include "identifier.hh"
 #include "lily-version.hh"
-#include "atom.hh"
+
 
 Paper_outputter::Paper_outputter ()
 {
index 36782cb6fc193f02dc2d538f28c891d76fbd3aed..544759570939e5601815e3ec9d9bab6b078b2e83 100644 (file)
@@ -6,7 +6,7 @@
   (c)  1997--2000 Jan Nieuwenhuizen <janneke@gnu.org>
 */
 
-#include "atom.hh"
+
 #include "beam.hh"
 #include "box.hh"
 #include "debug.hh"
index 0fac7a6c2338018cc5974f5bb74e04f9db33364f..9f5427a2443feb73407f40b5ef081df958ca34a4 100644 (file)
@@ -19,7 +19,7 @@
 #include "stem.hh"
 #include "dimension-cache.hh"
 #include "group-interface.hh"
-#include "atom.hh"
+
 
 
 Volta_spanner::Volta_spanner ()