| Barry MacDonnell's
Toolbox for WordPerfect
Macros, tips, and
templates for Corel® WordPerfect® for Windows®
| Page updated Sep 12, 2017
| Pleading Setup - a macro to set up a basic Pleading format
Related pages -
Modifying the WordPerfect legal Pleading feature (i.e., the formatting produced by WordPerfect's own Pleading feature; however, some tips are relevant to the Pleading setup macro on this page)
Pleading Setup.wcm is an alternative to WordPerfect's own Pleading.wcm macro (i.e., the Pleading Paper feature and also the Legal Pleading Expert).
It creates a very basic Pleading format for the document using a watermark to produce line numbers outside the left page margin and vertical lines on both sides of the document's text.
There are some significant differences between this macro and the WordPerfect features.
One major difference is that no other formatting is done to the document (e.g., page margins, page numbering, headers or footers, etc.) because different legal jurisdictions can have different requirements. You will need to manually set up these items in the document.
On the other hand, it can number all lines in single-space fashion (even those that appear empty due to extra line spacing) as well number them the same way as the WordPerfect version. (See Tips below for more information.)
It does this using one of two different line numbering options.
Numbering option 1 (the default). Number all lines (1..n) on each page, single spaced in the left margin, including any "empty lines" that might be created by double (or triple) line spacing elsewhere in the main document text. Sometimes this is referred to as "fixed line numbering" or "true line numbering".
With this option, note that any line spacing changes further in the document (i.e., anywhere after the first format codes at the top of the document) must be in whole number sizes (2, 3, etc.) and not in fractional sizes (1.5, etc). Otherwise, the adjacent document text might not line up with the numbers.
Numbering option 2. Number all lines (1..n) on each page in the left margin excluding (ignoring) any "empty lines" that might be created by double (or triple) line spacing elsewhere in the main document text.
This is the same way both the Corel shipping macro Pleading.wcm and the Legal toolbar's Pleading Expert create their line numbers. Pleading Setup.wcm is partly based on that format scheme.
● Play the macro in either a document containing text, or in a new blank document.
A menu will appear [screen shot] with several options that let you omit line numbers to produce just vertical lines on both sides of each page's text, and/or choose to use different styles for the lines (double/single; double/double; single/double; or single/single).
● If you change initial page margins, the initial font or font size,
or the initial line spacing, just play the macro again. A new watermark will
replace the old one.
How it works
Both numbering options above use a WordPerfect watermark
to create the numbers and vertical lines. You can choose which type of
watermark (A or B) to use, as well as several other options, from a pop
[It is worth noting that the program's built-in Pleading feature uses Watermark B. It places that watermark inside the initial opening style in the document ("upstream" from the document's text) which makes it a little hard to find and modify (but it's more immune to accidental deletion). See here for more information as well as how to modify the WordPerfect Pleading feature.]
When the macro is played
it positions the cursor at the top of the document after (to the right
of) any initial format codes. It then stores information about the
font, font size, line spacing, and page margins in effect at that
location. It then creates the chosen watermark with the vertical lines
and line numbering that will appear on all pages in the document.
[Note that that watermark will display unless it is discontinued or replaced by another of the same type; see here for more on watermarks.]
☼ You can play the macro in a new blank document and add various other features such as margins, page numbering, and your firm's name (see the Pleading linked page above for some tips); then save the document as a custom Pleading template. This will give you the basic format for a legal pleading. See here for more information on creating and using custom templates.
Related tip: As is done with the WordPerfect Pleading feature's formatting, you can "hide" the [Watermark] code inside the template's initial [Open Style] code. Just carefully select the code in Reveal Codes and cut it to the clipboard (Ctrl+x). Double-click on the [Open Style] code to edit it, then paste the [Watermark] into the Editor's Contents pane. It will then be more difficult for a user to accidentally delete it from any document spawned by that template.
☼ If the document must have changes to page size or page margins mid-way through the document, it is better to extract those pages to a separate window (or save them to a separate disk file) and then play the macro on the separate document(s). Then you can insert the separate document(s) back into the original document.
☼ The Pleading Setup.wcm macro has some advantages compared to the WordPerfect Pleading feature:
• You can create "fixed" single-line numbering (Option 1 above). This means that all "empty lines" are numbered, even between-line spaces created by increasing line spacing in the document (e.g., double space).
• The [Watermark] code that displays numbers and lines is readily available in Reveal Codes in the main document area, not inside the [Open Style] code, and it can be double-clicked to change it or add things to it in situ -- such as adding a text box outside page margins (see Pleading.html for tips). Also, you can more easily delete the Watermark code to remove the Pleading formatting.
• You can play the macro again if you change the document's initial margins, fonts, or line spacing, and the macro will re-create the Pleading numbers and lines to accommodate the new changes.
• You can optionally adjust the "span" of the vertical lines to display only between the top and bottom margins. The default is to display from (near) the top and bottom edges of the page, the same way WordPerfect's Pleading feature does it.
• You can optionally produce a Pleading without line numbers, and then use WordPerfect's built-in line numbering feature to add them and further customize the Pleading (see next item).
☼ WordPerfect's built-in line numbering feature (Format, Page, Line Numbering) has some advantages compared to the WordPerfect Pleading macro and the Pleading Setup macro, such as being able to -
• use line numbers with a different font face and font size from those used in the main document;
• set line numbers to be continuous (1..n) through the document, not just on each individual page;
• adjust the exact distance from the left edge of the page or from the left margin;
• count (or not count) blank lines (i.e., lines without text but ending in a hard return);
• automatically adjust to changes in the page size and/or page margins; and
• quickly modify line numbering by simply double-clicking on the [Ln Num] code.
Hence, you could use the WordPerfect line numbering feature instead of the Pleading Setup macro's line numbers -- but you can still use the vertical lines.
In either order: (1) Use WordPerfect's line numbering (Format, Page, Line Numbering) to insert the line numbers; and (2) play the Pleading Setup macro without its line numbering.
Note: In contrast, the Pleading Setup macro can number "empty lines" that might be created by double (or triple) line spacing in the main document -- something the WordPerfect line numbering feature cannot do because it does not "see" such lines since they do not end with a hard return or page break.
☼ You can specify your desired default menu values in the User Modification Area at the top of the macro's code (below). Then save the macro with the Save & Compile button on the macro toolbar.
☼ If you have used WordPerfect's own Pleading features and you wish to customize the pleading paper that these features produced, see "Modifying the legal Pleading feature" here.
☼ If you
already have used the line numbering feature in several places (i.e.,
turning it on and off) in a long document, and wish to replace the
formatting of the numbering in all of the existing line numbering
segments, a macro can help. See Footnote 1 below.
Existing line numbering of the same type applied alone in multiple locations in the body text of a document can be removed by using Find and Replace to replace all [Ln Num] codes with <Nothing>. [For more on using Find and Replace, see here.]
But what if you just want to change the line numbering formatting (e.g., a new font of font size, etc.) in all existing line numbering of the same type?
A macro can help, such as this one from my post on WordPerfect Universe (here). It searches for all [Ln Num] codes and when if finds each "On" code it deletes it and then applies new line numbering. (It skips over any line numbering "Off" codes.)
Obviously, this is a global replacement without concern for any existing variations in line numbering format. If you use different line numbering formats in the same document you would need to add some sort of pause-and-examine code to the macro below -- or avoid using the macro altogether.
In this example the numbers will be set in Arial, 6-point, Redline text, along with other typical line numbering formatting. (Instead of using the Redline Attribute, you could omit that line of code and use (e.g.) a light gray with Red:192; Green:192; Blue:192.)
Note that the numbering code segment was recorded into a new macro, which was then edited and the commands were copied into the rest of the macro under the "// ADD NEW..." line. Font Size in points is found with (Points/72), which here is (6/72) or 0.083". Instead of inches you could use (e.g.) points, such as 6p or whatever point size you prefer.
 Be sure to replace the text placeholder in the SearchString() command, as indicated.
 When you play the macro be sure Reveal Codes in open in the document.
 Always make a backup of the document first.
TIP: To copy this code into your WordPerfect program to create a working macro, see here.
// Macro code begins:
SearchString("[Ln Num]") // (<= REPLACE with the actual binary Code with the Codes button. Retain quote marks)
// When found:
If(?LeftCode=4819) DeleteCharPrevious Endif
// ADD NEW (RECORDED) LINE NUMBERING CREATION CODE HERE:
FontFace: "Arial Regular";
Red: 0; Green: 0; Blue: 0; Shade: 100;
MatchSelection // (restore searches to WP default)
Messagebox(;"Finished"; "Processed "+vCount+" items")
// Macro code ends