Using Templates

Note

Some illustrations in this section, and throughout the book, are shown with templates not included with OpenOffice.org, which we've created and obtained through the OpenOffice.org team. Many templates are available on the OpenOffice.org CD included with this book.

You can also get old StarOffice 5.2 templates at http://wwws.sun.com/software/star/staroffice/5.2/templates/.


Up to this point in the chapter we've progressed from manually setting specific formatting characteristics to grouping those characteristics into specific styles. Styles are containers for characteristics. This section takes the progression a step further by talking about templates, which are containers for styles.

A template is a document that was created with specific styles that can be used as a model for creating a specific type of document. For example, the program installs with templates to help you create resumes, memos, fax cover sheets, budgets , calendars, newsletters, HTML documents, envelopes, and a bevy of other types of documents.

Templates are even more than containers for styles. They can also contain predefined text, graphics, pagination, work environment settings ( toolbars , keyboard shortcuts, etc.), and other elements that will always be used in a new document of that type.

Creating a Document From a Template

See Creating a Writer Document From a Template on page 176.

If you want to just use the styles from a template, see Loading Styles From Another Document on page 265.

Switching to a Different Template

You can't change to a different template once you've created a document. However, you can bring styles in from another template or document. See Loading Styles From Another Document on page 265.

About the Standard Template

When you start a new Writer document, Writer bases the new document on a template called Standard, which has a standard set of styles and some behind-the-scenes functionality. If you don't like the default style settings provided by the Standard template (for example, if you want to use a different font size for the Text body or heading styles), you can have Writer use another template for new documents.

If all you want to do is start new documents with different font faces than those provided by the Standard template, there's an easy way to change the default standard fonts. See Changing Default Fonts and the Default Template on page 178.

Changing Default Fonts in the Standard Template

These changes apply to Writer's Standard template only.

  1. Select Tools > Options > Text document > Basic Fonts.

  2. Change fonts for the respective types of paragraphs (see Figure 7-61).

    Figure 7-61. Changing the default fonts used by Writer's Standard template

    graphics/07fig61.jpg

Using a Different Template as the Basis for New Documents

The Standard template is used as the basis for every document you create by choosing File > New > Text Document. If you find you always have to change the formatting of your new documents to suit your requirements, it is time to use a separate template, known as the default template .

  1. Create or open a document that contains your favorite Styles and formatting.

  2. Delete the text of the document if you want, so that only the Styles and other settings remain .

  3. Save the document as template by choosing File > Templates > Save. Save it in the Default location. The main directory for the displayed directories is office\ user \template .

  4. Choose File > Templates > Organize.

  5. In the list at the left, double-click Default. The name of the default template you just saved will appear under it. Select the name .

  6. Right-click the name and choose Set as Default Template. Close the window. This template will now be used as the default template when you choose File > New > Text document.

Figure 7-62. Template Management window, specifying a new default template

graphics/07fig62.jpg

Switching Back to the Standard Template for New Documents

If you switched from the Standard template to another template for creating new documents (see previous procedure), use this procedure to switch back to the Standard template.

  1. Choose File > Templates > Organize.

  2. Right-click in either of the list boxes or open the submenu of the Commands button.

  3. Choose Reset Default Template. This command opens a submenu in which you see every document type for which you have selected a default template. Select the document type you want to assign the default settings to.

The Standard template will now be used whenever you start a new Writer document.

Modifying the Characteristics of the Default Style in the Standard Template

When you choose File > New > Text Document, you get a new blank document with one style, Default. It's Thorndale 12-point.

If you want to change this, these are your options:

  • Use a different template as the template that new documents are based on by default. See Using a Different Template as the Basis for New Documents on page 264. In that template, make the styles you want.

  • You can change only the font of the Default style, in the standard template. See Figure 7-61 on page 263.

Loading Styles From Another Document

If you want a document to use styles from another document or a template, you can load all styles or individual styles.

This procedure isn't the same as using a template to create a document. See Creating a Writer Document From a Template on page 176.

Loading All Styles
  1. Start a new document or open the document into which you want to load different styles.

  2. Choose Format > Styles > Load.

  3. In the File type field, select whether you want to load styles from a Writer document or a Writer template.

  4. At the bottom of the window, select the types of styles you want to load, as shown in Figure 7-63.

    Select the Overwrite option to replace the style definitions for styles with the same name. If you don't select Overwrite, style settings with the same name won't be overwritten in the open document.

If you're loading styles from a template, you can also click the Templates button at the bottom of the window to select a template.

If you don't see the styles update automatically in the Stylist, click one of the other style buttons in the Stylist, then click the button of the styles you want to see.

Loading Individual Styles

If you want to load individual styles from one document into another (rather than loading all styles), use the template Organizer.

  1. With Writer active, choose File > Templates > Organize.

    You can also choose Format > Styles > Catalog, and click the Organizer button.

  2. In the Template Management window (Figure 7-64), below each list box, select whether you want to view Document Templates or Documents.

    One list box will be used to copy styles from a document into the document listed in the other list box.

  3. In one list box, double-click the file whose styles you want to use, then double-click the Styles icon below it. The styles used in the document are displayed.

  4. In the other list box, double-click the name and the Styles icon of the document into which you want to load the styles.

  5. Drag the style(s) you want to use from one document to the other. Use Figure 7-64 for guidance on using the Template Management window.

Creating a Template

Creating a template isn't much more than formatting a document, adding boilerplate content to it if you want, and saving it in template format.

If all you want to use a template for is to automatically insert boilerplate stuff like a company logo and address for a letterhead, you can also use the AutoText feature. See Creating and Inserting AutoText on page 180.

  1. Create a document, adding any styles, formatting, graphics, tables, and any other content you want to use for a template.

  2. Choose File > Templates > Save.

  3. In the Document Templates window, enter new name for template. See Figure 7-65.

    Figure 7-65. Creating a new template in the Document Templates window

    graphics/07fig65.jpg

  4. Select a template category in which you want to store the template. (To create your own template category, see Creating a Template Category on page 269.)

  5. Click OK. The template is ready to use.

Editing Templates

If you edit one of the default templates, you might notice that it uses a handful of automated fields. For help on fields, see Chapter 9, Headers, Footers, and Fields , on page 281.

  1. With Writer active, choose File > Templates > Organize.

  2. In the Document Templates window, select Document Templates in the field at the bottom of the window.

  3. Double-click the folder containing the template you want to edit.

  4. Select the template you want to edit.

  5. Click the Commands button and choose Edit.

  6. Modify and save the template.

If you want to edit a template that isn't stored in a template folder, you can edit it by choosing File > Templates > Edit and double-clicking the template you want.

Importing and Exporting Templates in the Organizer

Importing and exporting templates is simply a way of moving template files into and out of the template folders.

This procedure shows you how to import and export templates using the Organizer.

Importing a Template to a Category
  1. With Writer active, choose File > Templates > Organize.

  2. In the Document Templates window, choose Document Templates in the field at the bottom of the window.

  3. Select the template folder into which you want to import the template.

  4. Click the Commands button and choose Import Template.

  5. Locate and double-click the template you want to import.

Exporting a Template to a Different Category
  1. With Writer active, choose File > Templates > Organize.

  2. In the Document Templates window, select Document Templates in the field at the bottom of the window.

  3. Double-click the category containing the template you want to export.

  4. Select the template you want to export.

  5. Click the Commands button and choose Export Template.

  6. In the Save As window, navigate to the folder to which you want to export the template.

  7. Click Save.

Importing Microsoft Office Templates

See Converting Microsoft Office and StarOffice 5.2 Documents on page 161.

Organizing Templates

In addition to letting you edit, import, and export templates, and share styles between documents, the Document Templates Organizer lets you create template categories.

Note

Until you've created some templates, converted templates, or brought in the templates provided on the OpenOffice.org CD included with this book, you won't need to use this procedure.


Creating a Template Category

This procedure shows you how to create a template category using the Organizer.

  1. With Writer active, choose File > Templates > Organize.You can also choose Format > Styles > Catalog, and click the Organizer button.

  2. Select Document Templates in the field at the bottom of the window.

  3. Select any of the template folders.

  4. Click the Commands button and choose New.

  5. A new Untitled folder is displayed with the name highlighted. Type the name of the new template category.

Moving Templates to Different Categories

This procedure shows you how to move templates to different categories using the Organizer.

  1. With Writer active, choose File > Templates > Organize.

    You can also choose Format > Styles > Catalog, and click the Organizer button.

  2. Select Document Templates in the field at the bottom of the window.

  3. Double-click the folder containing the template you want to move.

  4. Hold down the Shift key and drag the template you want to move into another category folder.

    If you don't hold down the Shift key while you drag, you copy the template rather than move it.

Deleting Templates and Template Categories
  1. With Writer active, choose File > Templates > Organize.

    You can also choose Format > Styles > Catalog, and click the Organizer button.

  2. Select Document Templates in the field at the bottom of the window.

  3. Select the category folder or template you want to delete.

  4. Click the Commands button and choose Delete.

  5. Click Yes in the confirmation window.

Editing Values of Fields in Business Correspondence Templates

See Setting Up Fixed Data for Business Cards or Labels on page 363 and Creating and Inserting Predefined Information Using Fields on page 284.



OpenOffice. org 1.0 Resource Kit
OpenOffice.Org 1.0 Resource Kit
ISBN: 0131407457
EAN: 2147483647
Year: 2005
Pages: 407

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net