GetModifiers
Get modifiers.
int GetModifiers( vector<int> & vnDesigs, vector<string> & saNames )
0 if successfully get the modifiers
EX1
// assum a worksheet has 3 columns // make a scatter plot with first 2 columns // and use the 3rd column as plot label void DataPlot_GetModifiers_ex() { Worksheet wks = Project.ActiveLayer(); if(!wks) return; Column col(wks, 2); if(!col) return; DataRange dr; dr.Add(wks, 0, "X"); dr.Add(wks, 1, "Y"); GraphPage gp; gp.Create("Origin"); GraphLayer gl = gp.Layers(); gl.AddPlot(dr, IDM_PLOT_SCATTER); gl.Rescale(); DataPlot dp = gl.DataPlots(0); if(!dp) return; dp.SetModifier(COLDESIG_PLOTLABEL_FORM, col); vector<int> vnDesigs; vector<string> saNames; dp.GetModifiers(vnDesigs, saNames); vector<uint> vecIndex; if(vnDesigs.Find(vecIndex, COLDESIG_PLOTLABEL_FORM) > 0) { printf("label form = %s\n", saNames[ vecIndex[0] ]); } }
origin.h