### Creating an XSD style

To create an XSD style, that is to add a style group in a catalog, follow the steps below:

1. In JReport Designer, open the catalog to which you want to add the style group.
2. In the Styles tab of the Catalog Browser, right-click any of the existing group and select New Style Group from the shortcut menu.
3. In the New Style Group dialog, enter the name and description of the group, then click OK. A new style group will be added to the tree.
4. Right-click the group and click New Style.
5. In the New Style dialog, specify the name, type and description of the new style, then click OK.

   The style type indicates the application scope of a style, for example, a style with Label type can only be applied to label objects, and a style with DBField type can only be applied to DBFields.

6. In the Save Style dialog, add the properties to be included in the style and change the property values as required. See the dialog.

   To add a property, select it from the All Properties box and click . To add all the available properties to the style at a time, click .

   To edit the value of a property, click its value cell in the Selected Properties box, then input the new value and press Enter on the keyboard to confirm the change.

   To remove a property that has been added, select it from the Selected Properties box and click . To remove all the added properties at a time, click .

7. Click Save to add the style to the group.
8. Repeat steps 4 to 7 to add more styles to the group.

Now, an XSD style will have been created. You can then apply the style to your reports.

Notes:

- The root of the style group tree can only hold style groups. The styles must reside in the style groups. You cannot create a style directly in the style group tree root.
- You cannot create style groups in the Default style group.
- The name of each style group must be unique in the style group tree.
- Each style has a style type to indicate its application scope, for example, a style with Label type can only be applied to label objects, and a style with DBField type can only be applied to a DBFields.
- You can create more than one style for a style type, and apply different styles to report objects of the same type. For example, suppose that you have a number of DBFields in your report, such as address fields, totals, and quantity fields. You probably will not want all the fields to look the same. You can create two or more styles, using the same style type - DBField, and then apply them separately to the fields that you want to distinguish.
- You can apply a default style to all the objects that hold the same type.

  In the Default style group, create a new style, making sure that the style name and style type are the same, for example, style name=Label, style type=Label. Then, modify the style properties. Then, when a new object of the specified type is inserted into the report, the default style will be applied to it automatically. Note that you can see the difference only at runtime.