<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">% $Id: tex4ht-mathplayer.tex 65 2010-11-17 19:16:45Z karl $
% compile 3 times: latex tex4ht-mathplayer
%            or   xhlatex tex4ht-mathplayer "html,3,sections+"
%
% Copyright (C) 2009-2010 TeX Users Group
% Copyright (C) 1997-2009 Eitan M. Gurari
% Released under LPPL 1.3c+.
% See tex4ht-cpright.tex for license text.

%%%%%%%%%%%%%%%%%% load style files %%%%%%%%%%%%%%%%%%%%%%%%%%

\ifx \HTML\UnDef
   \def\HTML{mathplayer}                   
   \def\CONFIG{\jobname}
   \def\MAKETITLE{\author{Eitan M. Gurari}}         
   \def\next{\input mktex4ht.4ht  \endinput}
   \expandafter\next
\fi

\input{common}
\input{tex4ht-cpright}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\chapter{Preamble}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\&lt;mathplayer\&gt;&lt;&lt;&lt;
% mathplayer.4ht (|version), generated from |jobname.tex
% Copyright (C) 2009-2010 TeX Users Group
% Copyright (C) |CopyYear.2002. Eitan M. Gurari
|&lt;TeX4ht copywrite|&gt;
&gt;&gt;&gt;

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\chapter{Start Here}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%%%%%%%%%%%%%%%%%
\section{Header}
%%%%%%%%%%%%%%%%

\&lt;configure mathplayer Preamble\&gt;&lt;&lt;&lt;
\edef\Preamble{\Preamble,xht}
\Configure{ext}{xht}
&gt;&gt;&gt;

% \Configure{mathml}{m:}


\&lt;dtd lang\&gt;&lt;&lt;&lt;
\expandafter
\ifx \csname a:dtd-lang\endcsname\relax EN\else
  \csname a:dtd-lang\endcsname
\fi
&gt;&gt;&gt;

\&lt;configure mathplayer tex4ht\&gt;&lt;&lt;&lt;
\Configure{DOCTYPE}
       {\HCode{&lt;!DOCTYPE html PUBLIC
                "-//W3C//DTD XHTML 1.1 plus MathML 2.0//|&lt;dtd lang|&gt;"\Hnewline
                "http://www.w3.org/Math/DTD/mathml2/xhtml-math11-f.dtd"\Hnewline
                 [\Hnewline
                     &lt;!ENTITY \% MATHML.prefixed "INCLUDE"&gt;\Hnewline
                     &lt;!ENTITY \% MATHML.prefix "m"&gt;\Hnewline
                 ]\Hnewline
                &gt;\Hnewline }}
\Configure{@BODY}
   {\ifvmode \EndP\fi \IgnorePar\HCode{&lt;script type="text/javascript"&gt;\Hnewline&lt;!--\Hnewline
           |&lt;check for ie 5.5 and mathplayer|&gt;\Hnewline--&gt;\Hnewline
           &lt;/script&gt;\Hnewline
   }\par\ShowPar}
   \Configure{@HTML}
     {xmlns:m="http://www.w3.org/1998/Math/MathML"\Hnewline
%      xmlns:dsi="http://www.dessci.com/mathml" \Hnewline
     }
%\let\dsi:=\empty
&gt;&gt;&gt;


application/xhtml+xml



\&lt;check for ie 5.5 and mathplayer\&gt;&lt;&lt;&lt;
if(   navigator.appName=="Microsoft Internet Explorer"   \Hnewline
   &amp;&amp; navigator.platform=="Win32"                        \Hnewline
){                                                       \Hnewline
  if( parseFloat(navigator.appVersion.substr(            \Hnewline
       navigator.appVersion.indexOf("MSIE ")+5))&gt;="5.5"  \Hnewline
  ){
    try {                                                  \Hnewline
      var oMP = new ActiveXObject("MathPlayer.Factory.1"); \Hnewline
    }                                                      \Hnewline
    catch(e) { alert("Can't find Design Science's MathPalyer" +  \Hnewline
          "(http://www.dessci.com/webmath/mathplayer)");} \Hnewline
  } else {                                                \Hnewline
    alert("Requires MSIE version 5.5 or later");          \Hnewline
} }                                                       \Hnewline
&gt;&gt;&gt;

%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{Wrapping in Tables}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%

The attribute \verb+nowrap="nowrap"+ in table cells prevents
Mathplayer from displaying them its own way, and one gets minimal
cells, overlapped: it ought to be avoided altogether.

\&lt;configure mathplayer tex4ht\&gt;&lt;&lt;&lt;
\Configure{halignTD} {}{}
   {&lt;}{\ifmathml \HCode{ columnalign="left"}\else
        \HCode{ style="text-align:left" }\fi}
   {-}{\ifmathml \HCode{ columnalign="center"}\else
        \HCode{ style="text-align:center" }\fi}
   {&gt;}{\ifmathml \HCode{ columnalign="right"}\else
        \HCode{ style="text-align:right" }\fi}
   {^}{\ifmathml \HCode{ rowalign="top"}\else
        \HCode{ style="vertical-align:top" }\fi}
   {=}{\ifmathml \HCode{ rowalign="baseline"}\else
        \HCode{ style="vertical-align:baseline" }\fi}
   {||}{\ifmathml \HCode{ rowalign="center"}\else
        \HCode{ style="vertical-align:middle" }\fi}
   {_}{\ifmathml \HCode{ rowalign="bottom"}\else
        \HCode{ style="vertical-align:bottom" }\fi}
   {p}{\ifmathml \HCode{ columnalign="left"}\else
        \HCode{ style="text-align:left"}\fi}
   {}
&gt;&gt;&gt;







% %%%%%%%%%%%%%%%%%%%%%
% \section{Cross References}
% %%%%%%%%%%%%%%%%%%%%%

% 

% 

% \&lt;configure mathplayer tex4htNO\&gt;&lt;&lt;&lt;
% \LinkCommand\mtxt:link{\a:mathml maction,%
%    actiontype="link" \dsi: href, id, 
%    class="label"|&lt;mtext ref decoration|&gt;,,}
% \LinkCommand\msp:link{\a:mathml maction,%
%    actiontype="link" \dsi: href, id,
%    class="label"|&lt;mstyle ref decoration|&gt;,,}
% \def\Link{\ifmathml
%      \ifmtext |&lt;end mtext|&gt;\HCode{&lt;/\a:mathml mtext&gt;}%
%               \expandafter\expandafter\expandafter\mtxt:link
%      \else    \expandafter\expandafter\expandafter\msp:link\fi
%    \else \expandafter\M:Link\fi}
% \def\EndLink{\ifmathml 
%      \ifmtext    |&lt;end mtext|&gt;|&lt;end mtext ref decoration|&gt;%
%        \Endmtxt:link \HCode{&lt;\a:mathml mtext\Hnewline 
%                    class="endlabel"&gt;}|&lt;start mtext|&gt;%
%      \else  \HCode{|&lt;end mstyle ref decoration|&gt;&lt;/\a:mathml
%                                maction&gt;&lt;!--endlabel--&gt;}\fi
%    \else \expandafter\M:EndLink\fi}
% &gt;&gt;&gt;

% 

% 

% 

% 

% 

% 
% \&lt;mtext ref decorationNO\&gt;&lt;&lt;&lt;
% &gt;&lt;\a:mathml mtext  mathbackground="yellow"%
% &gt;&gt;&gt;

% \&lt;end mtext ref decorationNO\&gt;&lt;&lt;&lt;
% \HCode{&lt;/\a:mathml mtext&gt;}%
% &gt;&gt;&gt;

% \&lt;mstyle ref decorationNO\&gt;&lt;&lt;&lt;
% &gt;&lt;\a:mathml mstyle  mathbackground="yellow"%
% &gt;&gt;&gt;

% \&lt;end mstyle ref decorationNO\&gt;&lt;&lt;&lt;
% &lt;/\a:mathml mstyle&gt;%
% &gt;&gt;&gt;

% 
% \begin{verbatim}
%  JUST BACKGROUND (one could add colour, and it would be fine to include the
%  labels, if any)
%  &lt;m:mstyle \a:mathml mathbackground="yellow"&gt; &lt;m:maction
%   actiontype="link" \dsi: href="#x1-2r1"  class="label"&gt;&lt;m:mrow
%  &gt;&lt;m:mn&gt;1&lt;/m:mn&gt;&lt;!--tex4ht:ref: equ1 --&gt;&lt;/m:mrow&gt;&lt;/m:maction&gt;&lt;/m:mstyle &gt;

%  HIGHLIGHT ON MOUSEOVER
%  &lt;m:maction
%   actiontype="highlight" \dsi: color="pink" &gt;&lt;m:maction
%   actiontype="link" \dsi: href="#x1-2r1"  class="label"&gt;&lt;m:mtext
%  background="yellow" &gt;1&lt;!--tex4ht:ref:
%  equ1 --&gt;&lt;/m:mtext&gt;&lt;/m:maction&gt;&lt;/m:maction&gt;

%  TOOLTIP CLUE ON MOUSEOVER
%  &lt;m:mrow&gt;
%  &lt;m:maction actiontype="tooltip" &gt;&lt;m:maction
%   actiontype="link" \dsi: href="#x1-2r1"  class="label"&gt;&lt;m:mrow &gt;&lt;m:mn
%  background="yellow" &gt;1&lt;/m:mn&gt;&lt;/m:mrow&gt;&lt;/m:maction&gt;
%  &lt;m:mtext&gt;click to jump!&lt;/m:mtext&gt;
%  &lt;!--tex4ht:ref: equ1 --&gt;&lt;/m:maction&gt;&lt;!--endlabel--&gt;&lt;/m:mrow&gt;

% * &lt;m:mtext m:mathbackground="yellow" &gt; disables background colour in all
%   the (math-)links - this one coming from a typo in mathplayer.4ht, inserting
%   m: before mathbackground;

%   m: also problematic on actiontype
% \end{verbatim}

% \&lt;start mtext\&gt;&lt;&lt;&lt;
% \ht:special{t4ht@,&amp;\#x00A0;}%
% &gt;&gt;&gt;
% \&lt;end mtext\&gt;&lt;&lt;&lt;
% \ht:special{t4ht@,}%
% &gt;&gt;&gt;

% 

% The area of the clickable links can be enlarged with a cpde similar to
% the following one.

% \begin{verbatim}
%   \let\svLink=\Link
%   \let\svEndLink=\EndLink
%   \Odef\Link[#1]#2#3{%
%      \svLink[#1]{#2}{#3}%
%      \ifmathml\ifmtext\else \HCode{&lt;m:mpadded width="4"&gt;}\fi\fi}
%   \def\EndLink{%
%      \ifmathml\ifmtext\else \HCode{&lt;/m:mpadded&gt;}\fi\fi
%      \svEndLink}
% \end{verbatim}


%%%%%%%%%%%%%%%%%%
\section{Namespace Prefixes}
%%%%%%%%%%%%%%%%%%

\&lt;configure mathplayer tex4ht\&gt;&lt;&lt;&lt;
\:CheckOption{xht} \if:Option
\else \:CheckOption{xml} \if:Option
\else
\Configure{DviMath}
   {\a:DviMathML \mathmltrue
      \ifOption{mml-fonts}{}{|%\mml:htfsym|%\NoFonts}%
      \IgnoreRule \HCode{&lt;!--l.
      \the\inputlineno--&gt;}\HCode{&lt;\a:mathml math\Hnewline}%
         |&lt;disable a:mathml for math attr|&gt;%
         \HCode{\csname a:math-xmlns\endcsname \Hnewline \a:@math&gt;}%
      |&lt;end disable a:mathml for math attr|&gt;\a:math
      |&lt;sv dvimath par|&gt;\IgnorePar}
   {\Tg&lt;/\a:mathml math&gt;\EndIgnoreRule
    \ifOption{mml-fonts}{}{|%\ext:htfsym|%\EndNoFonts}%
    \mathmlfalse \b:DviMathML |&lt;recall dvimath par|&gt;}
\fi\fi
&gt;&gt;&gt;


\&lt;recall dvimath par\&gt;&lt;&lt;&lt;
\sv:ignore
&gt;&gt;&gt;

\&lt;sv dvimath par\&gt;&lt;&lt;&lt;
\edef\sv:ignore{\if:nopar  
    \noexpand\IgnorePar\else \noexpand\ShowPar\fi}%
&gt;&gt;&gt;

\&lt;disable a:mathml for math attr\&gt;&lt;&lt;&lt;
\let\sva:mathml=\a:mathml \let\a:mathml=\empty
&gt;&gt;&gt;

\&lt;end disable a:mathml for math attr\&gt;&lt;&lt;&lt;
\let\a:mathml=\sva:mathml 
&gt;&gt;&gt;


%%%%%%%%%%%%%%%%%%
\section{Color}
%%%%%%%%%%%%%%%%%%

\&lt;configure mathplayer color\&gt;&lt;&lt;&lt;
\let\a:txt:textcolor\a:textcolor
\let\b:txt:textcolor\b:textcolor
\Configure{textcolor}
   {\ifmathml 
      \Configure{color}%
         {\Configure{SetHColor}
              {\HCode{&lt;m:mstyle color="\HColor"&gt;}}}%
    \else \a:txt:textcolor \fi
   }
   {\ifmathml \HCode{&lt;/m:mstyle&gt;}\else \b:txt:textcolor \fi}
&gt;&gt;&gt;


\endinput
</pre></body></html>