# KDChart::PositionPoints Class Reference

`#include <KDChartPosition.h>`

Collaboration diagram for KDChart::PositionPoints:

[legend]
List of all members.

## Public Member Functions

bool | isNull () const
const QPointF | point (Position position) const
| PositionPoints (QPointF northWest, QPointF northEast, QPointF southEast, QPointF southWest)
| PositionPoints (const QRectF &rect)
| PositionPoints (const QPointF &onePointForAllPositions)
| PositionPoints (QPointF center, QPointF northWest, QPointF north, QPointF northEast, QPointF east, QPointF southEast, QPointF south, QPointF southWest, QPointF west)
| PositionPoints ()

## Public Attributes

QPointF | mPositionCenter
QPointF | mPositionEast
QPointF | mPositionNorth
QPointF | mPositionNorthEast
QPointF | mPositionNorthWest
QPointF | mPositionSouth
QPointF | mPositionSouthEast
QPointF | mPositionSouthWest
QPointF | mPositionUnknown
QPointF | mPositionWest

## Constructor & Destructor Documentation

KDChart::PositionPoints::PositionPoints | ( |  | ) |

Definition at line 138 of file KDChartPosition.h.

    00138 {} // all points get initialized with the default automatically

KDChart::PositionPoints::PositionPoints | ( | QPointF | center,
|  | QPointF | northWest,
|  | QPointF | north,
|  | QPointF | northEast,
|  | QPointF | east,
|  | QPointF | southEast,
|  | QPointF | south,
|  | QPointF | southWest,
|  | QPointF | west
| ) |

Definition at line 140 of file KDChartPosition.h.

    00150       : mPositionCenter(    center )
    00151       , mPositionNorthWest( northWest )
    00152       , mPositionNorth(     north )
    00153       , mPositionNorthEast( northEast )
    00154       , mPositionEast(      east )
    00155       , mPositionSouthEast( southEast )
    00156       , mPositionSouth(     south )
    00157       , mPositionSouthWest( southWest )
    00158       , mPositionWest(      west )
    00159         {}

KDChart::PositionPoints::PositionPoints | ( | const QPointF & | onePointForAllPositions | ) |

Definition at line 160 of file KDChartPosition.h.

    00162       : mPositionCenter(    onePointForAllPositions )
    00163       , mPositionNorthWest( onePointForAllPositions )
    00164       , mPositionNorth(     onePointForAllPositions )
    00165       , mPositionNorthEast( onePointForAllPositions )
    00166       , mPositionEast(      onePointForAllPositions )
    00167       , mPositionSouthEast( onePointForAllPositions )
    00168       , mPositionSouth(     onePointForAllPositions )
    00169       , mPositionSouthWest( onePointForAllPositions )
    00170       , mPositionWest(      onePointForAllPositions )
    00171         {}

KDChart::PositionPoints::PositionPoints | ( | const QRectF & | rect | ) |

Definition at line 172 of file KDChartPosition.h.

    00174     {
    00175         const QRectF r( rect.normalized() );
    00176         mPositionCenter    = r.center();
    00177         mPositionNorthWest = r.topLeft();
    00178         mPositionNorth     = QPointF(r.center().x(), r.top());
    00179         mPositionNorthEast = r.topRight();
    00180         mPositionEast      = QPointF(r.right(), r.center().y());
    00181         mPositionSouthEast = r.bottomRight();
    00182         mPositionSouth     = QPointF(r.center().x(), r.bottom());
    00183         mPositionSouthWest = r.bottomLeft();
    00184         mPositionWest      = QPointF(r.left(), r.center().y());
    00185     }

KDChart::PositionPoints::PositionPoints | ( | QPointF | northWest,
|  | QPointF | northEast,
|  | QPointF | southEast,
|  | QPointF | southWest
| ) |

Definition at line 186 of file KDChartPosition.h.

    00191       : mPositionCenter(    (northWest + southEast) / 2.0 )
    00192       , mPositionNorthWest( northWest )
    00193       , mPositionNorth(     (northWest + northEast) / 2.0 )
    00194       , mPositionNorthEast( northEast )
    00195       , mPositionEast(      (northEast + southEast) / 2.0 )
    00196       , mPositionSouthEast( southEast )
    00197       , mPositionSouth(     (southWest + southEast) / 2.0 )
    00198       , mPositionSouthWest( southWest )
    00199       , mPositionWest(      (northWest + southWest) / 2.0 )
    00200         {}

## Member Function Documentation

bool KDChart::PositionPoints::isNull | ( |  | ) | const

Definition at line 226 of file KDChartPosition.h.

    00227     {
    00228         return
    00229             mPositionUnknown.isNull() &&
    00230             mPositionCenter.isNull() &&
    00231             mPositionNorthWest.isNull() &&
    00232             mPositionNorth.isNull() &&
    00233             mPositionNorthEast.isNull() &&
    00234             mPositionEast.isNull() &&
    00235             mPositionSouthEast.isNull() &&
    00236             mPositionSouth.isNull() &&
    00237             mPositionSouthWest.isNull() &&
    00238             mPositionWest.isNull();
    00239     }

const QPointF KDChart::PositionPoints::point | ( | Position | position | ) | const

Definition at line 202 of file KDChartPosition.h.

    00203     {
    00204       //qDebug() << "point( " << position.name() << " )";
    00205       if( position ==  Position::Center)
    00206         return mPositionCenter;
    00207       if( position ==  Position::NorthWest)
    00208         return mPositionNorthWest;
    00209       if( position ==  Position::North)
    00210         return mPositionNorth;
    00211       if( position ==  Position::NorthEast)
    00212         return mPositionNorthEast;
    00213       if( position ==  Position::East)
    00214         return mPositionEast;
    00215       if( position ==  Position::SouthEast)
    00216         return mPositionSouthEast;
    00217       if( position ==  Position::South)
    00218         return mPositionSouth;
    00219       if( position ==  Position::SouthWest)
    00220         return mPositionSouthWest;
    00221       if( position ==  Position::West)
    00222         return mPositionWest;
    00223       return mPositionUnknown;
    00224     }

## Member Data Documentation

QPointF KDChart::PositionPoints::mPositionCenter

| Definition at line 242 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionEast

| Definition at line 246 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionNorth

| Definition at line 244 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionNorthEast

| Definition at line 245 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionNorthWest

| Definition at line 243 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionSouth

| Definition at line 248 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionSouthEast

| Definition at line 247 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionSouthWest

| Definition at line 249 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionUnknown

| Definition at line 241 of file KDChartPosition.h.

QPointF KDChart::PositionPoints::mPositionWest

| Definition at line 250 of file KDChartPosition.h.

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

- KDChartPosition.h