* lily/lily-guile.cc: remove ly_scm2str0.
2004-09-01 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ * lily/include/lily-guile.hh: compatibility glue for 1.6
+
+ * lily/*.cc (acknowledge_grob): ly_string_p -> scm_is_string.
+
* lily/lily-guile.cc: remove ly_scm2str0.
2004-09-01 Jan Nieuwenhuizen <janneke@gnu.org>
(SCM name),
"Load the font @var{name}. ")
{
- SCM_ASSERT_TYPE (ly_c_string_p (name), name, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (name), name, SCM_ARG1, __FUNCTION__, "string");
Font_metric * fm = all_fonts_global->find_font (ly_scm2string (name));
void
Auto_beam_engraver::process_music ()
{
- if (ly_c_string_p (get_property ("whichBar")))
+ if (scm_is_string (get_property ("whichBar")))
{
consider_end (shortest_mom_);
junk_beam ();
void
Bar_engraver::process_acknowledged_grobs ()
{
- if (!bar_ && ly_c_string_p (get_property ("whichBar")))
+ if (!bar_ && scm_is_string (get_property ("whichBar")))
create_bar ();
}
SCM s = me->get_property ("glyph");
SCM barsiz_proc = me->get_property ("bar-size-procedure");
- if (ly_c_string_p (s) && ly_c_procedure_p (barsiz_proc))
+ if (scm_is_string (s) && ly_c_procedure_p (barsiz_proc))
{
String str =ly_scm2string (s);
SCM siz = scm_call_1 (barsiz_proc, me->self_scm ());
SCM g = me->get_property ("glyph");
SCM orig = g;
Direction bsd = item->break_status_dir ();
- if (ly_c_string_p (g) && bsd)
+ if (scm_is_string (g) && bsd)
{
SCM proc = me->get_property ("break-glyph-function");
g = scm_call_2 (proc, g, scm_int2num (bsd));
}
- if (!ly_c_string_p (g))
+ if (!scm_is_string (g))
{
me->set_property ("print-function", SCM_EOL);
me->set_extent (SCM_EOL, X_AXIS);
SCM wb = get_property ("whichBar");
- if (ly_c_string_p (wb))
+ if (scm_is_string (wb))
{
SCM smp = get_property ("measurePosition");
#if (DEBUG_QUANTING)
SCM quant_score = me->get_property ("quant-score");
if (to_boolean (me->get_paper ()->lookup_variable (ly_symbol2scm ("debug-beam-quanting")))
- && ly_c_string_p (quant_score))
+ && scm_is_string (quant_score))
{
/*
if (item)
{
if (Bar_line::has_interface (info.grob_)
- && ly_c_string_p (get_property ("clefGlyph")))
+ && scm_is_string (get_property ("clefGlyph")))
create_clef ();
}
}
SCM glyph = s->get_property ("glyph-name");
- if (ly_c_string_p (glyph))
+ if (scm_is_string (glyph))
{
String str = ly_scm2string (glyph);
{
Grob *me = unsmob_grob (smob);
SCM glyph_scm = me->get_property ("glyph-name");
- if (!ly_c_string_p (glyph_scm))
+ if (!scm_is_string (glyph_scm))
return SCM_EOL;
String glyph = String (ly_scm2string (glyph_scm));
}
SCM sym = ly_cadr (mod);
- if (ly_c_string_p (sym))
+ if (scm_is_string (sym))
sym = scm_string_to_symbol (sym);
if (ly_symbol2scm ("consists") == tag
SCM tag = ly_caar (s);
SCM arg = ly_cadar (s);
- if (ly_c_string_p (arg))
+ if (scm_is_string (arg))
arg = scm_string_to_symbol (arg);
if (ly_symbol2scm ("consists") == tag)
String c_id;
SCM ci = get_music ()->get_property ("context-id");
- if (ly_c_string_p (ci))
+ if (scm_is_string (ci))
c_id = ly_scm2string (ci);
SCM ops = get_music ()->get_property ("property-operations");
void
Custos_engraver::process_acknowledged_grobs ()
{
- if (ly_c_string_p (get_property ("whichBar")))
+ if (scm_is_string (get_property ("whichBar")))
custos_permitted = true;
if (custos_permitted)
if (ly_c_symbol_p (style))
note->set_property ("style", style);
- if (ly_c_string_p (script))
+ if (scm_is_string (script))
{
Item *p = make_item ("Script", ev->self_scm ());
bool follow;
/*
FIXME: use get_markup () to check type.
*/
- if (ly_c_string_p (s) || ly_c_pair_p (s))
+ if (scm_is_string (s) || ly_c_pair_p (s))
{
cresc_->set_property ("edge-text",
scm_cons (s, scm_makfrom0str ("")));
*/
SCM s = get_property ("midiInstrument");
- if (!ly_c_string_p (s))
+ if (!scm_is_string (s))
s = get_property ("instrument");
- if (!ly_c_string_p (s))
+ if (!scm_is_string (s))
s = scm_makfrom0str ("piano");
{
Font_metric *fm = unsmob_metrics (font);
SCM_ASSERT_TYPE (fm, font, SCM_ARG1, __FUNCTION__, "font-metric");
- SCM_ASSERT_TYPE (ly_c_string_p (name), name, SCM_ARG2, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (name), name, SCM_ARG2, __FUNCTION__, "string");
Stencil m = fm->find_by_name (ly_scm2string (name));
Modified_font_metric*fm = dynamic_cast<Modified_font_metric*>
(unsmob_metrics (font));
SCM_ASSERT_TYPE (fm, font, SCM_ARG1, __FUNCTION__, "modified font metric");
- SCM_ASSERT_TYPE (ly_c_string_p (text), text, SCM_ARG2, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (text), text, SCM_ARG2, __FUNCTION__, "string");
b = fm->text_dimension (ly_scm2string (text));
{
SCM name = ly_assoc_chain (ly_symbol2scm ("font-name"), chain);
- if (!ly_c_pair_p (name) || !ly_c_string_p (ly_cdr (name)))
+ if (!ly_c_pair_p (name) || !scm_is_string (ly_cdr (name)))
{
SCM fonts = paper->lookup_variable (ly_symbol2scm ("fonts"));
name = properties_to_font_size_family (fonts, chain);
else
name = ly_cdr (name);
- if (ly_c_string_p (name))
+ if (scm_is_string (name))
{
SCM mag = ly_assoc_chain (ly_symbol2scm ("font-magnification"), chain);
Real rmag = (ly_c_pair_p (mag)
"Add an interface description.")
{
SCM_ASSERT_TYPE (ly_c_symbol_p (a), a, SCM_ARG1, __FUNCTION__, "symbol");
- SCM_ASSERT_TYPE (ly_c_string_p (b), b, SCM_ARG2, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (b), b, SCM_ARG2, __FUNCTION__, "string");
SCM_ASSERT_TYPE (ly_c_list_p (c), c, SCM_ARG3, __FUNCTION__, "list of syms");
if (!ly_c_vector_p (all_ifaces))
all_ifaces = scm_make_vector (scm_int2num (40), SCM_EOL);
#define SCM_VECTOR_REF(v,i) (SCM_VELTS ((v))[(i)])
#define scm_from_int(x) SCM_MAKINUM (x)
#define scm_is_integer(x) SCM_INUMP (x)
+#define scm_is_string(x) SCM_STRINGP(x)
#define scm_hash_table_p scm_vector_p
+#define scm_i_string_chars(x) SCM_STRING_CHARS(x)
+#define scm_i_string_length(x) SCM_STRING_LENGTH(x)
#endif /* SCM_MINOR_VERSION < 7 */
#ifndef SMOB_FREE_RETURN_VAL
{
Input *ip = unsmob_input (sip);
SCM_ASSERT_TYPE (ip, sip, SCM_ARG1, __FUNCTION__, "input location");
- SCM_ASSERT_TYPE (ly_c_string_p (msg), msg, SCM_ARG2, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (msg), msg, SCM_ARG2, __FUNCTION__, "string");
String m = ly_scm2string (msg);
ip->message (m);
Also create text if barlines in other groups. This allows
a name to be attached to lyrics or chords.
*/
- if (ly_c_string_p (get_property ("whichBar")))
+ if (scm_is_string (get_property ("whichBar")))
create_text ();
}
"Return the expanded path of @var{name}, or"
"@code{#f} if not found.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (name), name, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (name), name, SCM_ARG1, __FUNCTION__, "string");
String nm = ly_scm2string (name);
String filename = global_path.find (nm);
s = s.left_string (s.length () - 1);
SCM sid = lookup_identifier (s);
- if (ly_c_string_p (sid)) {
+ if (scm_is_string (sid)) {
new_input (ly_scm2string (sid), sources_);
yy_pop_state ();
} else {
"Read the file @var{name}, and return its contents in a string. "
"The file is looked up using the search path.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (name), name, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (name), name, SCM_ARG1, __FUNCTION__, "string");
return scm_makfrom0str (gulp_file_to_string (ly_scm2string (name)).to_str0 ());
}
char *
ly_scm2newstr (SCM str, size_t *lenp)
{
- SCM_ASSERT_TYPE (ly_c_string_p (str), str, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (str), str, SCM_ARG1, __FUNCTION__, "string");
size_t len = SCM_STRING_LENGTH (str);
if (char *new_str = (char *) malloc ((len + 1) * sizeof (char)))
"Scheme callable function to issue the warning @code{msg}. "
"The message is formatted with @code{format} and @code{rest}.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (str), str, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (str), str, SCM_ARG1, __FUNCTION__, "string");
progress_indication ("\n");
str = scm_simple_format (SCM_BOOL_F, str, rest);
"Scheme callable function to issue the warning @code{msg}. "
"The message is formatted with @code{format} and @code{rest}.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (str), str, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (str), str, SCM_ARG1, __FUNCTION__, "string");
progress_indication ("\n");
str = scm_simple_format (SCM_BOOL_F, str, rest);
1, 0, 0, (SCM font_family),
"Add pango afm decoder for FONT-FAMILY.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (font_family), font_family, SCM_ARG1,
+ SCM_ASSERT_TYPE (scm_is_string (font_family), font_family, SCM_ARG1,
__FUNCTION__, "font_family");
pango_fc_afm_add_decoder (ly_scm2newstr (font_family, 0));
return SCM_UNSPECIFIED;
1, 0, 0, (SCM string),
"Gettext wrapper.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (string), string, SCM_ARG1,
+ SCM_ASSERT_TYPE (scm_is_string (string), string, SCM_ARG1,
__FUNCTION__, "string");
return scm_makfrom0str (gettext (scm_i_string_chars (string)));
}
Lily_lexer::set_identifier (SCM name, SCM s)
{
SCM sym = name;
- if (ly_c_string_p (name))
+ if (scm_is_string (name))
sym = scm_string_to_symbol (name);
if (ly_c_symbol_p (sym))
"Parse a single @code{.ly} file. "
"Upon failure, throw @code{ly-file-failed} key.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (name), name, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (name), name, SCM_ARG1, __FUNCTION__, "string");
char const *file = scm_i_string_chars (name);
char const *extensions[] = {"ly", "", 0};
"Parse the string LY_CODE. "
"Upon failure, throw @code{ly-file-failed} key.")
{
- SCM_ASSERT_TYPE (ly_c_string_p (ly_code), ly_code, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (ly_code), ly_code, SCM_ARG1, __FUNCTION__, "string");
Sources sources;
sources.set_path (&global_path);
Lily_parser *parser = unsmob_my_lily_parser (parser_smob);
SCM_ASSERT_TYPE (parser, parser_smob, SCM_ARG1, __FUNCTION__, "parser");
- SCM_ASSERT_TYPE (ly_c_string_p (ly_code), ly_code, SCM_ARG2, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (ly_code), ly_code, SCM_ARG2, __FUNCTION__, "string");
parser->parse_string (ly_scm2string (ly_code));
SCM voice_name = lyrics->get_property ("associatedVoice");
String nm = lyrics->id_string ();
- if (ly_c_string_p (voice_name))
+ if (scm_is_string (voice_name))
nm = ly_scm2string (voice_name);
else
{
{
// FIXME: won't work with fancy lyrics
if (lreqs_.size ()
- && ly_c_string_p (lreqs_[0]->get_property ("text"))
+ && scm_is_string (lreqs_[0]->get_property ("text"))
&& ly_scm2string (lreqs_[0]->get_property ("text")).length ())
{
audio_ = new Audio_text (Audio_text::LYRIC,
if (ly_c_symbol_p (coding))
coding = scm_symbol_to_string (coding);
- String scheme = ly_c_string_p (coding) ? ly_scm2string (coding) : "";
+ String scheme = scm_is_string (coding) ? ly_scm2string (coding) : "";
Modified_font_metric *sfm = new Modified_font_metric (scheme, m, s);
= ly_scm2int (get_property ("currentBarNumber"));
}
- bar_seen_ = ly_c_string_p (get_property ("whichBar"));
+ bar_seen_ = scm_is_string (get_property ("whichBar"));
}
void
Music* m = unsmob_music (s);
SCM nm = m->get_property ("name");
- if (ly_c_symbol_p (nm) || ly_c_string_p (nm))
+ if (ly_c_symbol_p (nm) || scm_is_string (nm))
scm_display (nm, p);
else
scm_puts (classname (m),p);
"for creating music objects. "
)
{
- SCM_ASSERT_TYPE (ly_c_string_p (type), type, SCM_ARG1, __FUNCTION__, "string");
+ SCM_ASSERT_TYPE (scm_is_string (type), type, SCM_ARG1, __FUNCTION__, "string");
SCM s = make_music (ly_scm2string (type))->self_scm ();
unsmob_music (s)->immutable_property_alist_ = props;
scm_gc_unprotect_object (s);
SCM voice_name = lyricsto_voice_name_;
SCM running = lyrics_context_ ? lyrics_context_->get_property ("associatedVoice") : SCM_EOL;
- if (ly_c_string_p (running))
+ if (scm_is_string (running))
voice_name = running;
- if (ly_c_string_p (voice_name)
+ if (scm_is_string (voice_name)
&& (!music_context_ || ly_scm2string (voice_name) != music_context_->id_string ()))
{
/*
SCM voice_name = get_music ()->get_property ("associated-context");
String name;
- if (ly_c_string_p (voice_name))
+ if (scm_is_string (voice_name))
name = ly_scm2string (voice_name);
get_music ()->origin ()->warning (_f ("cannot find Voice `%s'",
{
finished_= span_;
span_ = 0;
- if (ly_c_string_p (ott))
+ if (scm_is_string (ott))
{
span_ = make_spanner ("OttavaBracket", SCM_EOL);
span_->set_property ("text", ott);
{
Paper_outputter *po = unsmob_outputter (outputter);
SCM_ASSERT_TYPE (po, outputter, SCM_ARG1, __FUNCTION__, "Paper_outputter");
- SCM_ASSERT_TYPE (ly_c_string_p (str), str, SCM_ARG1, __FUNCTION__, "Paper_outputter");
+ SCM_ASSERT_TYPE (scm_is_string (str), str, SCM_ARG1, __FUNCTION__, "Paper_outputter");
return po->dump_string (str);
}
/* FIXME: should find out uniqueXXX name from music */
SCM name = $1->get_property ("context-id");
//if (name == SCM_EOL)
- if (!ly_c_string_p (name))
+ if (!scm_is_string (name))
name = scm_makfrom0str ("");
SCM context = scm_makfrom0str ("Lyrics");
| script_abbreviation {
SCM s = THIS->lexer_->lookup_identifier ("dash" + ly_scm2string ($1));
Music *a = MY_MAKE_MUSIC ("ArticulationEvent");
- if (ly_c_string_p (s))
+ if (scm_is_string (s))
a->set_property ("articulation-type", s);
else THIS->parser_error (_ ("Expecting string as script definition"));
$$ = a;
int
Lily_lexer::try_special_identifiers (SCM *destination, SCM sid)
{
- if (ly_c_string_p (sid)) {
+ if (scm_is_string (sid)) {
*destination = sid;
return STRING_IDENTIFIER;
} else if (ly_c_number_p (sid)) {
ly_c_symbol_p (type) ? type : scm_string_to_symbol (type));
csm->set_property ("property-operations", ops);
- if (ly_c_string_p (id))
+ if (scm_is_string (id))
csm->set_property ("context-id", id);
return csm;
}
"Convert the contents of a PFB file to PFA."
)
{
- SCM_ASSERT_TYPE(ly_c_string_p (pfb_path), pfb_path,
+ SCM_ASSERT_TYPE(scm_is_string (pfb_path), pfb_path,
SCM_ARG1, __FUNCTION__, "string");
String path = ly_scm2string (pfb_path);
}
}
- if (ly_c_string_p (s))
+ if (scm_is_string (s))
{
String propname = String (p->name_) + "Pedal";
*/
SCM wb = get_property ("whichBar");
SCM db = get_property ("defaultBarType");
- if (!ly_c_string_p (wb) || ly_c_equal_p (db, wb))
+ if (!scm_is_string (wb) || ly_c_equal_p (db, wb))
{
- if (s != "" || (volta_found && !ly_c_string_p (wb)))
+ if (s != "" || (volta_found && !scm_is_string (wb)))
{
context ()->set_property ("whichBar", scm_makfrom0str (s.to_str0 ()));
}
+ "\n" +_ ("Music font has not been installed properly. Aborting"));
SCM pfa_path = ly_kpathsea_expand_path (scm_makfrom0str ("ecrm10.pfa"));
- if (!ly_c_string_p (pfa_path))
+ if (!scm_is_string (pfa_path))
error (_f ("can't find `%s'", "ecrm10.pfa")
+ "\n" +_f ("Install the ec-mftraced package from %s. Aborting",
"http://lilypond.org/download/fonts/"));
{
Global_context *g = dynamic_cast<Global_context*> (unsmob_context (context));
SCM_ASSERT_TYPE (g, context, SCM_ARG1, __FUNCTION__, "Global context");
- SCM_ASSERT_TYPE (ly_c_string_p (outname), outname, SCM_ARG2, __FUNCTION__, "output filename");
+ SCM_ASSERT_TYPE (scm_is_string (outname), outname, SCM_ARG2, __FUNCTION__, "output filename");
Music_output *output = g->get_output ();
progress_indication ("\n");
if (to_boolean (me->get_paper ()
->lookup_variable (ly_symbol2scm ("debug-slur-quanting")))
- && ly_c_string_p (quant_score))
+ && scm_is_string (quant_score))
{
String str;
SCM properties = Font_interface::text_font_alist_chain (me);
/* glyph may not be a string, when ME is killed by Hara Kiri in
between. */
- if (!ly_c_string_p (glyph))
+ if (!scm_is_string (glyph))
return SCM_EOL;
String glyph_string = ly_scm2string (glyph);
{
SCM gl = me->get_property ("glyph");
- if (ly_c_string_p (gl))
+ if (scm_is_string (gl))
return ;
for (SCM s = me->get_property ("elements");
- !ly_c_string_p (gl) && ly_c_pair_p (s); s = ly_cdr (s))
+ !scm_is_string (gl) && ly_c_pair_p (s); s = ly_cdr (s))
{
gl = unsmob_grob (ly_car (s))
->get_property ("glyph");
}
- if (!ly_c_string_p (gl))
+ if (!scm_is_string (gl))
{
me->suicide ();
return;
// mustn't ask Score for instrument: it will return piano!
SCM minstr = get_property ("midiInstrument");
- if (!ly_c_string_p (minstr)
+ if (!scm_is_string (minstr)
|| ly_scm2string (minstr) == instrument_string_)
return "";
{
SCM glyph = bar_grob->get_property ("glyph");
- String glyph_string = ly_c_string_p (glyph) ? ly_scm2string (glyph) : "";
+ String glyph_string = scm_is_string (glyph) ? ly_scm2string (glyph) : "";
if (glyph_string.left_string (1) == "|" || glyph_string.left_string (1) == ".")
{
SCM sz = Bar_line::get_staff_bar_size (bar_grob->self_scm ());
{
SCM stanza = get_property ("stanza");
- if (ly_c_string_p (stanza) && stanza != last_stanza_)
+ if (scm_is_string (stanza) && stanza != last_stanza_)
{
last_stanza_ = stanza;
me->warning (_f ("flag `%s' not found", font_char));
SCM stroke_style_scm = me->get_property ("stroke-style");
- if (ly_c_string_p (stroke_style_scm))
+ if (scm_is_string (stroke_style_scm))
{
String stroke_style = ly_scm2string (stroke_style_scm);
if (!stroke_style.is_empty ())
Stencil mol;
SCM glyph = e->get_property ("text");
- if (!ly_c_string_p (glyph))
+ if (!scm_is_string (glyph))
return mol.smobbed_copy ();
String text = ly_scm2string (glyph);
/*
UGH UGH
*/
- if (ly_c_string_p (gl) && ly_c_equal_p (gl, scm_makfrom0str ("brace"))
- && ly_c_string_p (my_gl) && ly_c_equal_p (my_gl, scm_makfrom0str ("bracket")))
+ if (scm_is_string (gl) && ly_c_equal_p (gl, scm_makfrom0str ("brace"))
+ && scm_is_string (my_gl) && ly_c_equal_p (my_gl, scm_makfrom0str ("bracket")))
inf.grob_->translate_axis (-0.8, X_AXIS); // ugh
- else if (ly_c_string_p (gl) && ly_c_equal_p (gl, scm_makfrom0str ("bracket"))
- && ly_c_string_p (my_gl) && ly_c_equal_p (my_gl, scm_makfrom0str ("bracket")))
+ else if (scm_is_string (gl) && ly_c_equal_p (gl, scm_makfrom0str ("bracket"))
+ && scm_is_string (my_gl) && ly_c_equal_p (my_gl, scm_makfrom0str ("bracket")))
{
inf.grob_->translate_axis ( -0.8, X_AXIS); // ugh
inf.grob_->set_property ("arch-height",
return SCM_EOL;
SCM s = me->get_property ("glyph");
- if (!ly_c_string_p (s))
+ if (!scm_is_string (s))
return SCM_EOL;
SCM gsym = scm_string_to_symbol (s) ;
SCM_ASSERT_TYPE (paper, paper_smob, SCM_ARG1,
__FUNCTION__, "Paper definition");
- SCM_ASSERT_TYPE (ly_c_string_p (markup), markup, SCM_ARG3,
+ SCM_ASSERT_TYPE (scm_is_string (markup), markup, SCM_ARG3,
__FUNCTION__, "string");
SCM_ASSERT_TYPE (input_encoding == SCM_EOL || ly_c_symbol_p (input_encoding),
input_encoding, SCM_ARG2, __FUNCTION__, "symbol");
if (!ly_c_symbol_p (input_encoding))
{
SCM enc = paper->lookup_variable (ly_symbol2scm ("inputencoding"));
- if (ly_c_string_p (enc))
+ if (scm_is_string (enc))
input_encoding = scm_string_to_symbol (enc);
else if (ly_c_symbol_p (enc))
input_encoding = enc;
SCM
Text_item::interpret_markup (SCM paper_smob, SCM props, SCM markup)
{
- if (ly_c_string_p (markup))
+ if (scm_is_string (markup))
return interpret_string (paper_smob, props, SCM_EOL, markup);
else if (ly_c_pair_p (markup))
{
bool
Text_item::markup_p (SCM x)
{
- return (ly_c_string_p (x)
+ return (scm_is_string (x)
|| (ly_c_pair_p (x)
&& SCM_BOOL_F
!= scm_object_property (ly_car (x),
Moment now = now_mom ();
/* Set the first bar of the score? */
- if (!ly_c_string_p (which))
+ if (!scm_is_string (which))
which = (now.main_part_ || now.main_part_ == last_moment_.main_part_)
? SCM_EOL : scm_makfrom0str ("|");
SCM which = get_property ("whichBar");
/* Set the first bar of the score? */
- if (!ly_c_string_p (which))
+ if (!scm_is_string (which))
which = SCM_EOL;
Moment mp = measure_position ();
->set_property ("measure-length", mlen.smobbed_copy ());
}
- if (!ly_c_string_p (which) && to_boolean (automatic_bars))
+ if (!scm_is_string (which) && to_boolean (automatic_bars))
{
SCM always = get_property ("barAlways");
Output_def *pap = me->get_paper ();
Stencil num;
- if (ly_c_string_p (number) && number_visibility)
+ if (scm_is_string (number) && number_visibility)
{
SCM properties = Font_interface::text_font_alist_chain (me);
SCM snum = Text_item::interpret_markup (pap->self_scm (), properties, number);
SCM glyph = endbar ? endbar->get_property ("glyph") : SCM_EOL;
String str;
- if (ly_c_string_p (glyph))
+ if (scm_is_string (glyph))
str = ly_scm2string (glyph);
else
str = "|";
}
if (volta_span_ &&
- (ly_c_string_p (start_string_) || ly_c_pair_p (start_string_)))
+ (scm_is_string (start_string_) || ly_c_pair_p (start_string_)))
{
warning (_ ("Already have a volta spanner. Stopping that one prematurely."));
}
if (!volta_span_ &&
- (ly_c_string_p (start_string_) || ly_c_pair_p (start_string_)))
+ (scm_is_string (start_string_) || ly_c_pair_p (start_string_)))
{
started_mom_ = now_mom () ;