Advanced Features

Christopher Hornbaker

    chrishornbaker@earthlink.net

# Advanced Features

This chapter outlines the advanced features of &quantaplus; and how to use them.

## &XML; Tools

The 3.2 release of &quantaplus; brings with it many new &XML; tools and features. The tools are unique in their integration within &quantaplus;. All of these tools use Kommander as a front-end and libxml2 and libxslt as a back-end. The combination of these makes for fast, efficient, productive, and complete tools.

### &kde; Documentation Tools

&quantaplus; supports &kde;'s two main documentation tools: `meinproc` and `checkXML`.

#### `meinproc`

Anyone who has worked with &kde; documentation knows `meinproc` and how superb it is. Well, take it up a notch with a great graphical interface! No longer resort to a shell; just click the icon that resembles a processor and you are done!

Current Working Folder

  This application expects an `index.docbook` file to be present in a folder. If `index.docbook` is in the current working folder, then simply leave Current Working Folder checked. If it is not, then uncheck Current Working Folder and enter the folder you wish to process in the Other Folder field.

Outputted files are placed in the same folder as the sources files. All &HTML; files are removed each time `meinproc` is ran.

#### `checkXML`

Again, anyone who has worked with &kde; documentation knows this helpful application. Again, &quantaplus; provides a great little graphical front-end to this one.

Current Working Folder

  If the currently opened file is the `index.docbook` file, then simply leave Current Working Folder checked. If it is not, then uncheck Current Working Folder and enter the folder of where `index.docbook` can be found.

Output

If there is output, then your file is invalid. Please correct the reported errors and try again.

### &XML; Validation

&quantaplus; has a great &XML; validation tool, which uses a `xmllint` back-end.

Current File

  If the file to be validated is currently focused on in &quantaplus;, then simply leave Current File checked. If it is not, then uncheck Current File and select the file to be validated from the Other File file selector.

Well-formed Checking

  If you only wish to know only if the file is well-formed, click the Well-formed Checking Only check box.

Definition &URI;

  If you are using a &DTD; and it is specified within the &XML; file, then select &DTD; (Internal) (default), else select &DTD; (External) and locate the &DTD; with the Definition &URI; file selector. Both &W3C; &XML; Schema and RelaxNG validation are required to be externally defined via the Definition &URI; file selector.

### &XSL; Processing

Yep, &quantaplus; has a &XSL; processing tool, too! This uses the `xsltproc` tool provided with libxml2.

Current File

  If the file to be processed is currently focused on in &quantaplus;, then simply leave Current File checked. If it is not, then uncheck Current File and select the file to be processed from the Other File selector.

Stylesheet

  Select the &XSL; file that you wish to be used.

Output file name

  Enter the name of the file that you want the resulting file to be called. File is outputed to your home folder by default.

This application lacks flexibility. Sorry, we will do better next time.

Using Plugins

Mathieu Kooiman

    quanta@map-is.nl

## Using Plugins

### What is a Plugin?

&quantaplus; is able to load plugins, which are KParts. The KPart framework is another very powerfull framework of &kde;. A KPart is a relatively small, reusable container of functionality. It allows &kde; developers to easily build on the work of other programmers. One example of this is &quantaplus; itself. The editor &quantaplus; uses is the &kate; KPart. The &kate; KPart already had a bunch of functionality that &quantaplus; needed, like syntax highlighting. Integrating it into &quantaplus; allowed the &quantaplus; developers to focus on what &quantaplus; should be able to do, rather than facing the many problems that developing a new editor KPart/component from scratch would bring.

The plugins &quantaplus; loads might have nothing to do with &quantaplus; itself. This makes it a very powerful plugin system. You can benefit from extra functionality and need not to wait until someone integrates it into &quantaplus;! The plugins can be loaded into a number of &GUI; elements. More on this below.

### Understanding the Edit Plugin Dialog

To install a Plugin or KPart we will work from the Plugins Edit menu. This will bring up the following dialog:

The Edit Plugin dialog.

This dialog lets you manage all defined plugins and lets you add new ones. We will describe each &GUI; element in here:

Search paths

  Here you can fill in a search path. When adding a plugin without a Location, &quantaplus; will search these paths to find the plugin.

Add

  This will bring up a dialog which allows you to add a new plugin.

Configure

  This will allow you to change the settings of a particular plugin.

Remove

  Removes the currently selected plugin.

Refresh

  Refreshes the dialog's contents.

Read to learn more about plugins.

## Team Development

Often a project has more than one people working on it and there is some kind of hierarchical relationsship between them. &quantaplus; supports the notion of team members and they are configurable in the &Shift;F7 Project Project Properties dialog.

The team member editor dialog

The Name, Email entries are self explaining. Nickname is the nick of the user and acts as an unique identifier.

Role specifies the role of the member in the project and can be one of the following:

- Team leader

- Subproject Leader

- Task Leader

- Simple Member

Task is a description of the task assigned to this member.

Subproject: you can select a list of subproject. Subprojects can be configured and created by pressing the Edit subprojects button. Each subproject has a user visible name and a location entry, the later specifying a relative path to a directory under the project tree. This means that a subproject is a directory under the main project. For example the main project can be the website of your company, while a subproject can be the website for the intranet, located under the `intranet` folder in the project.

One member can have more than one role in the project, like both team leader and subproject leader.

The user should select who is himself from the list of the team members. This is possible by selecting a team member from the list and pressing the Set to Yourself button. The currently selected member (your identity) appears in bold after the You are: text.

Nicknames and setting yourself is important regarding messaging and annotations. See to learn more about annotations.

Aside of keeping track of your team, there is one more benefit of setting up the team members: you can configure an event to inform the team leaders when some action happens. See about how to do it.

## Event Actions

Event actions are actions executed when some event happens in the project. An example would be logging when the project was opened and closed, so it can be later reviewed how much one worked on it, or sending a mail when a file is saved, or adding the file to the CVS with the help of a script when the file is added to the project and the list could continue.

On the Event Configuration page of the &Shift;F7 Project Project Properties dialog you can create, edit and delete the event actions.

The event editor dialog

The entries in the dialog are:

Event

  the action is executed when the event selected from the list happens. The event names are self explanatory.

Action

  the type of the executed action. The possible choices are

  Non-script action

    an action that is not a user defined script action. See for user action.

    Action name specifies the action to be executed when the event happens.

  Send email

    an email is sent when the action happens to the recipient selected in the Receiver list. The recipient can be a team or subproject leader. See for defining such leaders.

  Log event

    the event is logged in a file. The arguments for this action are:

    Log file

      the filename with full path

    Detail

      How much information will the log contain

    Behavior

      Whether to create/overwrite the existing log file or append the new logged event to it.

  Script action

    an user defined script action. See for user action.

    Action name specifies the action to be executed when the event happens.

The other entries depend on the Action type as they were described.

## Annotations

Annotations are special comments in the documents. They differ from regular comments by the following things:

- the information is collected by Quanta and shown in the Annotations toolview.

- the information can be addressed to a team member

Entering annotations is simple. You can either use the Annotate entry from the editor context menu or enter the @annotation keyword in a comment area followed by the annotation text.

Annotation example in XML

    <!-- @annotation It is possible  that this code is wrong. -->

    <!-- @annotation
     Multiline
     annotation.
    -->

Annotation example in PHP

    /* @annotation
    Use PHP comments when annotating a PHP area
    */

Annotations can be addressed for a specific member of your team. The syntax in this case is @annotation(nickname) or @annotation(role), where nickname is the nickname of a team member, while role is a project role from the following items:

- team leader

- task leader

- subproject leader

The task and subproject leaders should be followed by the corresponding task and subproject name, like it is shown in the below examples.

Make a note to a team member with the nickname eric

    <-- @annotation(eric) Eric, please look at this. Andras -->

Inform the team leader

    <-- @annotation(team leader) This is very important for the team -->

Inform the PHP subproject leader

    // @annotation(subproject leader:PHP) What do you think about it?

Nicknames and role names are case insensitive, but spaces around brackets and the : make the annotation invalid.

More about team members, roles and nicknames can be found in .

The annotations found in the project can be inspected in the Annotations view. It consists of tree tabs:

Current File

  The annotation found in the current file.

For You

  Annotations in the project addressed for you. The entries are groupped per file.

All Files

  The annotations found in all the project files, groupe dy files

The annotations are scanned on project and file load for external modifications. This way even is somebody adds an annotation outside of &quantaplus;, it will be recognized. As scanning can take some time, the information dialog about new annotations addressed for you might appear after some seconds of the project loading.
&debugging-quanta;