BPS C++ API  2.24.4
BpsPropertyManager Class Reference

The class extends QtVariantPropertyManager by support for objects of the following types:
. More...

#include <bpspropertymanager.h>

+ Inheritance diagram for BpsPropertyManager:

Public Slots

virtual void setAttribute (QtProperty *aProperty, const QString &aName, const QVariant &aValue)
 Sets the value of the specified attribute for the property. More...
 
virtual void setValue (QtProperty *aProperty, const QVariant &aValue)
 Sets the value of the given property to value. More...
 

Public Member Functions

 BpsPropertyManager (QObject *aParent)
 Creates a manager with the given parent. More...
 
virtual bool isPropertyTypeSupported (int aPropertyType) const
 Check if a given property type is supported by the manager. More...
 
virtual QVariant value (const QtProperty *aProperty) const
 Get the properties value. More...
 
virtual int valueType (int aPropertyType) const
 Get the value type belonging to a given property type. More...
 

Static Public Member Functions

static int marginsTypeId ()
 

Protected Member Functions

virtual void initializeProperty (QtProperty *aProperty)
 This function is called whenever a new valid property pointer has been created, passing the pointer as parameter. More...
 
virtual void uninitializeProperty (QtProperty *aProperty)
 This function is called just before the specified property is destroyed. More...
 
virtual QIcon valueIcon (const QtProperty *aProperty) const
 Get a icon representing the current state of the given property. More...
 
virtual QString valueText (const QtProperty *aProperty) const
 Get a string representing the current state of the given property. More...
 

Detailed Description

The class extends QtVariantPropertyManager by support for objects of the following types:
.

Class Type/Usertype Description
BpsMargins marginsTypeId() Margins as used within reports. The attributes minimum, maximum and decimals apply to the margin values.
QPen QVariant::Pen The pen attributes style (excluding Qt::CustomDashLine), widthF and color are supported. The attributes minimum, maximum and decimals apply to the widthF value.
QBrush QVariant::Brush The brush attributes style (patterns only), scale percent (as transform m11/m22) and color are supported. The attributes minimum, maximum and decimals apply to the scale value.

Constructor & Destructor Documentation

◆ BpsPropertyManager()

BpsPropertyManager::BpsPropertyManager ( QObject aParent)

Creates a manager with the given parent.

Parameters
aParentThe parent to use.

Member Function Documentation

◆ initializeProperty()

virtual void BpsPropertyManager::initializeProperty ( QtProperty *  aProperty)
protectedvirtual

This function is called whenever a new valid property pointer has been created, passing the pointer as parameter.

The purpose is to let the manager know that the property has been created so that it can provide additional attributes for the new property.

Parameters
aPropertyThe property being initialized.

◆ isPropertyTypeSupported()

virtual bool BpsPropertyManager::isPropertyTypeSupported ( int  aPropertyType) const
virtual

Check if a given property type is supported by the manager.

Parameters
aPropertyTypeThe property type to check.
Returns
True if supported.

◆ marginsTypeId()

static int BpsPropertyManager::marginsTypeId ( )
static
Returns
The property id for BpsMargins

◆ setAttribute

virtual void BpsPropertyManager::setAttribute ( QtProperty *  aProperty,
const QString aName,
const QVariant aValue 
)
virtualslot

Sets the value of the specified attribute for the property.

Parameters
aPropertyThe property to assign the attribute to.
aNameName of the attribute.
aValueThe value to assign.

◆ setValue

virtual void BpsPropertyManager::setValue ( QtProperty *  aProperty,
const QVariant aValue 
)
virtualslot

Sets the value of the given property to value.

The specified value must be of a type returned by valueType(), or of type that can be converted to valueType() using the QVariant::canConvert() function, otherwise this function does nothing.

Parameters
aPropertyThe property to set.
aValueThe value to set.

◆ uninitializeProperty()

virtual void BpsPropertyManager::uninitializeProperty ( QtProperty *  aProperty)
protectedvirtual

This function is called just before the specified property is destroyed.

The purpose is to let the property manager know that the property is being destroyed so that it can remove the property's additional attributes.

Parameters
aPropertyThe property being uninitialized.

◆ value()

virtual QVariant BpsPropertyManager::value ( const QtProperty *  aProperty) const
virtual

Get the properties value.

Parameters
aPropertyThe property to get the value from.
Returns
The value of the property.

◆ valueIcon()

virtual QIcon BpsPropertyManager::valueIcon ( const QtProperty *  aProperty) const
protectedvirtual

Get a icon representing the current state of the given property.

Parameters
aPropertyThe property to query.
Returns
The icon representation.

◆ valueText()

virtual QString BpsPropertyManager::valueText ( const QtProperty *  aProperty) const
protectedvirtual

Get a string representing the current state of the given property.

Parameters
aPropertyThe property to query.
Returns
The string representation.

◆ valueType()

virtual int BpsPropertyManager::valueType ( int  aPropertyType) const
virtual

Get the value type belonging to a given property type.

Parameters
aPropertyTypeThe property type.
Returns
The value type.

The documentation for this class was generated from the following file: