Home > MUPEdit
MUPEdit is a convenient front end program for editing and building files for the MUP music typesetting program. All development was done in ActiveState Perl (version 5.8.3) on Windows XP. My purpose in writing this program was to speed up the process of entering and compiling MUP scores.
MUPEdit stores the path names of your MUP program, Postscript Viewer and MIDI file player and runs the required commands to create the Postscript and MIDI files. If compilation errors occur, the MUP error output is displayed in the lower window and the lines in error are highlighted.
Starting the program is just a matter of issuing the command
mupedit -f filename.mup. Here is a screen shot
of MUPEdit immediately following a build. The source file contains
errors, and the line in error is highlighted in red.

Let's take a tour of the interface.
The top of the window contains the menus (File, Edit and Options) and the name of the file currently being edited. When you click on a menu, you will see a dotted line at the top of the options. Click on this dotted line to detach the menu. The menu items are described later.
The large text area is the contents of the MUP file currently being edited. When the file is loaded or saved, the inbuilt colour coding rules are applied. These are fairly simple at present. Text is black, green for comment lines, and red for error lines following a "build". The red lines are reset to black at the next build.
The text area has right-mouse-click menu attached which provides search, copy/paste, and goto-line functionality.

The middle of the window has a Build button that runs the MUP command to create the Postscript and MIDI files. The action is the same as the File > Build menu item. Following a successful build, the Postscript viewer is started if the Display Score menu item is selected. The MIDI file is played if the Play Midi menu item is selected.
Next to the build button are four input fields for passing command line options to the MUP command.-x option and used
to choose a range of measures (bars) to publish. This is useful for checking
the bars of music you are currently preparing. Example: 3,5 produces measures
3, 4 and 5.
-s option and used
to limit the publishing to a subset of staffs. This is useful for
printing parts for music ensembles. Example: 1 produces the first staff
only.
-D option. This is
used to pass macro definitions.
-d 512 to switch on tracing.
You will need to use the File > Log File menu command to view the output.
Refer to page 10 of the MUP User Guide for more information about the usage of these command line options.
The text area at the bottom of the window displays the output of the MUP command following clicking the Build button, but only if errors occur. The line numbers and error message are shown, and the corresponding line numbers are coloured red in the MUP Text area with the field scrolled to the first error.
At the very bottom of the window is a status line showing informational or error messages.
The File menu has the following functions:
test1.mup
will have an associated test1.ps Postscript file, and
test1.mid MIDI file.
The Edit menu commands change the contents of the MUP window.
// bar nn (bar number comments)
are never uncommented. The lines are now coloured black.
em and ebm tags around selected notes.
(Not implemented yet)
The Options menu is used to set the options for automatically displaying the Postscript file and playing the MIDI file following a build.
The mupedit command accepts an optional parameter (-c) to create a new MUP file based on responses to a few questions. This is a very rudimentary "wizard" which allows rapid creation of a score. This step could be done with a fancy GUI interface, but this method is satisfactory for now, until I refine the wizard questions.
Here is the dialog of creating the Sailor's Hornpipe with the command mupedit -c -f hornpipe.mup. The user responses follow the colon (:) and are shown in bold.
> mupgui -c -f hornpipe.mup
Create file requested
Score title: Sailor's Hornpipe
Score subtitle: Old English Air
Composer (to print on right hand side: Arr by Julia Clayton
Time signature, cut, com or N / N, eg 3/4: 4/4
Key signature - eg 0#, 1&, 2&: 0#
How many staffs? 1, 2, 3, 4, etc: 2
Clefs can be treble, treble8, frenchviolin, soprano,
mezzosoprano, alto, tenor, baritone, or bass
Which cleff for staff 1: treble
Which cleff for staff 2: bass
How many bars/measures: 9
You will need Perl installed and the Perl/TK module (already packaged with ActiveState Perl).
Download the mupedit.zip package,
and extract the contents: mupedit.pl, test1.mup
and the README.TXT file. Full installation
instructions can be found in the README.TXT file.
MUPEdit is my learning project for Perl/TK. I will add further menu items and functionality as I learn more about Perl/TK and use MUP for my various music projects.
Charles Cave - 29th May 2005. (Send Email)