# How can I put musical clefs in the middle of text?

I'm setting a document that includes some music; I'm using lilypond-book for the musical examples. However, there are some points where the author has inserted a musical symbol in the text; I'm using MusiXTeX for those bits. Notes and accidentals are easy, but I can't find a way to put in just a clef sign. For example, the author says

The G sol re ut clef . . . is made thus, <treble-clef>.

I'd like to have a treble clef right in the text where it says <treble-clef>.

-

Found my own answer after help from Seamus:

The G sol re ut clef . . . is made thus, \begin{music}\trebleclef\end{music}.


That is, of course, after including \usepackage{musixtex} in the header.

-
It is not necessary to surround the \trebleclef command with the music environment. It also works outside. – clemens Jul 23 '14 at 23:18
@clemens This seems not to work for \bassclef, as it is set too low. For example, take a look at the output of pastebin.com/bjQFjWAp – Martin Thoma May 17 '15 at 9:47

There are various packages that allow you to include musical symbols. See p.88 et seq. of the LaTeX comprehensive symbols list.

Weirdly, I'm not actually sure the above document contains the "clef" symbols you want. (I don't actually know the terminology well enough to know if it's there) But if it isn't there, I don't know where you'll find it...

Your best bet might be to try and get musixtex to work inline... Searching musixtex documentation for "inline" gets only one hit, and it's no use...

You could print a pdf of just the symbol, and then \includegraphics it?

-
The document you refer to does not include the symbols I need; I looked at some length. Maybe \includegraphics is my best bet; I can get musixtex to work inline for most symbols, but after I've inserted a clef, it takes everything after that as music. – JasonFruit Oct 13 '10 at 21:02
Is there not an \endmusic command? or something similar. It seems strange that this symbol isn't easily achieved... – Seamus Oct 13 '10 at 21:05
I tried the \endmusic (or \endscore, I don't remember which it is) command, but it did nothing. It also surprises me that it's not easier. – JasonFruit Oct 13 '10 at 21:21
Found it! I should have been preceding it with \begin{music} and following it with \end{music}; \startpiece and \endpiece are not what I needed. – JasonFruit Oct 13 '10 at 21:33

Old thread but people who are looking should know that you could use \usepackage{lilyglyphs} as well. This requires the use of LuaLaTeX or XeLaTeX and is well worth it.

https://www.ctan.org/tex-archive/macros/luatex/latex/lilyglyphs

-