# class toTemplateItem | This is an item that is contained in a template. More...
Definition | `#include <totemplate.h>`
Inherits | toResultViewItem [public ]
Inherited by | toTemplateSQL, toTemplateText
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- toTemplateItem (toTemplateProvider &prov,QListView *parent,const QString &name)
- toTemplateItem (toTemplateItem *parent,const QString &name)
- toTemplateProvider & provider (void)
- virtual void expand (void)
- virtual void collapse (void)
- virtual QWidget * selectedWidget (QWidget *parent)
- virtual void setSelected (bool sel)

## Detailed Description

This is an item that is contained in a template. It is different in the expand and collapse methods that are called when this item is expanded or collapsed from the template widget.

toTemplateItem (toTemplateProvider &prov,QListView *parent,const QString &name) | ### toTemplateItem

Create an item.

Parameters:

prov | Provider for this item.
parent | Parent of this item.
name | Contents of the first column of the item.

toTemplateItem (toTemplateItem *parent,const QString &name) | ### toTemplateItem

Create an item.

Parameters:

parent | Parent of this item.
name | Contents of the first column of the item.

toTemplateProvider & provider (void) | ### provider

Get a reference to the provider of this item.

Returns: Reference to provider.

void expand (void) | ### expand

[virtual]

This function is called when the item is expanded and can be used to fill up the list when needed.

void collapse (void) | ### collapse

[virtual]

This function is called when the item is collapsed.

QWidget * selectedWidget (QWidget *parent) | ### selectedWidget

[virtual]

This function can be used to return a widget that is displays extra information for this item. Return NULL if no widget is to be displayed. The widget will be deleted when this item is no longer shown.

void setSelected (bool sel) | ### setSelected

[virtual]

Reimplemented for internal reasons.

Reimplemented from QListViewItem.