-
Notifications
You must be signed in to change notification settings - Fork 0
/
musixdoc.sty
166 lines (136 loc) · 5.14 KB
/
musixdoc.sty
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{chenmusixdox}[04/07/2018 CAMK by Chen]
%
% This file is part of MusiXTeX
%
% MusiXTeX is free software; you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
% the Free Software Foundation; either version 2, or (at your option)
% any later version.
%
% MusiXTeX is distributed in the hope that it will be useful,
% but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
% GNU General Public License for more details.
%
% You should have received a copy of the GNU General Public License
% along with MusiXTeX; see the file COPYING. If not, write to
% the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
% Boston, MA 02111-1307, USA.
%
%
\usepackage{CJKutf8}
\usepackage[papersize={210mm,11in},margin=1.125in]{geometry} % a4 width, letter-paper height
\pagestyle{headings}
\usepackage{makeidx}
\usepackage{multicol}
\usepackage{etex}
\usepackage{amssymb}
\usepackage{xcolor}
\usepackage{CJKutf8}
\newcommand{\myurl}[1]{\textcolor{blue}{\underline{\textcolor{black}{\url{#1}}}}}
\newcommand{\musixflxVersion}{0.83.3}
\newcommand{\comment}[1]{}
\newcommand{\chen}[1]{\textcolor{purple}{#1}}
\newcommand{\cmd}[1]{\textcolor{blue}{\texttt{\$ #1}}}
\newcommand{\songt}[1]{
\begin{CJK}{UTF8}{gbsn}
#1
\end{CJK}}
\newcommand{\kai}[1]{
\begin{CJK}{UTF8}{gkai}
#1
\end{CJK}}
\newcommand\Red{\color{red}}
%\usepackage{indentfirst}
\usepackage{mflogo}
%\usepackage[ansinew]{inputenc}
% default is Computer Modern OT1 encoding
\usepackage[T1]{fontenc} % for CM, \input musixec after musixtex
\usepackage[osf]{mathpazo} % Palatino text, with old-style figures; use $n$ for lining figures
%\usepackage{mathptmx} % Times text
%\usepackage{helvet}\renewcommand{\familydefault}{\sfdefault} % Helvetica text
% use OT1 encoding for tt to avoid need for cm-super fonts
\renewcommand{\ttfamily}{\fontencoding{OT1}\fontfamily{cmtt}\selectfont}
\usepackage{textcomp}
\input musixtex
\input musixbm
\input musixcho
\input musixdat
\input musixext
\input musixgre
\input musixgui
\input musixlit
\input musixltx
\input musixper
%%% \input musixps deferred to Section 10.2
%\input musixec % EC (Computer Modern) text in music
\input musixplt % Palatino text in music
%\input musixtmr % Times text in music
%\input musixhv % Helvetica text in music
\usepackage{paralist}
\setlength{\pltopsep}{1pt plus 2pt minus 1pt}
\setlength{\plitemsep}{4.5pt plus 2pt minus 1pt}
\renewenvironment{enumerate}{\begin{compactenum}}{\end{compactenum}}
\renewenvironment{itemize}{\begin{compactitem}}{\end{compactitem}}
\renewenvironment{description}{\begin{compactdesc}}{\end{compactdesc}}
\setcounter{tocdepth}{1}
\setcounter{secnumdepth}{2}
% more place for section numbers in \tableofcontents
\usepackage{tocloft}
\setlength{\cftsecnumwidth}{3.0em}
\renewcommand{\chaptermark}[1]{\markboth{\itshape Chapter \thechapter. #1}{}}
\renewcommand{\sectionmark}[1]{\markright{\itshape\thesection. #1}}
\usepackage[colorlinks=true]{hyperref}
\nobarnumbers
\def\st@ffs{1}
% for usage of notes inside text
\let\nblines\z@
\def\notesintext#1{% no staff lines, no clefs
{\let\extractline\relax
\setlines10\smallmusicsize \nobarnumbers \nostartrule
\staffbotmarg0pt \setclefsymbol1\empty \global\clef@skip0pt
\startextract\addspace{-\afterruleskip}#1\zendextract}}
\def\musicintext#1#2{% normal
{\let\extractline\relax
\smallmusicsize \nobarnumbers
\staffbotmarg0pt \setclef1{#1}
\startextract\addspace{-\afterruleskip}#2\endextract}}
% macro adapted to insert music without clef:
\def\musicintextnoclef#1{% no clef small
{\let\extractline\relax
\smallmusicsize \nobarnumbers
\staffbotmarg0pt \setclefsymbol1\empty
\startextract\addspace{-\afterruleskip}#1\endextract}}
\def\musicintextnoclefn#1{% no clef normal
{\let\extractline\relax
\nobarnumbers
\staffbotmarg0pt \setclefsymbol1\empty
\startextract\addspace{-\afterruleskip}#1\endextract}}
\def\musictex{Music\TeX{}}
\def\onen{{\ttfamily\char123}$n${\ttfamily\char125}}
\def\pitchp{{\ttfamily\char123}$p${\ttfamily\char125}}
\def\itbrace#1{{\ttfamily\char123}$#1${\ttfamily\char125}}
\def\nochange{{\ital{NOT to be changed}}}
\ifx\setendvolta\undefined\def\setendvolta{\endvolta}\fi
\ifx\setendvoltabox\undefined\def\setendvoltabox{\endvoltabox}\fi
\def\tty{\csname normalshape\endcsname\csname mediumseries\endcsname\ttfamily}
\def\mutex{M\raise\tw@\p@\hbox{\kern\m@ne\p@ u\kern\m@ne\p@}\TeX}
\def\Bslash{\ttfamily\char'134}
\def\|{\texttt{\char'174}}
\def\LBR{\texttt{\char'173}}
\def\RBR{\texttt{\char'175}}
\def\keyindex#1{\leavevmode
\hbox{{\Bslash #1}}\index{#1@{\protect\small\protect\Bslash #1}}}
\def\zkeyindex#1{\index{#1@{\protect\small\protect\Bslash #1}}}
\def\ixem#1{#1\index{#1}}
\def\itxem#1{\textit{#1}\index{#1}}
\def\ttxem#1{\texttt{#1}\index{#1@\texttt{#1}}}
\def\ixtt#1{\index{#1@\texttt{#1}}}
\def\ital#1{\textit{#1\/}}
\def\enpee{{\ttfamily{\char123$n$\char125\char123$p$\char125}}}
\def\unix{\textsc{unix}}
\sloppy
\def\underscoreSymbol{\leavevmode \kern.06em \vbox{\hrule width.3em}}%
\def\_{\protect\underscoreSymbol}
\endinput