Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
CFX_CSSNumberValue Class Referencefinal

#include <cfx_cssnumbervalue.h>

+ Inheritance diagram for CFX_CSSNumberValue:
+ Collaboration diagram for CFX_CSSNumberValue:

Public Types

enum class  Unit {
  kNumber , kPercent , kEMS , kEXS ,
  kPixels , kCentiMeters , kMilliMeters , kInches ,
  kPoints , kPicas
}
 
- Public Types inherited from CFX_CSSValue
enum class  PrimitiveType : uint8_t {
  kUnknown = 0 , kNumber , kString , kRGB ,
  kEnum , kFunction , kList
}
 

Public Member Functions

 CFX_CSSNumberValue (Unit unit, float value)
 
 ~CFX_CSSNumberValue () override
 
Unit unit () const
 
float value () const
 
float Apply (float percentBase) const
 
- Public Member Functions inherited from CFX_CSSValue
PrimitiveType GetType () const
 
- Public Member Functions inherited from fxcrt::Retainable
 Retainable ()=default
 
bool HasOneRef () const
 

Additional Inherited Members

- Protected Member Functions inherited from CFX_CSSValue
 CFX_CSSValue (PrimitiveType type)
 
 ~CFX_CSSValue () override
 
- Protected Member Functions inherited from fxcrt::Retainable
virtual ~Retainable ()=default
 

Detailed Description

Definition at line 12 of file cfx_cssnumbervalue.h.

Member Enumeration Documentation

◆ Unit

enum class CFX_CSSNumberValue::Unit
strong
Enumerator
kNumber 
kPercent 
kEMS 
kEXS 
kPixels 
kCentiMeters 
kMilliMeters 
kInches 
kPoints 
kPicas 

Definition at line 14 of file cfx_cssnumbervalue.h.

Constructor & Destructor Documentation

◆ CFX_CSSNumberValue()

CFX_CSSNumberValue::CFX_CSSNumberValue ( Unit unit,
float value )

Definition at line 11 of file cfx_cssnumbervalue.cpp.

References CFX_CSSValue::CFX_CSSValue(), kNumber, and CFX_CSSValue::kNumber.

+ Here is the call graph for this function:

◆ ~CFX_CSSNumberValue()

CFX_CSSNumberValue::~CFX_CSSNumberValue ( )
overridedefault

Member Function Documentation

◆ Apply()

float CFX_CSSNumberValue::Apply ( float percentBase) const

Definition at line 19 of file cfx_cssnumbervalue.cpp.

References kCentiMeters, kEMS, kEXS, kInches, kMilliMeters, kNumber, kPercent, kPicas, kPixels, and kPoints.

◆ unit()

Unit CFX_CSSNumberValue::unit ( ) const
inline

Definition at line 30 of file cfx_cssnumbervalue.h.

◆ value()

float CFX_CSSNumberValue::value ( ) const
inline

Definition at line 31 of file cfx_cssnumbervalue.h.


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