2 tex-lookup.cc -- implement Tex_lookup
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--1998 Jan Nieuwenhuizen <janneke@gnu.org>
7 Jan Nieuwenhuizen <janneke@gnu.org>
10 #include "tex-lookup.hh"
12 #include "symtable.hh"
14 #include "paper-def.hh"
15 #include "string-convert.hh"
17 #include "file-results.hh"
19 #include "paper-stream.hh"
20 #include "tex-stream.hh"
21 #include "tex-outputter.hh"
23 Tex_lookup::Tex_lookup ()
28 Tex_lookup::Tex_lookup (Lookup const& s)
33 Tex_lookup::Tex_lookup (Symtables const& s)
38 Tex_lookup::~Tex_lookup()
43 Tex_lookup::afm_find (String s) const
45 return Lookup::afm_find (s, String ("\\char%d"));
49 Tex_lookup::atom_p (String s, int n, Box b) const
53 for (int i = 0; i < n; i++)
55 return new Atom (s, b);
59 Tex_lookup::character_str (int i) const
61 return Lookup::character_str (i);
65 Tex_lookup::dashed_slur (Array<Offset> controls, Real thick, Real dash) const
67 return embed (Ps_lookup::dashed_slur (controls, thick, dash));
71 Tex_lookup::embed (Atom a) const
73 a.str_ = "\\embeddedps{\n" + a.str_ + "}";
78 Tex_lookup::hairpin (Real width, bool decresc, bool continued) const
80 return embed (Ps_lookup::hairpin (width, decresc, continued));
84 Tex_lookup::plet (Real dy , Real dx, Direction dir) const
86 return embed (Ps_lookup::plet (dy, dx, dir));
90 Tex_lookup::ps_beam (Real slope, Real width, Real thick) const
92 return embed (Ps_lookup::ps_beam (slope, width, thick));
96 Tex_lookup::slur (Array<Offset> controls) const
98 return embed (Ps_lookup::slur (controls));
102 Tex_lookup::stem (Real y1, Real y2) const
104 return Lookup::stem (y1, y2, "\\kern %\\vrule width % height % depth %");
108 Tex_lookup::text (String style, String text) const
110 return Lookup::text (style, text);
114 Tex_lookup::vbracket (Real &y) const
116 return embed (Ps_lookup::vbracket (y));