Paragraph and character styles.
You can read generally about paragraph and character styles in the help sheets that come with Maple (see Creating Styles for those details). What we want to do in this worksheet is describe some of the predefined styles and most of the user defined styles which are used by the perl script mknotes.pl in preparing the tex file created when a worksheet is exported to LaTeX. This documentation is not complete: We are still adding user defined styles and modifiying mknotes.pl to make use of the styles. So this is only a snapshot. As of 6/9/98, the latest version of mknotes.pl is mknotes54.pl
When a worksheet using these styles is exported to LaTeX, the paragraphs which are in the style Bullet Item (for example) are inserted into the tex file with a \begin{Bullet Item} at the beginning and an \end{Bullet Item} at the end of the paragraph. If some character string is formatted with a character style, say for example, Help Normal, the exported string begins with \QTR{ and ends with }. Here is a sample, with the exported LaTeX following:
This is an example Bullet Item with a String formatted in Help Normal.
\begin{Bullet Item}
This is an example \textbf{Bullet Item} with a \QTR{Help
Normal}{String formatted in Help Normal.}
\end{Bullet Item}
Note that boldface is not a character style. It gets exported as \textbf{ }.
The style file maple2e.sty which must be used (as a package) will process some of these styles, but most of them are ignored, unless something additional is done by the user. The perl script mknotes.pl can be used to activate those exported paragraph styles. For example, it has been written to implement the Bullet Item, and Dash Item styles in LaTeX. For details on how mknotes works, see the mknotes.pl section of the worksheet perls.mws.
These styles can be modified from the Styles option of the format menu. See the help topic on modifying styles
Pre-defined Paragraph styles
There are 18 pre-defined paragraph styles in MapleV5.
Bullet Item, List Item, and Dash Item. These three styles each offset the text a few points to the right. This paragraph is set in the Bullet Item style, as you tell. To change the style of a paragraph, simply put the cursor in the paragraph and then use the mouse to scroll to the style you want in the upper left hand corner of the worksheet. Try this by changing the style of this paragraph to Dash Item.
Heading 1, Heading 2, ..., Heading 4. These 4 styles are used to head up sections, subsections, and subsubsections.
Title and Author styles. These styles are used for the title and author of a worksheet.
Error, Warning, Diagnostic. These styles are used by the Maple program when formatting error messages.
Fixed width, Text Output. These styles are used by the Maple program to format output.
Maple Plot, and Maple Output. Also used by Maple to format output.
User Defined paragraph styles
There are currently 10 or so user defined paragraph styles.
Definition. A point is that which has no breadth or length.
#!perl
print "any last request?";
$line = <STDIN>;
if ($line =~ /^y/i) { print $line;}
exit;
This is a comment.
Pre-defined Character Styles
There are 13 pre-defined character styles. To format a phrase with a character style, use the mouse to color (or select) the phrase, then use the mouse to scroll down to the desired style (in the upper left hand corner of the worksheet.
Hyperlink This style is used to mark hyperlinks. I have trained mknotes.pl to remove leading hyperlinks, such as links to a table of contents worsheet that is often put at the bottom of a worksheet. There are numerous hyperlinks throughout this worksheet.
2d Output, 2d Comment, 2d Input, and 2d Math. These styles are used by the Maple program to format certain character strings. I leave them alone. Below is a phrase which has been formatted with these styles, what it looks like exported to LaTeX, and what it looks like after being massaged by mknotes.pl.
how now brown cow .
\begin{maplegroup}
\QTR{2D Comment}{how} \QTR{2D Input}{now} \QTR{2D Math}{brown} \QTR{2D
Output}{cow}.
\end{maplegroup}
After massage --
{how} {\color[rgb]{1,0,0}now} {brown} {\color[rgb]{0,0,1}cow}.
Help Heading, Help Normal, Maple Input, Output Labels, Plot Title, Plot Text, and Popup. These are also used by Maple. I haven't paid attention to them, yet.
User Defined Character Styles
There are several of these we have defined and there will likely be more. Mknotes.pl is written to preprocess them in the exported LaTeX worksheet.
\QTR{paragraph}{Bookmark or bookmark.} Use this style to mark a
paragraph you have bookmarked from the View Menu. That way the
\QTR{Bookmark}{bookmark} will be visible in the worksheet and also
make it into the index when you export to LaTeX. Here is what the
paragraph looks like after export --
After mknotes.pl is applied to the paragraph, it looks like this --
\paragraph{Bookmark or bookmark.}
Use this style to mark a
paragraph you have bookmarked from the View Menu. That way the
{\color[rgb]{0,.5,0}\index{bookmark}bookmark} will be visible in the worksheet and also
make it into the index when you export to LaTeX. Here is what the
paragraph looks like after export --