Mobile API Reference
MicroStrategy 2019
|
#include <Plot.h>
Public Types | |
typedef MSynch::SmartPtr< Plot > | Ptr |
Public Types inherited from MsiChart::GraphObjectManager | |
typedef MSynch::SmartPtr< GraphObjectManager > | Ptr |
Public Member Functions | |
Plot (const TripleId &irTripleId, GraphObjectManager *ipManager, const Rect2D &irDataArea) | |
virtual | ~Plot () |
virtual void | Draw () |
virtual void | GenerateView () |
virtual void | GenerateImageMap (ImageMap &iorImageMap) |
virtual GraphObject::Ptr | OnPointDetection (const Point2D &irCursor) const |
virtual void | OnRectangleSelection (const Rect2D &irRect, std::vector< GraphObject::Ptr > &iorSelectedObjects) const |
virtual bool | GetToolTipData (Int32 iSeriesID, Int32 iGroupID, double &orValue, double &orPercentValue, Int32 iOffset=0) |
virtual bool | GetGroupSpace (std::vector< Int32 > &orVect, Int32 iGroupIndex) |
virtual Int32 | GetMaxElementRadius () |
virtual void | RefreshValueAxis (const std::map< Int32, std::pair< double, double > > &irScaleSet, const Rect2D &irRect) |
virtual bool | GetMaxElementOffsetClippedByBoundary (bool iIsOnXAxis, double &orLowOffset, double &orHighOffset) |
virtual bool | GetGMPiePositon (Point2D &orCood, double iXInput, double iYInput, Int32 iXSubIndex=0, Int32 iYSubIndex=0, Int32 iXSectionCount=1, Int32 iYSectionCount=1, Int32 iRadius=2) |
virtual void | DrawTrendLinesAndEquations () |
Draw trendlines and equations. More... | |
void | GetDataArea (Rect2D &orDataArea) const |
void | SetDataArea (const Rect2D &irDataArea) |
Dataset::Ptr | GetDataset () const |
Legend::Ptr | GetLegend () const |
void | SetDataset (Dataset::Ptr iDataSetPtr) |
void | SetLegend (Legend::Ptr iLegendPtr) |
void | AddSeries (Int32 iSeriesId) |
Int32 | GetSeriesIndexByID (Int32 iSeriesId) const |
void | MoveLabel (TextObject *ipTextObject, const Point2D &irTopRight, const Point2D &irBottomLeft, bool iIsReverse, bool iIsVertical, EnumDSSGraphDataTextPosition iLabelLocation) const |
void | AddLegendMarkerToCollection (Int32 iSeriesId, GraphCollectionObject *ipRiserCollection, bool iIsLineCollection=false, bool iIsShownMarker=true, unsigned char iMarkerShape=DssGraphMarkerShapeRectangle, bool iIsShownLine=true, bool iIsLineVertical=false) const |
void | CreateTrendLine (const std::vector< double > &irX, const std::vector< double > &irY, const TripleId &irTripleId, GraphObjectManager *ipManager, GraphCollectionObject *ipParentObject, Axis *ipXAxis, Axis *ipYAxis, GraphTrendLineOptions *ipTrendLineOptions, const Rect2D &irDataArea, bool iIsVertical, const Point2D &irDepthOffset, bool iIsY2=false) |
void | AdjustTrendLineEquation (Rect2D &irRect, EnumTrendLineIndex iIndex) |
void | DrawTrendLinesAndEquations (Rect2D &irClipRect, bool iIsY2=false) |
void | DrawPostTrendLineObjects () |
void | GeneratePostTrendLineViews () |
bool | HasTrendLines () const |
void | AddTrendLineAnadRefLine (GraphObject::Ptr iLine) |
DataLabelManager::Ptr | GetDataLabelManager () |
bool | GetVAMetricIndexDrawn (Int32 iValueMetricIndex) |
void | SetVAMetricIndexDrawn (Int32 iValueMetricIndex) |
Public Member Functions inherited from MsiChart::GraphObjectManager | |
GraphObjectManager (const TripleId &irTripleId, GraphObjectManager *ipManager) | |
virtual | ~GraphObjectManager () |
void | GetTripleId (TripleId &orTripleId) const |
virtual GraphObject::Ptr | OnPointDetectionEx (const Point2D &irCursor, const std::vector< Int32 > &irObjectIds, Int32 &iorDistance, Int32 iRadius, std::vector< GraphObject::Ptr > &iorGraphObjectsAround, EnumGraphObjectUsage iUsage=GOU_NORMAL_HIGHLIGHT) |
virtual void | OnPointInPolygon (const Point2D &irCursor, const std::vector< Int32 > &irObjectIds, const std::vector< Point2D > &iPoints, std::vector< GraphObject::Ptr > &iorGraphObjectsIn) const |
virtual void | GenerateMapAndList ()=0 |
virtual void | GetOptions (Int32 iSeriesId, Int32 iPropertyId, CComVariant *opValue) const =0 |
virtual GraphObject::Ptr | GetGraphObject (const TripleId &irTripleId, bool iRecursive=true) const |
GraphObjectManager::Ptr | GetGraphObjectManager (const TripleId &irTripleId, bool iRecursive=true) const |
void | GetAllGraphObjectInfo (std::vector< CGRect > &iAllGraphObjectsBorder, std::vector< MsiChart::TripleId > &iAllGraphObjectsTripleId) |
virtual void | GenerateVirtualMarker () |
ChartContext::Ptr | GetChartContext () const |
Int32 | GetChartAreaId () const |
void | AddToMapAndList (GraphObject::Ptr iGraphObjectPtr) |
void | AddToMapAndList (std::vector< GraphObject::Ptr > iGraphObjectPtrList) |
void | AddToList (GraphObject::Ptr iGraphObjectPtr) |
void | AddToManagerList (GraphObjectManager::Ptr iGraphObjectPtr) |
void | AddToMap (GraphObject::Ptr iGraphObjectPtr) |
void | InsertGraphObjectListAfterObject (const std::vector< GraphObject::Ptr > &irGraphObjectList, const GraphObject *ipGraphObject) |
virtual void | GenerateInterpolationFrame (double iProgress, LayerObject *ipLayerObject) |
void | MergeObjectList (GraphObjectManager *ipGraphObjectManager, bool iIsAppend) |
void | GetGraphObjectList (std::vector< GraphObject::Ptr > &orGraphObjectList) |
Get GraphObject list. More... | |
void | GetGraphObjectManagerList (std::vector< GraphObjectManager::Ptr > &orGraphObjectManagerList) |
Get GraphObjectManager list. More... | |
void | ClearGraphObjectList () |
Clear GraphObject list. More... | |
float | GetMemoryUsageEstimation () const |
Get memory usage estimation for current GraphObjectManager. More... | |
void | ExtractGraphObjectsByObjectId (std::vector< GraphObject::Ptr > &orGraphObjectList, Int32 iObjectId) |
Extract some graph objects out by object ID. The extracted graph object will be removed from mGraphObjectList. More... | |
Protected Member Functions | |
void | LoadTrendLineProperties (Int32 iSeriesId, GraphTrendLineOptions &iorTrendLineOption) const |
void | LoadValueAxisInfo (Int32 iSeriesIndex, bool iIsDualAxes, EnumValueAxis &orValueAxis) const |
Protected Member Functions inherited from MsiChart::GraphObjectManager | |
bool | ToBool (CComVariant *ipValue) const |
void | BoolToVariant (bool iValue, CComVariant *opValue) const |
void | AdjustObjectsForLayer () |
Protected Attributes | |
Dataset::Ptr | mDatasetPtr |
Legend::Ptr | mLegendPtr |
std::vector< Int32 > | mGroupID |
std::vector< Int32 > | mSeriesId |
Rect2D | mDataArea |
std::vector< TrendLineObject::Ptr > | mTrendLines [2] |
std::vector< GraphObject::Ptr > | mPostTrendLineObjects |
DataLabelManager::Ptr | mLabelManager |
bool | mVAIndexDrawn [5] |
std::set< Int32 > | mVAIndexDrawnSet |
Protected Attributes inherited from MsiChart::GraphObjectManager | |
std::map< TripleId, GraphObject::Ptr > | mGraphObjectMap |
std::vector< GraphObject::Ptr > | mGraphObjectList |
std::vector< GraphObjectManager::Ptr > | mGraphObjectManagerList |
This list keeps all the children of current GraphObjectManager. More... | |
const TripleId | mTripleId |
Identifiy current GraphObjectManager. More... | |
ChartContext::Ptr | mChartContextPtr |
The drawing context instance. Only one object in a chart. More... | |
GraphObjectManager * | mpManager |
The manager object which created the current object. More... | |
double | mProgress |
LayerObject * | mpCurrentLayerObject |
Additional Inherited Members | |
Static Public Member Functions inherited from MsiChart::GraphObjectManager | |
static GraphObject::Ptr | OnPointDetectionByList (const std::vector< GraphObject::Ptr > &irGraphObjectList, const Point2D &irCursor, const std::vector< Int32 > &irObjectIds, Int32 &iorDistance, Int32 iRadius, std::vector< GraphObject::Ptr > &iorGraphObjectsAround, EnumGraphObjectUsage iUsage=GOU_NORMAL_HIGHLIGHT) |
Protected Types inherited from MsiChart::GraphObjectManager | |
typedef std::pair< TripleId, GraphObject::Ptr > | MapPair |
typedef MSynch::SmartPtr<Plot> MsiChart::Plot::Ptr |
MsiChart::Plot::Plot | ( | const TripleId & | irTripleId, |
GraphObjectManager * | ipManager, | ||
const Rect2D & | irDataArea | ||
) |
|
virtual |
void MsiChart::Plot::AddLegendMarkerToCollection | ( | Int32 | iSeriesId, |
GraphCollectionObject * | ipRiserCollection, | ||
bool | iIsLineCollection = false , |
||
bool | iIsShownMarker = true , |
||
unsigned char | iMarkerShape = DssGraphMarkerShapeRectangle , |
||
bool | iIsShownLine = true , |
||
bool | iIsLineVertical = false |
||
) | const |
As the name, add legend marker to the collection they belong to.
iSeriesId | The input series ID. |
ipRiserCollection | The input collection. |
iIsLineCollection | Indicate whether it is line collection, true for line chart. |
iMarkerShape | Indicate the marker shape. |
iIsShownLine | Indicate whether the lines are shown or not. |
|
inline |
Add a series to the category plot
iSeriesId | The input series ID. |
void MsiChart::Plot::AddTrendLineAnadRefLine | ( | GraphObject::Ptr | iLine | ) |
void MsiChart::Plot::AdjustTrendLineEquation | ( | Rect2D & | irRect, |
EnumTrendLineIndex | iIndex | ||
) |
Adjust trend line equation position.
irRect | The rectangle trend lines should be in. |
iIndex | Indicate which trend line collection we would like to adjust, Y1, Y2 or Both. |
void MsiChart::Plot::CreateTrendLine | ( | const std::vector< double > & | irX, |
const std::vector< double > & | irY, | ||
const TripleId & | irTripleId, | ||
GraphObjectManager * | ipManager, | ||
GraphCollectionObject * | ipParentObject, | ||
Axis * | ipXAxis, | ||
Axis * | ipYAxis, | ||
GraphTrendLineOptions * | ipTrendLineOptions, | ||
const Rect2D & | irDataArea, | ||
bool | iIsVertical, | ||
const Point2D & | irDepthOffset, | ||
bool | iIsY2 = false |
||
) |
Create a trend line, add it to collection and update the format line information if necessary.
irX | The input sample point X coordinate. |
irY | The input sample point Y coordinate. |
irTripleId | The input triple ID for trend line. |
ipManager | Indicate the manager to create the trend line. |
ipParentObject | Indicate the parent of the trend line. |
ipXAxis | Indicate the axis where we get the irX. |
ipYAxis | Indicate the axis where we get the irY. |
ipTrendLineOptions | The input trend line option. |
irDataArea | The input data area. |
iIsVertical | Indicate whether the chart is vertical or horizontal. |
irDepthOffset | The input depth information. |
iIsY2 | Indicate whether the trend line belongs to Y1 or Y2. |
|
virtual |
This function is the drawing function for all graph object. Draw all the GraphObject in the GraphObject list which maintained by current GraphObjectManager.
Reimplemented from MsiChart::GraphObjectManager.
Reimplemented in MsiChart::ABLPlot, MsiChart::PiePlot, MsiChart::FunnelPlot, MsiChart::ValuePlot, MsiChart::GaugePlot, MsiChart::HistogramPlot, MsiChart::GridPlot, MsiChart::PolarPlot, MsiChart::GanttPlot, MsiChart::ValuePiePlot, CategoryPiePlot, and MsiChart::GridPiePlot.
void MsiChart::Plot::DrawPostTrendLineObjects | ( | ) |
Draw objects in mPostTrendLineObjects.
|
virtual |
Draw trendlines and equations.
Reimplemented in MsiChart::ABLPlot.
void MsiChart::Plot::DrawTrendLinesAndEquations | ( | Rect2D & | irClipRect, |
bool | iIsY2 = false |
||
) |
Draw trend lines and their equations.
irClipRect | The rectangle which is used to clip the trend line. |
iIsY2 | Indicate whether draw trend line for Y1 or Y2. |
|
virtual |
This function is to generate the image map for the web.
ioImageMap | Input and output parameter which contains the image map. |
Reimplemented from MsiChart::GraphObjectManager.
Reimplemented in MsiChart::ABLPlot, MsiChart::ValuePlot, MsiChart::GaugePlot, MsiChart::HistogramPlot, MsiChart::GridPlot, MsiChart::ValuePiePlot, CategoryPiePlot, and MsiChart::GridPiePlot.
void MsiChart::Plot::GeneratePostTrendLineViews | ( | ) |
Generate UIViews for objects in mPostTrendLineObjects.
|
virtual |
Generate UIViews for drawing. The UIViews generation is seperated from Draw() and put here to optimize the workflow and support Memory Governor's work. This function has the same workflow as Draw(), which means either function is changed, the other one has to update its workflow too. All the inheriting classes has to ensure this restriction too.
Reimplemented from MsiChart::GraphObjectManager.
Reimplemented in MsiChart::ABLPlot, MsiChart::PiePlot, MsiChart::FunnelPlot, MsiChart::ValuePlot, MsiChart::GaugePlot, MsiChart::HistogramPlot, MsiChart::PolarPlot, and MsiChart::GanttPlot.
void MsiChart::Plot::GetDataArea | ( | Rect2D & | orDataArea | ) | const |
Get the data area for the plot.
orDataArea | The output data area. |
|
inline |
|
inline |
Get dataset pointer.
|
virtual |
Reimplemented in CategoryPiePlot, MsiChart::ValuePiePlot, and MsiChart::GridPiePlot.
|
virtual |
Reimplemented in MsiChart::PiePlot.
|
inline |
Get legend pointer.
|
virtual |
Reimplemented in MsiChart::ValuePlot.
|
virtual |
Reimplemented in MsiChart::ValuePlot, MsiChart::ValuePiePlot, MsiChart::GridPlot, and MsiChart::GridPiePlot.
Get the series index by series ID. We do a binary search in mSeriesId since it is ordered vector.
iSeriesId | The input series ID. |
|
virtual |
Reimplemented in MsiChart::ABLPlot, MsiChart::PiePlot, MsiChart::FunnelPlot, and MsiChart::HistogramPlot.
|
inline |
|
inline |
|
protected |
Load the trend line properties for series specified by iSeriesId.
iSeriesId | The input series ID. |
iorTrendLineOption | The input and output trend line option. |
|
protected |
Load the value axis information for each series.
iSeriesIndex | The input series index. |
iIsDualAxes | Indicate whether it is dual axis or not. |
orValueAxis | The output reference to value axis variable. |
void MsiChart::Plot::MoveLabel | ( | TextObject * | ipTextObject, |
const Point2D & | irTopRight, | ||
const Point2D & | irBottomLeft, | ||
bool | iIsReverse, | ||
bool | iIsVertical, | ||
EnumDSSGraphDataTextPosition | iLabelLocation | ||
) | const |
Move the labels.
ipTextObject | The input text object that is to be moved. |
irTopRight | The top or right point according to the new center point. |
irBottomLeft | The bottom or left point according to the new center point. |
iIsReverse | Indicate whether reverse, two things will affect this: Axis reverse and data negative or positive. |
iIsVertical | Indicate whether the chart is vertical or horizontal. |
iLabelLocation | Indicate the label position. |
iSmart,whether | use smart label or not. |
|
virtual |
Provided the cursor coordinate, this function returns the GraphObject which contains that coordinate. If there are more then one GraphObject contains this coordinate, the one on top layer will be returned.
irCursor | The coordinate of cursor. |
Reimplemented from MsiChart::GraphObjectManager.
Reimplemented in MsiChart::ABLPlot, MsiChart::PiePlot, MsiChart::FunnelPlot, MsiChart::ValuePlot, MsiChart::GaugePlot, MsiChart::HistogramPlot, MsiChart::GridPlot, MsiChart::GanttPlot, MsiChart::ValuePiePlot, CategoryPiePlot, and MsiChart::GridPiePlot.
|
virtual |
This function provides the rectangle hit test detection service. Provided a bounding rectangle, this function can tell all the object inside that area by the parameter ioSelectedObjects.
irRect | Specifies the bounding rectangle. |
iorSelectedObjects | To store the pointers of the selected objects. This function will append the smart pointer of each selected GraphObject in current GraphObjectCreater to ioSelectedObjects. |
Reimplemented from MsiChart::GraphObjectManager.
Reimplemented in MsiChart::PiePlot, MsiChart::ValuePlot, MsiChart::HistogramPlot, MsiChart::GridPlot, MsiChart::ValuePiePlot, and MsiChart::GridPiePlot.
|
virtual |
Reimplemented in MsiChart::ValuePlot.
void MsiChart::Plot::SetDataArea | ( | const Rect2D & | irDataArea | ) |
Set the data area for the plot.
irDataArea | The input data area. |
|
inline |
Set dataset to plot.
iLegendPtr | The input dataset pointer. |
|
inline |
Set legend to plot.
iLegendPtr | The input legend pointer. |
|
inline |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |