Krita Source Code Documentation
Loading...
Searching...
No Matches
EnhancedPathReferenceParameter Class Reference

A referencing parameter, one that references another formula or a modifier. More...

#include <EnhancedPathParameter.h>

+ Inheritance diagram for EnhancedPathReferenceParameter:

Public Member Functions

 EnhancedPathReferenceParameter (const QString &reference, EnhancedPathShape *parent)
 Constructs reference parameter from the given reference string.
 
qreal evaluate () override
 evaluates the parameter using the given path
 
void modify (qreal value) override
 modifies the parameter if possible, using the new value
 
QString toString () const override
 returns string representation of the parameter
 
- Public Member Functions inherited from EnhancedPathParameter
 EnhancedPathParameter (EnhancedPathShape *parent)
 
virtual ~EnhancedPathParameter ()
 

Private Attributes

QString m_reference
 the reference, formula or modifier
 

Additional Inherited Members

- Protected Member Functions inherited from EnhancedPathParameter
EnhancedPathShapeparent ()
 

Detailed Description

A referencing parameter, one that references another formula or a modifier.

Definition at line 79 of file EnhancedPathParameter.h.

Constructor & Destructor Documentation

◆ EnhancedPathReferenceParameter()

EnhancedPathReferenceParameter::EnhancedPathReferenceParameter ( const QString & reference,
EnhancedPathShape * parent )
explicit

Constructs reference parameter from the given reference string.

Definition at line 174 of file EnhancedPathParameter.cpp.

176 , m_reference(reference)
177{
178}
EnhancedPathParameter(EnhancedPathShape *parent)
EnhancedPathShape * parent()
QString m_reference
the reference, formula or modifier

Member Function Documentation

◆ evaluate()

qreal EnhancedPathReferenceParameter::evaluate ( )
overridevirtual

evaluates the parameter using the given path

Implements EnhancedPathParameter.

Definition at line 180 of file EnhancedPathParameter.cpp.

181{
183}
qreal evaluateReference(const QString &reference)

References EnhancedPathShape::evaluateReference(), m_reference, and EnhancedPathParameter::parent().

◆ modify()

void EnhancedPathReferenceParameter::modify ( qreal value)
overridevirtual

modifies the parameter if possible, using the new value

Reimplemented from EnhancedPathParameter.

Definition at line 185 of file EnhancedPathParameter.cpp.

186{
188}
float value(const T *src, size_t ch)
void modifyReference(const QString &reference, qreal value)

References m_reference, EnhancedPathShape::modifyReference(), EnhancedPathParameter::parent(), and value().

◆ toString()

QString EnhancedPathReferenceParameter::toString ( ) const
overridevirtual

returns string representation of the parameter

Implements EnhancedPathParameter.

Definition at line 190 of file EnhancedPathParameter.cpp.

191{
192 return m_reference;
193}

References m_reference.

Member Data Documentation

◆ m_reference

QString EnhancedPathReferenceParameter::m_reference
private

the reference, formula or modifier

Definition at line 88 of file EnhancedPathParameter.h.


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