<code>
element. (I object to having such styles in the theme CSS, indicating that it would cause problems like this. I think some have been removed, but not all.)
You could change the theme CSS, or could use PGcourse.pl
to insert (into every problem that includes PGcourse.pl
) some CSS that overrides the styles for <code>
elements.
Paul's idea is the one I recommend as well. Here are some definitions that implement in-line and multi-line code segments:
$BCODE = MODES(HTML=>'<code style="font-family: Courier">l',TeX=>'\verb'.chr(0x85)); $ECODE = MODES(HTML=>'</code>',TeX=>chr(0x85)); $BPRE = MODES(HTML=>'<pre style="font-family: Courier">',TeX=>'\begin{verbatim}'); $EPRE = MODES(HTML=>'</pre>',TeX=>'\end{verbatim}');which you use as
BEGIN_TEXT This is in-line code: ${BCODE}findZeros()${ECODE} finds the zeros of the function. $PAR Here is multi-line code: $BPRE Line1 of code Line1.1 Line2 $EPRE That's it. END_TEXTThe theme styling may affect these as well, so you might need to specify more style rules, such as
$BCODE = MODES( HTML=>'<code style="font-family: Courier; font-size:inherit; background:transparent; border:0; padding:0">', TeX=>'\verb'.chr(0x85) );to override the ones set in the theme. It would also be possible to use
<tt>
rather than <code>
tags, which might not be styled by the theme (I didn't check).
Davide