1 // utility functions for PScore
10 for (PCursor
<PCol
*> c(cols
); c
.ok(); )
13 mtor
<< "removing pcol\n";
20 PScore::add(PStaff
*s
)
22 staffs
.bottom().add(s
);
26 PScore::typeset_item(Item
*i
, PCol
*c
, PStaff
*s
, int breakstat
)
29 if (breakstat
== 1 ) {
30 typeset_item(i
, c
->prebreak
, s
, 0);
32 typeset_item(i
, c
->prebreak
, s
, 0 );
41 PScore::add_line(svec
<const PCol
*> curline
, svec
<Real
> config
)
43 Line_of_score
*p
= new Line_of_score(curline
,this);
44 lines
.bottom().add(p
);
45 for (int i
=0; i
< curline
.sz(); i
++){
46 PCol
*c
=(PCol
*)curline
[i
]; // so, this isn't really const.
52 PScore::get_spacing(PCol
*l
, PCol
*r
)
55 for (PCursor
<Idealspacing
*> ic (suz
); ic
.ok(); ic
++) {
56 if (ic
->left
== l
&& ic
->right
== r
){
61 Idealspacing
*ip
=new Idealspacing(l
,r
);
63 // l->used = r->used = true;
68 PScore::find_breaks() const
70 svec
<const PCol
*> retval
;
71 for (PCursor
<PCol
*> c(cols
); c
.ok(); c
++)
88 linewidth
= 15; // in cm for now
92 PScore::output(Tex_stream
&ts
)
95 ts
<< "% linewidth " << linewidth
* HOR_TO_PT
<< " pt\n";
96 for (PCursor
<Line_of_score
*> lic(lines
); lic
.ok(); lic
++) {
97 ts
<< "% line of score no. " << l
++ <<"\n";
98 ts
<< lic
->TeXstring();
100 ts
<< "\\interscoreline\n";