Chapter 16 Report Generation

HTML Report

HTML Report Dialog

Generate HTML Report

Defining Image Quality

Defining Header/Footer

Defining the content

Defining the alignment

Defining the font

Defining Document Info

PDF Report

PDF Report Dialog

Generate PDF Report

Defining Image Quality

Defining the page information

Defining the Page size

Defining the Page orientation

Adjusting the Page Margin

Defining Header/Footer

Defining the Header/Footer Style

Defining the content

Defining the alignment

Defining the font

Defining Document Info

Previewing the document

Navigating the preview report

Viewing the preview report

Saving the preview report

         


Chapter 16  Report Generation

VP-UML supports HTML and PDF report generation. It can convert all the diagrams in the projects into HTML or PDF format, together with a navigation menu. This facility allows users to publish their VP-UML project. This chapter discusses how to use the documentation generation facility to create the report for the VP-UML project.

 

Figure 16.1 Example of a generated HTML report


Figure 16.2 Example of a preview generated PDF report


HTML Report

 

Figure 16.3 Example of a generated HTML report

 

HTML Report Dialog

 

There are two methods to open the HTML Report generation dialog:

 

Method 1 – Open the dialog using menu bar.

 

1.      Click on Tools on the menu bar. The tools menu appears.

2.      Click on Report on the tools menu.

3.      Click on HTML… on the report menu.

 

Method 2 – Open the dialog using the toolbar.

 

1.      Click on the Generate HTML Report button  on the toolbar.

 

A HTML Report dialog will be displayed for you to specify the options for generate the report (Figure 16.4).

 

Figure 16.4 - Generate HTML Report Dialog

 

Field

Functionality

File Location

To select the destination directory for the generated report. You can type in the path in the text field or browse the location using the  button.

Launch Viewer

If this option was selected, the default browser of the system will be open automatically to show the generated document.

Show Diagrams

If this option was selected, the image of the selected diagrams will be generated to the report.

Show Model’s File/URL Link

The defined file and URL link in the project will be generated if this option was selected.

Show Empty Tree Node

If this option was selected, the diagram node will be generated in the navigate tree even no diagram was selected.

Template

Select the template for generating the report.

Graphic Antialiasing

To enable/disable the graphic antialiasing of the diagram images.

Text Antialiasing

To enable/disable the text antialiasing of the diagram images.

Print Diagrams

To select which diagram will be generated in the output document.

 

Generate HTML Report

 

To generate the HTML Report:

 

1.      Open the Generate HTML Report dialog.

2.      Enter the destination location of the generated document.

 

Figure 16.5 - Selecting destination location for the output HTML report.

 

3.      Select the report properties, such as Show Diagrams, Show Model’s File/URL Link, etc…

4.      Select the template of the report that will be generated.

5.      Select the diagram’s image quality if the Show Diagrams was selected.

6.      Define advance report information such as Header/Footer and Document Info.

7.      Select the diagram to generate to the report.

8.      Press the Generate button to start report generation.

 

 

Figure 16.6 - Generating HTML report.

 

Figure 16.7 – The detail pane of the dialog showing that the report generation was finish.

 

 

Figure 16.8 - The message pane showing that the HTML report generation was success.

 

Figure 16.9 - The HTML report was generated to the destination location.

 

 

Figure 16.10 - The output HTML documentation.

 

 

Defining Image Quality

 

There are two image quality options for the HTML Report: graphics and text antialiasing. To enable the antialiasing options just click check the antialiasing options check box.

 

Figure 16.11 - HTML Report with antialiasing options selected.

 

Figure 16.12 - HTML Report with antialiasing options not selected.

 

 

Defining Header/Footer

 

To define the Header/Footer of the document:

 

1.      Open the Generate HTML Report dialog.

2.      Select the Header/Footer tab.

3.      Check Use Header / Use Footer CheckBox to make the report use header/footer.

 

Figure 16.13 – Defining Header/Footer.

 

 

Field

Functionality

Header

Use Header

To indicate the output HTML document will use header or not.

Alignment

The alignment (Left/Center/Right) of the header.

Header Text 1

The content of the header.

Font Name

The font type of the header.

Font Style

The font style of the header.

Font Size

The font size of the header.

Font Color

The font color of the header.

Footer

Use Footer

To indicate the output HTML document will use footer or not.

Alignment

The alignment (Left/Center/Right) of the footer.

Footer Text 1

The content of the footer.

Font Name

The font type of the footer.

Font Style

The font style of the footer.

Font Size

The font size of the footer.

Font Color

The font color of the footer.

Preview

The preview of the header/footer.

 

 

Defining the content

 

To define the header content, fill in the text in the Header Text 1/Footer Text 1 text field.

 

Figure 16.14 – Defining the content of the header.

 

 

Figure 16.15 – The output header.

 

 

Defining the alignment

 

Select the alignment options (Left/Center/Right) from the Alignment Combo Box. The preview of the alignment will be show in the preview area on the right hand side of the dialog.

 

Figure 16.16 - Defining alignment of the header.

 

Figure 16.17 - The output header align to left side.

 

 

Defining the font

 

To change the font type, select the font from the Font Name Combo box.

 

Figure 16.18 - Defining the font type for the header.

To change the font style, select the style from the Font Style Combo box.

 

Figure 16.19 - Defining the font style of the header.

 

To change the font size, select the size from the Font Size Combo box.

 

Figure 16.20 - Defining the font size of the header.

 

To change the font color, press the  button in the Font Color field, a color chooser dialog will be displayed. Select the color you want and click the OK button.

 

Figure 16.21 - Defining the font color of the header.

 

Figure 16.22 - The result header of the report.

 

 

 

Defining Document Info

 

To define the document info:

 

1.      Open the Generate HTML dialog.

2.      Select the Document Info tab.

 

Figure 16.23 –Defining Document Info.

 

 

Field

Functionality

Title

The title of the output HTML document.

Author

The author of the output HTML document.

Keywords

The keywords meta-tag of the output HTML document.

 

Figure 16.24 - The title of the HTML report.

 

PDF Report

 

Figure 16.25 Example of a preview generated PDF report

 

PDF Report Dialog

There are two methods to open the PDF Report generation dialog:

 

Method 1 – Open the dialog using menu bar.

 

4.      Click on Tools on the menu bar. The tools menu appears.

5.      Click on Report on the tools menu.

6.      Click on PDF… on the report menu.

 

Method 2 – Open the dialog using the toolbar.

 

2.      Click on the Generate PDF Report button  on the toolbar.

 

A PDF Report dialog will be displayed for you to specify the options for generate the report

 

Figure 16.26 – Generate PDF dialog.

 

 

Field

Functionality

File Location

To select the destination directory for the generated report. You can type in the path in the text field or browse the location using the  button.

Launch Viewer

If this option was selected, the default browser of the system will be open automatically to show the generated document.

Show Diagrams

If this option was selected, the image of the selected diagrams will be generated to the report.

Show Model’s File/URL Link

The defined file and URL link in the project will be generated if this option was selected.

Template

Select the template for generating the report.

Graphic Antialiasing

To enable/disable the graphic antialiasing of the diagram images.

Text Antialiasing

To enable/disable the text antialiasing of the diagram images.

Diagram Quality

To select the image quality of the diagrams in the output PDF document.

Print Diagrams

To select which diagram will be generated in the output document.

 

Generate PDF Report

 

To generate the PDF Report:

 

1.      Open the Generate PDF Report dialog.

2.      Enter the destination location of the generated document.

Figure 16.27 – Selecting destination location for the output PDF report.

 

3.      Select the report properties, such as Show Diagrams, Show Model’s File/URL Link, etc…

4.      Select the template of the report that will be generated.

5.      Select the diagram’s image quality if the Show Diagrams was selected.

6.      Define the paper for the output document.

7.      Define advance report information such as Header/Footer and Document Info.

8.      Select the diagram to generate to the report.

 

Figure 16.28 - The generating PDF document dialog.

 

9.      When the process was finish, you can see a message when you open the detail pane of the generating PDF dialog. You can also see a message in the message pane.

Figure 16.29 - The detail pane of the dialog showing that the report generation was success.

 

Figure 16.30 - The message pane showing that the PDF report generation was success.

Figure 16.31 – The PDF report was generated to the destination location.

 

 

Figure 16.32 – The generated PDF report.

 

Defining Image Quality

 

There are three image quality options for the PDF Report: graphics antialiasing, text antialiasing and the diagram quality. The antialiasing options are just similar to the HTML report.

 

Since the dimension of the paper limits the size of the image in the PDF report, VP-UML provides an extra image quality option in the PDF report to control how the output image will be scaled in the report.

 

To change the diagram quality option, simply select the quality option in the Diagram Quality combo box.

 

Figure 16.33 - Choosing different image quality.

 

 

Figure 16.34 - Output diagram with diagram quality set to normal (without Graphics and Text Antialiasing)

 

Figure 16.35 - Output diagram with diagram quality set to fine (without Graphics and Text Antialiasing)

 

 

Defining the page information

 

This option allows the user to define the paper size and orientation of the output report. To define the paper information:

 

1.      Open the PDF Report dialog.

2.      Select the Page tab under the File Location field.

 

Figure 16.36 – Defining the page information for the PDF report.

 

 

Field

Functionality

Page Size

To select paper size of the generated report.

Page Orientation

This option is use to select the orientation of the output report (portrait/landscape).

Page Margins

To specify the page margin of the output the document.

 

 

Defining the Page size

 

The VP-UML supports a wide range of pager sizes for PDF report. Different paper size can be selected in the Page Size combo box.

 

Figure 16.37 – Selecting paper.

 

 

Defining the Page orientation

 

To define the page orientation for the output report, select the desired orientation option in the Page Orientation section.

 

Figure 16.38 – Selecting page orientation.

 

 

Adjusting the Page Margin

 

To define the page margin type in the margin in the text box at the side that you want to adjust, or simply drag the margin in the paper image.

 

Figure 16.39 – Adjusting page margin.

 

 

Defining Header/Footer

 

To define the Header/Footer of the document:

 

4.      Open the Generate PDF Report dialog.

5.      Select the Header/Footer tab.

6.      Check Use Header / Use Footer CheckBox to make the report use header/footer.

 

Figure 16.40 – Defining the header/footer.

 

 

Field

Functionality

Header

Use Header

To indicate the output PDF document will use header or not.

Header Style

The style of the header (i.e. include page number or not).

Alignment

The alignment (Left/Center/Right) of the header.

Header Text 1

The first content of the header.

Header Text 2

The second content of the header.

Font Name

The font type of the header.

Font Style

The font style of the header.

Font Size

The font size of the header.

Font Color

The font color of the header.

Footer

Use Footer

To indicate the output HTML document will use footer or not.

Footer Style

The style of the footer (i.e. include page number or not).

Alignment

The alignment (Left/Center/Right) of the footer.

Footer Text 1

The first content of the footer.

Footer Text 2

The second content of the footer.

Font Name

The font type of the footer.

Font Style

The font style of the footer.

Font Size

The font size of the footer.

Font Color

The font color of the footer.

Preview

The preview of the header/footer.

 

 

Defining the Header/Footer Style

 

VP-UML supports four types of header/footer style for the PDF report. They are “text only”, “text followed by page number”, “page number followed by text” and “page number between text”.

To choose the header/footer style, simple select the style from the Header/Footer Style combo box. The sample preview will be show on the preview section.

 

Figure 16.41 – Selecting header/footer style.

 

 

Figure 16.42 – The output header.

 

 

 

Defining the content

 

To define the header content, fill in the text in the Header Text 1 and Header Text 2 text field.

 

Figure 16.43 – Defining the content of the header/footer.

 

 

Defining the alignment

 

Select the alignment options (Left/Center/Right) from the Alignment Combo Box. The preview of the alignment will be show in the preview area on the right hand side of the dialog.

 

Figure 16.44 – Defining the alignment of the header/footer.

 

Defining the font

 

To change the font type select the font from the Font Name Combo box.

 

Figure 16.45 – Selecting the font for the header/footer.

 

To change the font style, select the style from the Font Style Combo box.

Figure 16.46 – Selecting font style for the header/footer.

 

 

To change the font size, select the size from the Font Size Combo box.

 

Figure 16.47 – Defining the font size for the header/footer.

 

To change the font color, press the  button in the Font Color field, a color chooser dialog will be displayed. Select the color you want then press the OK button.

 

Figure 16.48 – Selecting the font color for the header/footer.

 

Figure 16.49 – The generated header.

 

 

Defining Document Info

 

To define the document info:

 

1.      Open the Generate PDF dialog.

2.      Select the Document Info tab.

 

Figure 16.50 – Defining Document Info.

 

 

Field

Functionality

Title

The title of the output PDF document.

Author

The author of the output PDF document.

Subject

The subject of the output PDF document.

Keywords

The keywords of the output PDF document.

InfoHeader

The info header of the output PDF document.

InfoHeader Content

The info header content of the output PDF document.

Allow Modify

The allow modify permission of the output PDF document.

 

 

Figure 16.51 – Generated Document Info in the PDF report.

 

Figure 16.52 – With allow modify option unchecked, the “Changing the Document” permission was changed to false.

 

 

Previewing the document

 

 

VP-UML allows you to preview the output PDF documents before saving to the file system. To preview the output report, simply click the Preview button instead of Generate.

 

Figure 16.53 - The progress showing the current status of generating the preview.

Figure 16.54 – Preview window of the PDF report.

 

 

Function Group

Icon

Button

Function

Save Document

Save

To save the document to the destination location.

Navigation

First Page

Go to the first page of the document.

Previous Page

Go to the previous page of the document.

Next Page

Go to the next page of the document.

Last Page

Go to the last page of the document.

Zoom

Zoom in

Zoom in the document.

Zoom out

Zoom out the document.

Actual Size

To view the document with actual size.

Fit in Window

To view the document which size automatically fit the size of the preview window.

Fit Width

To view the document which size automatically fit the width of the preview window.

Exit Preview

Close

To close the preview dialog

 

 

Navigating the preview report

 

You can use the navigation buttons to walkthrough the preview report. The current page number is show on the status bar at the bottom of the preview dialog.

 

 

Viewing the preview report

 

You can view the report with different zoom ratio. To zoom in the diagram, press the Zoom in button. Then the preview will be zoomed in by 5%. Press the Zoom out button to zoom out the preview by 5%. The current zoom ratio is show on the status bar at the bottom of the preview dialog.

 

To view the report with actual size, press the Actual size button.  The report preview will show in Actual size mode by default (see Figure 16.54).

 

 

To view the report with size fit to the preview window, press the Fit in Window button.

 

Figure 16.55 – Viewing the preview in Fit in Window mode,

 

To view the report with size fit to the width of the preview window, press the Fit Width button.

 

Figure 16.56 – Viewing the preview in Fit Width mode.

 

 

Saving the preview report

 

To save the preview, click the Save button, then select the destination location and press save.

 

 

If the target file already exists and is in use, VP-UML is able to generate the PDF report. Please make sure the target file is close before generating PDF report.

 

 

It may take some time when the first time you start the preview.

 

The links inside the preview report is not work.