several new plot symbols
@ -42,11 +42,12 @@ Changes, compared to \ref WHATSNEW_V2018_08 "v2018.08" include:
|
||||
<li> new: user-interaction tool that shows coordinates of data points near the current mouse position (when mouse is dragged, while mouse button is pressed) \see jkqtpmdaToolTipForClosestDataPoint </li>
|
||||
<li> new: user-interaction tool that measures distances and angles when mouse is dragged, while mouse button is pressed) \see jkqtpmdaRuler </li>
|
||||
<li> new: advanced styling options for boxplots + example for the styling: \ref JKQTPlotterBoxplotStyling </li>
|
||||
<li> new: notched boxplots </li>
|
||||
<li> new: notched boxplots \see JKQTPlotterBoxplotStyling </li>
|
||||
<li> new: several new plot symbols \see JKQTPGraphSymbols </li>
|
||||
<li> changed: removed old selection-code and replaced by general highlighting feature </li>
|
||||
<li> changed: JKQTPStepHorizontalGraph has been renamed to JKQTPSpecialLineHorizontalGraph (vertical variants also) and have gained additional features (baseline for filling and drawing of symbols) </li>
|
||||
<li> changed: filled curve graphs (e.g. JKQTPSpecialLineHorizontalGraph) are now merely a specializedly initialized JKQTPSpecialLineHorizontalGraph </li>
|
||||
<li> deprecated: Removed datarange-feature </li>
|
||||
<li> removed: Removed datarange-feature </li>
|
||||
<li> update: \ref JKQTPLOTTER_USERINTERACTION "reworked user interactions API" </li>
|
||||
<li> update: \ref jkqtplotter_basegraphserrors "reworked error indicator base classes" </li>
|
||||
<li> fixed: colorbars at top were positioned over the plot label </li>
|
||||
|
BIN
doc/images/symbols/none.png
Normal file
After Width: | Height: | Size: 102 B |
BIN
doc/images/symbols/symbol_asterisc.png
Normal file
After Width: | Height: | Size: 383 B |
BIN
doc/images/symbols/symbol_asterisc6.png
Normal file
After Width: | Height: | Size: 376 B |
BIN
doc/images/symbols/symbol_asterisc8.png
Normal file
After Width: | Height: | Size: 510 B |
BIN
doc/images/symbols/symbol_circle.png
Normal file
After Width: | Height: | Size: 398 B |
BIN
doc/images/symbols/symbol_circle_cross.png
Normal file
After Width: | Height: | Size: 455 B |
BIN
doc/images/symbols/symbol_circle_peace.png
Normal file
After Width: | Height: | Size: 505 B |
BIN
doc/images/symbols/symbol_circle_plus.png
Normal file
After Width: | Height: | Size: 441 B |
BIN
doc/images/symbols/symbol_cross.png
Normal file
After Width: | Height: | Size: 230 B |
BIN
doc/images/symbols/symbol_curved_triangle.png
Normal file
After Width: | Height: | Size: 440 B |
BIN
doc/images/symbols/symbol_diamond.png
Normal file
After Width: | Height: | Size: 212 B |
BIN
doc/images/symbols/symbol_diamond_cross.png
Normal file
After Width: | Height: | Size: 287 B |
BIN
doc/images/symbols/symbol_diamond_plus.png
Normal file
After Width: | Height: | Size: 267 B |
BIN
doc/images/symbols/symbol_dot.png
Normal file
After Width: | Height: | Size: 117 B |
BIN
doc/images/symbols/symbol_down_curved_triangle.png
Normal file
After Width: | Height: | Size: 457 B |
BIN
doc/images/symbols/symbol_down_triangle.png
Normal file
After Width: | Height: | Size: 265 B |
BIN
doc/images/symbols/symbol_down_tripod.png
Normal file
After Width: | Height: | Size: 191 B |
BIN
doc/images/symbols/symbol_female.png
Normal file
After Width: | Height: | Size: 308 B |
BIN
doc/images/symbols/symbol_filled_circle.png
Normal file
After Width: | Height: | Size: 568 B |
BIN
doc/images/symbols/symbol_filled_curved_triangle.png
Normal file
After Width: | Height: | Size: 538 B |
BIN
doc/images/symbols/symbol_filled_diamond.png
Normal file
After Width: | Height: | Size: 274 B |
BIN
doc/images/symbols/symbol_filled_down_curved_triangle.png
Normal file
After Width: | Height: | Size: 573 B |
BIN
doc/images/symbols/symbol_filled_down_triangle.png
Normal file
After Width: | Height: | Size: 358 B |
BIN
doc/images/symbols/symbol_filled_hexagon.png
Normal file
After Width: | Height: | Size: 525 B |
BIN
doc/images/symbols/symbol_filled_horizontal_hourglass.png
Normal file
After Width: | Height: | Size: 309 B |
BIN
doc/images/symbols/symbol_filled_hourglass.png
Normal file
After Width: | Height: | Size: 300 B |
BIN
doc/images/symbols/symbol_filled_left_curved_triangle.png
Normal file
After Width: | Height: | Size: 502 B |
BIN
doc/images/symbols/symbol_filled_left_triangle.png
Normal file
After Width: | Height: | Size: 291 B |
BIN
doc/images/symbols/symbol_filled_octagon.png
Normal file
After Width: | Height: | Size: 282 B |
BIN
doc/images/symbols/symbol_filled_pentagon.png
Normal file
After Width: | Height: | Size: 565 B |
BIN
doc/images/symbols/symbol_filled_rect.png
Normal file
After Width: | Height: | Size: 185 B |
BIN
doc/images/symbols/symbol_filled_right_curved_triangle.png
Normal file
After Width: | Height: | Size: 521 B |
BIN
doc/images/symbols/symbol_filled_right_triangle.png
Normal file
After Width: | Height: | Size: 269 B |
BIN
doc/images/symbols/symbol_filled_santaclause.png
Normal file
After Width: | Height: | Size: 599 B |
BIN
doc/images/symbols/symbol_filled_star.png
Normal file
After Width: | Height: | Size: 619 B |
BIN
doc/images/symbols/symbol_filled_triangle.png
Normal file
After Width: | Height: | Size: 328 B |
BIN
doc/images/symbols/symbol_filled_updowntriangle.png
Normal file
After Width: | Height: | Size: 426 B |
BIN
doc/images/symbols/symbol_hexagon.png
Normal file
After Width: | Height: | Size: 333 B |
BIN
doc/images/symbols/symbol_horizontal_hourglass.png
Normal file
After Width: | Height: | Size: 277 B |
BIN
doc/images/symbols/symbol_hourglass.png
Normal file
After Width: | Height: | Size: 236 B |
BIN
doc/images/symbols/symbol_left_curved_triangle.png
Normal file
After Width: | Height: | Size: 406 B |
BIN
doc/images/symbols/symbol_left_triangle.png
Normal file
After Width: | Height: | Size: 220 B |
BIN
doc/images/symbols/symbol_left_tripod.png
Normal file
After Width: | Height: | Size: 176 B |
BIN
doc/images/symbols/symbol_male.png
Normal file
After Width: | Height: | Size: 342 B |
BIN
doc/images/symbols/symbol_octagon.png
Normal file
After Width: | Height: | Size: 254 B |
BIN
doc/images/symbols/symbol_peace.png
Normal file
After Width: | Height: | Size: 227 B |
BIN
doc/images/symbols/symbol_pentagon.png
Normal file
After Width: | Height: | Size: 436 B |
BIN
doc/images/symbols/symbol_plus.png
Normal file
After Width: | Height: | Size: 136 B |
BIN
doc/images/symbols/symbol_rect.png
Normal file
After Width: | Height: | Size: 177 B |
BIN
doc/images/symbols/symbol_rect_cross.png
Normal file
After Width: | Height: | Size: 366 B |
BIN
doc/images/symbols/symbol_rect_downtriangle.png
Normal file
After Width: | Height: | Size: 337 B |
BIN
doc/images/symbols/symbol_rect_lefttriangle.png
Normal file
After Width: | Height: | Size: 261 B |
BIN
doc/images/symbols/symbol_rect_plus.png
Normal file
After Width: | Height: | Size: 222 B |
BIN
doc/images/symbols/symbol_rect_righttriangle.png
Normal file
After Width: | Height: | Size: 252 B |
BIN
doc/images/symbols/symbol_rect_triangle.png
Normal file
After Width: | Height: | Size: 339 B |
BIN
doc/images/symbols/symbol_right_curved_triangle.png
Normal file
After Width: | Height: | Size: 389 B |
BIN
doc/images/symbols/symbol_right_triangle.png
Normal file
After Width: | Height: | Size: 215 B |
BIN
doc/images/symbols/symbol_right_tripod.png
Normal file
After Width: | Height: | Size: 157 B |
BIN
doc/images/symbols/symbol_santaclause.png
Normal file
After Width: | Height: | Size: 401 B |
BIN
doc/images/symbols/symbol_star.png
Normal file
After Width: | Height: | Size: 462 B |
Before Width: | Height: | Size: 382 B |
Before Width: | Height: | Size: 448 B |
Before Width: | Height: | Size: 234 B |
Before Width: | Height: | Size: 182 B |
Before Width: | Height: | Size: 109 B |
Before Width: | Height: | Size: 249 B |
Before Width: | Height: | Size: 643 B |
Before Width: | Height: | Size: 220 B |
Before Width: | Height: | Size: 336 B |
Before Width: | Height: | Size: 594 B |
Before Width: | Height: | Size: 173 B |
Before Width: | Height: | Size: 665 B |
Before Width: | Height: | Size: 324 B |
Before Width: | Height: | Size: 433 B |
Before Width: | Height: | Size: 170 B |
Before Width: | Height: | Size: 165 B |
Before Width: | Height: | Size: 301 B |
Before Width: | Height: | Size: 217 B |
Before Width: | Height: | Size: 445 B |
Before Width: | Height: | Size: 448 B |
Before Width: | Height: | Size: 246 B |
BIN
doc/images/symbols/symbol_target.png
Normal file
After Width: | Height: | Size: 360 B |
BIN
doc/images/symbols/symbol_triangle.png
Normal file
After Width: | Height: | Size: 251 B |
BIN
doc/images/symbols/symbol_tripod.png
Normal file
After Width: | Height: | Size: 184 B |
BIN
doc/images/symbols/symbol_updowntriangle.png
Normal file
After Width: | Height: | Size: 291 B |
@ -19,14 +19,16 @@ int main(int argc, char* argv[])
|
||||
JKQTPDatastore* ds=plot.getDatastore();
|
||||
|
||||
// 2. now we create data a vector of x-values for a simple plot (a sine curve)
|
||||
QVector<double> X;
|
||||
QVector<double> X1, X2;
|
||||
const int Ndata=10; // number of plot points in each curve
|
||||
for (int i=0; i<Ndata; i++) {
|
||||
const double x=double(i)/double(Ndata)*2.0*M_PI;
|
||||
X<<x;
|
||||
if (i<Ndata/2) X1<<x;
|
||||
if (i>Ndata/2) X2<<x;
|
||||
}
|
||||
// and copy it to the datastore
|
||||
size_t columnX=ds->addCopiedColumn(X, "x");
|
||||
size_t columnX1=ds->addCopiedColumn(X1, "x1");
|
||||
size_t columnX2=ds->addCopiedColumn(X2, "x2");
|
||||
|
||||
|
||||
// 3. now we make several plots with different symbol styles and line-styles
|
||||
@ -34,17 +36,19 @@ int main(int argc, char* argv[])
|
||||
// pen styles from the vector pens
|
||||
QVector<Qt::PenStyle> pens {Qt::SolidLine, Qt::DashLine, Qt::DotLine, Qt::DashDotLine, Qt::DashDotDotLine };
|
||||
int ipen=0;
|
||||
for (int symbolID=0; symbolID<=JKQTPMaxSymbolID; symbolID++) {
|
||||
for (int symbolID=0; symbolID<=static_cast<int>(JKQTPMaxSymbolID); symbolID++) {
|
||||
// generate some plot data
|
||||
QVector<double> Y;
|
||||
const QVector<double>& X=(symbolID<=static_cast<int>(JKQTPMaxSymbolID)/2)?X1:X2;
|
||||
const double dy=(symbolID<=static_cast<int>(JKQTPMaxSymbolID)/2)?(static_cast<double>(symbolID)*1.5):(static_cast<double>(symbolID-static_cast<int>(JKQTPMaxSymbolID)/2)*1.5);
|
||||
for (auto& xx: X) {
|
||||
Y<<sin(xx)+static_cast<double>(symbolID)*1.5;
|
||||
Y<<sin(xx)+dy;
|
||||
}
|
||||
|
||||
JKQTPXYLineGraph* graph=new JKQTPXYLineGraph(&plot);
|
||||
|
||||
// copy data into datastore and immediately set the yColumn
|
||||
graph->setXColumn(columnX);
|
||||
graph->setXColumn((symbolID<=JKQTPMaxSymbolID/2)?columnX1:columnX2);
|
||||
graph->setYColumn(ds->addCopiedColumn(Y, "y"+QString::number(symbolID)));
|
||||
|
||||
// set symbol + pen style and color
|
||||
@ -54,7 +58,7 @@ int main(int argc, char* argv[])
|
||||
graph->setDrawLine(static_cast<JKQTPGraphSymbols>(symbolID)!=JKQTPDot);
|
||||
if (!graph->getDrawLine()) lname="";
|
||||
// set symbol size
|
||||
graph->setSymbolSize(14);
|
||||
graph->setSymbolSize(12);
|
||||
// set width of symbol lines
|
||||
graph->setSymbolLineWidth(1.5);
|
||||
// set width of graph line
|
||||
@ -68,14 +72,32 @@ int main(int argc, char* argv[])
|
||||
|
||||
ipen++;
|
||||
if (ipen>=pens.size()) ipen=0;
|
||||
|
||||
// create PNG with the symbol
|
||||
/*QPixmap pix(24,24);
|
||||
pix.fill(Qt::transparent);
|
||||
JKQTPEnhancedPainter p;
|
||||
p.begin(&pix);
|
||||
p.setRenderHint(JKQTPEnhancedPainter::Antialiasing);
|
||||
p.setRenderHint(JKQTPEnhancedPainter::TextAntialiasing);
|
||||
JKQTPPlotSymbol(p, pix.width()/2,pix.height()/2,static_cast<JKQTPGraphSymbols>(symbolID),pix.width()/1.2,1.5,QColor("blue"), QColor("blue").lighter());
|
||||
p.end();
|
||||
pix.save(JKQTPGraphSymbols2String(static_cast<JKQTPGraphSymbols>(symbolID))+".png", "PNG");*/
|
||||
|
||||
}
|
||||
|
||||
|
||||
// 4. autoscale the plot so the graph is contained
|
||||
plot.getPlotter()->setKeyPosition(JKQTPKeyPosition::JKQTPKeyOutsideBottomLeft);
|
||||
plot.getPlotter()->setKeyLayout(JKQTPKeyLayout::JKQTPKeyLayoutMultiColumn);
|
||||
plot.getXAxis()->setShowZeroAxis(false);
|
||||
plot.getYAxis()->setShowZeroAxis(false);
|
||||
plot.setGrid(false);
|
||||
plot.zoomToFit();
|
||||
|
||||
// 5. show plotter and make it a decent size
|
||||
plot.show();
|
||||
plot.resize(800,600);
|
||||
plot.resize(1200, 900);
|
||||
|
||||
return app.exec();
|
||||
}
|
||||
|
@ -39,27 +39,57 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
p.setColor(color);
|
||||
p.setWidthF(qMax(JKQTPlotterDrawinTools::ABS_MIN_LINEWIDTH, symbolLineWidth));
|
||||
p.setStyle(Qt::SolidLine);
|
||||
p.setCapStyle(Qt::FlatCap);
|
||||
painter.setPen(p);
|
||||
QBrush b=painter.brush();
|
||||
b.setColor(fillColor);
|
||||
b.setStyle(Qt::SolidPattern);
|
||||
const double w=symbolSize;
|
||||
const double w2=w/2.0;
|
||||
const double w45=fabs(w*cos(45.0/180.0*M_PI));
|
||||
const double w3=w/3.0;
|
||||
|
||||
// calculate star cordinates as static values
|
||||
static int star_items=0;
|
||||
static double starcordsx[10];
|
||||
static double starcordsy[10];
|
||||
if (star_items==0) {
|
||||
star_items=5;
|
||||
double angle=360.0/double(star_items)/180.0*M_PI;
|
||||
for (int i=0; i<star_items; i++) {
|
||||
static int star5_items=0;
|
||||
static double star5cordsx[10];
|
||||
static double star5cordsy[10];
|
||||
if (star5_items==0) {
|
||||
star5_items=5;
|
||||
double angle=360.0/double(star5_items)/180.0*M_PI;
|
||||
for (int i=0; i<star5_items; i++) {
|
||||
double a=(static_cast<double>(i)+0.5)*angle;
|
||||
starcordsx[i*2]=sin(a);
|
||||
starcordsx[i*2+1]=0.5*sin(a+angle/2.0);
|
||||
starcordsy[i*2]=cos(a);
|
||||
starcordsy[i*2+1]=0.5*cos(a+angle/2.0);
|
||||
star5cordsx[i*2]=sin(a);
|
||||
star5cordsx[i*2+1]=0.5*sin(a+angle/2.0);
|
||||
star5cordsy[i*2]=cos(a);
|
||||
star5cordsy[i*2+1]=0.5*cos(a+angle/2.0);
|
||||
}
|
||||
}
|
||||
static int star6_items=0;
|
||||
static double star6cordsx[12];
|
||||
static double star6cordsy[12];
|
||||
if (star6_items==0) {
|
||||
star6_items=6;
|
||||
double angle=360.0/double(star6_items)/180.0*M_PI;
|
||||
for (int i=0; i<star6_items; i++) {
|
||||
double a=(static_cast<double>(i)+0.5)*angle;
|
||||
star6cordsx[i*2]=sin(a);
|
||||
star6cordsx[i*2+1]=0.5*sin(a+angle/2.0);
|
||||
star6cordsy[i*2]=cos(a);
|
||||
star6cordsy[i*2+1]=0.5*cos(a+angle/2.0);
|
||||
}
|
||||
}
|
||||
static int star8_items=0;
|
||||
static double star8cordsx[16];
|
||||
static double star8cordsy[16];
|
||||
if (star8_items==0) {
|
||||
star8_items=8;
|
||||
double angle=360.0/double(star8_items)/180.0*M_PI;
|
||||
for (int i=0; i<star8_items; i++) {
|
||||
double a=(static_cast<double>(i)+0.5)*angle;
|
||||
star8cordsx[i*2]=sin(a);
|
||||
star8cordsx[i*2+1]=0.5*sin(a+angle/2.0);
|
||||
star8cordsy[i*2]=cos(a);
|
||||
star8cordsy[i*2+1]=0.5*cos(a+angle/2.0);
|
||||
}
|
||||
}
|
||||
|
||||
@ -68,10 +98,6 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
painter.drawPoint(QPointF(x,y));
|
||||
break;
|
||||
case JKQTPCross:{
|
||||
/*QVector<QLineF> lines;
|
||||
lines<<QLineF(x-w2,y-w2,x+w2,y+w2);
|
||||
lines<<QLineF(x-w2,y+w2,x+w2,y-w2);
|
||||
painter.drawLines(lines);*/
|
||||
QPainterPath path;
|
||||
path.moveTo(x-w2,y-w2);
|
||||
path.lineTo(x+w2,y+w2);
|
||||
@ -92,6 +118,42 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
painter.drawEllipse(rectangle);
|
||||
}
|
||||
break;
|
||||
case JKQTPCircleCross:{
|
||||
QRectF rectangle(x-w2, y-w2, w, w);
|
||||
painter.drawEllipse(rectangle);
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x-w45/2.0,y-w45/2.0,x+w45/2.0,y+w45/2.0);
|
||||
lines<<QLineF(x-w45/2.0,y+w45/2.0,x+w45/2.0,y-w45/2.0);
|
||||
painter.drawLines(lines);
|
||||
}
|
||||
break;
|
||||
case JKQTPCirclePlus:{
|
||||
QRectF rectangle(x-w2, y-w2, w, w);
|
||||
painter.drawEllipse(rectangle);
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x,y-w2,x,y+w2);
|
||||
lines<<QLineF(x-w2,y,x+w2,y);
|
||||
painter.drawLines(lines);
|
||||
}
|
||||
break;
|
||||
case JKQTPCirclePeace:{
|
||||
QRectF rectangle(x-w2, y-w2, w, w);
|
||||
painter.drawEllipse(rectangle);
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x,y-w2,x,y+w2);
|
||||
lines<<QLineF(x,y,x+w45/2.0,y+w45/2.0);
|
||||
lines<<QLineF(x,y,x-w45/2.0,y+w45/2.0);
|
||||
painter.drawLines(lines);
|
||||
}
|
||||
break;
|
||||
case JKQTPPeace:{
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x,y-w2,x,y+w2);
|
||||
lines<<QLineF(x,y,x+w45/2.0,y+w45/2.0);
|
||||
lines<<QLineF(x,y,x-w45/2.0,y+w45/2.0);
|
||||
painter.drawLines(lines);
|
||||
}
|
||||
break;
|
||||
case JKQTPTarget:{
|
||||
QPainterPath path;
|
||||
QRectF rectangle3(x-w3, y-w3, 2.0*w3, 2.0*w3);
|
||||
@ -103,6 +165,29 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
painter.drawPath(path);
|
||||
}
|
||||
break;
|
||||
case JKQTPFemale:{
|
||||
QPainterPath path;
|
||||
QRectF rectangle3(x-w2/2.0, y-w2, w2, w2);
|
||||
path.addEllipse(rectangle3);
|
||||
path.moveTo(QPointF(x,y));
|
||||
path.lineTo(QPointF(x,y+w2));
|
||||
path.moveTo(QPointF(x-w2/3.0,y+w2/2.0));
|
||||
path.lineTo(QPointF(x+w2/3.0,y+w2/2.0));
|
||||
painter.drawPath(path);
|
||||
}
|
||||
break;
|
||||
case JKQTPMale:{
|
||||
QPainterPath path;
|
||||
QRectF rectangle3(x-w2/2.0, y-w2/2.0, w2, w2);
|
||||
path.addEllipse(rectangle3);
|
||||
path.moveTo(QPointF(x+w2/2.0*cos(45.0/180.0*M_PI),y-w2/2.0*cos(45.0/180.0*M_PI)));
|
||||
path.lineTo(QPointF(x+w2,y-w2));
|
||||
path.moveTo(QPointF(x+w2-w2/2.0,y-w2));
|
||||
path.lineTo(QPointF(x+w2,y-w2));
|
||||
path.lineTo(QPointF(x+w2,y-w2+w2/2.0));
|
||||
painter.drawPath(path);
|
||||
}
|
||||
break;
|
||||
case JKQTPFilledCircle:{
|
||||
painter.setBrush(b);
|
||||
QRectF rectangle(x-w2, y-w2, w, w);
|
||||
@ -127,6 +212,146 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
painter.drawRect(rectangle);
|
||||
}
|
||||
break;
|
||||
case JKQTPFilledCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.setBrush(b);
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
case JKQTPCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
|
||||
case JKQTPFilledDownCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.rotate(180);
|
||||
painter.setBrush(b);
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
case JKQTPDownCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.rotate(180);
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
case JKQTPFilledLeftCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.rotate(-90);
|
||||
painter.setBrush(b);
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
case JKQTPLeftCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.rotate(-90);
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
case JKQTPFilledRightCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.rotate(90);
|
||||
painter.setBrush(b);
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
case JKQTPRightCurvedTriangle:{
|
||||
painter.save();
|
||||
painter.translate(x,y);
|
||||
painter.rotate(90);
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPainterPath path;
|
||||
path.moveTo(0,0-w2);
|
||||
path.quadTo(0-w/10.0,0+w/4.0, 0-w2,0+w2);
|
||||
path.quadTo(0,0+w/4.0, 0+w2,0+w2);
|
||||
path.quadTo(0+w/10.0,0+w/4.0, 0,0-w2);
|
||||
painter.drawPath(path);
|
||||
painter.restore();
|
||||
}
|
||||
break;
|
||||
|
||||
case JKQTPRectTriangle:{
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x, y-w2)<<QPointF(x+w2, y+w2)<<QPointF(x-w2, y+w2)<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y-w2)<<QPointF(x+w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
}
|
||||
break;
|
||||
case JKQTPRectDownTriangle:{
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y-w2)<<QPointF(x, y+w2)<<QPointF(x+w2, y-w2)<<QPointF(x-w2, y-w2)<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
}
|
||||
break;
|
||||
case JKQTPRectLeftTriangle:{
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x+w2, y-w2)<<QPointF(x-w2, y)<<QPointF(x+w2, y+w2)<<QPointF(x-w2, y+w2)<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y-w2)<<QPointF(x+w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
}
|
||||
break;
|
||||
case JKQTPRectRightTriangle:{
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y)<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x+w2, y-w2)<<QPointF(x-w2, y-w2)<<QPointF(x-w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
}
|
||||
break;
|
||||
case JKQTPRectPlus:{
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QVector<QLineF> lines;
|
||||
@ -167,12 +392,132 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
poly<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y-w2)<<QPointF(x, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPLeftTriangle: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x+w2, y+w2)<<QPointF(x-w2, y)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledLeftTriangle: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x+w2, y+w2)<<QPointF(x-w2, y)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPRightTriangle: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y)<<QPointF(x-w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledRightTriangle: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y)<<QPointF(x-w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPTripod: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x, y-w2, x, y)
|
||||
<<QLineF(x, y, x-w45, y+w45)
|
||||
<<QLineF(x, y, x+w45, y+w45);
|
||||
painter.drawLines(lines);
|
||||
} break;
|
||||
case JKQTPDownTripod: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x, y+w2, x, y)
|
||||
<<QLineF(x, y, x-w45, y-w45)
|
||||
<<QLineF(x, y, x+w45, y-w45);
|
||||
painter.drawLines(lines);
|
||||
} break;
|
||||
case JKQTPLeftTripod: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x-w2, y, x, y)
|
||||
<<QLineF(x, y, x+w45, y-w45)
|
||||
<<QLineF(x, y, x+w45, y+w45);
|
||||
painter.drawLines(lines);
|
||||
} break;
|
||||
case JKQTPRightTripod: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QVector<QLineF> lines;
|
||||
lines<<QLineF(x+w2, y, x, y)
|
||||
<<QLineF(x, y, x-w45, y-w45)
|
||||
<<QLineF(x, y, x-w45, y+w45);
|
||||
painter.drawLines(lines);
|
||||
} break;
|
||||
case JKQTPUpDownTriangle: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x, y+w2)<<QPointF(x+w2, y-w2)<<QPointF(x-w2, y-w2)<<QPointF(x, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x, y-w2)<<QPointF(x-w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledUpDownTriangle: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x, y+w2)<<QPointF(x+w2, y-w2)<<QPointF(x-w2, y-w2)<<QPointF(x, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x, y-w2)<<QPointF(x-w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPSantaClauseHouse: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x+w2, y-w/6.0)<<QPointF(x-w2, y-w/6.0)<<QPointF(x, y-w2)<<QPointF(x+w2, y-w/6.0)<<QPointF(x-w2, y+w2)<<QPointF(x-w2, y-w/6.0)<<QPointF(x+w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledSantaClauseHouse: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x+w2, y-w/6.0)<<QPointF(x-w2, y-w/6.0)<<QPointF(x, y-w2)<<QPointF(x+w2, y-w/6.0)<<QPointF(x-w2, y+w2)<<QPointF(x-w2, y-w/6.0)<<QPointF(x+w2, y+w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPHourglass: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPHorizontalHourglass: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y+w2)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledHourglass: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x+w2, y+w2)<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledHorizontalHourglass: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
poly<<QPointF(x-w2, y+w2)<<QPointF(x-w2, y-w2)<<QPointF(x+w2, y+w2)<<QPointF(x+w2, y-w2);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPDiamond: {
|
||||
QPolygonF poly;
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
poly<<QPointF(x, y-w2)<<QPointF(x+w2, y)<<QPointF(x, y+w2)<<QPointF(x-w2, y);
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPDiamondPlus: {
|
||||
QPolygonF poly;
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
poly<<QPointF(x, y-w2)<<QPointF(x+w2, y)<<QPointF(x, y+w2)<<QPointF(x-w2, y);
|
||||
painter.drawConvexPolygon(poly);
|
||||
painter.drawLine(poly[0], poly[2]);
|
||||
painter.drawLine(poly[1], poly[3]);
|
||||
} break;
|
||||
case JKQTPDiamondCross: {
|
||||
QPolygonF poly;
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
poly<<QPointF(x, y-w2)<<QPointF(x+w2, y)<<QPointF(x, y+w2)<<QPointF(x-w2, y);
|
||||
painter.drawConvexPolygon(poly);
|
||||
painter.drawLine((poly[0]+poly[1])/2.0, (poly[2]+poly[3])/2.0);
|
||||
painter.drawLine((poly[1]+poly[2])/2.0, (poly[3]+poly[0])/2.0);
|
||||
} break;
|
||||
case JKQTPFilledDiamond: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
@ -182,43 +527,88 @@ void JKQTPPlotSymbol(JKQTPEnhancedPainter& painter, double x, double y, JKQTPGra
|
||||
case JKQTPstar: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star_items*2; i++) {
|
||||
poly<<QPointF(x+starcordsx[i]*w2, y+starcordsy[i]*w2);
|
||||
for (int i=0; i<star5_items*2; i++) {
|
||||
poly<<QPointF(x+star5cordsx[i]*w2, y+star5cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledStar: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star_items*2; i++) {
|
||||
poly<<QPointF(x+starcordsx[i]*w2, y+starcordsy[i]*w2);
|
||||
for (int i=0; i<star5_items*2; i++) {
|
||||
poly<<QPointF(x+star5cordsx[i]*w2, y+star5cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPPentagon: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star_items*2; i+=2) {
|
||||
poly<<QPointF(x+starcordsx[i]*w2, y+starcordsy[i]*w2);
|
||||
for (int i=0; i<star5_items*2; i+=2) {
|
||||
poly<<QPointF(x+star5cordsx[i]*w2, y+star5cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPHexagon: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star6_items*2; i+=2) {
|
||||
poly<<QPointF(x+star6cordsx[i]*w2, y+star6cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPOctagon: {
|
||||
painter.setBrush(QColor(Qt::transparent));
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star8_items*2; i+=2) {
|
||||
poly<<QPointF(x+star8cordsx[i]*w2, y+star8cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPAsterisc: {
|
||||
//QVector<QLineF> lines;
|
||||
QPainterPath path;
|
||||
for (int i=0; i<star_items*2; i+=2) {
|
||||
//lines<<QLineF(x+starcordsx[i]*w2, y+starcordsy[i]*w2, x, y);
|
||||
path.moveTo(x+starcordsx[i]*w2, y+starcordsy[i]*w2);
|
||||
for (int i=0; i<star5_items*2; i+=2) {
|
||||
path.moveTo(x+star5cordsx[i]*w2, y+star5cordsy[i]*w2);
|
||||
path.lineTo(x,y);
|
||||
}
|
||||
painter.drawPath(path);
|
||||
} break;
|
||||
case JKQTPAsterisc6: {
|
||||
QPainterPath path;
|
||||
for (int i=0; i<star6_items*2; i+=2) {
|
||||
path.moveTo(x+star6cordsx[i]*w2, y+star6cordsy[i]*w2);
|
||||
path.lineTo(x,y);
|
||||
}
|
||||
painter.drawPath(path);
|
||||
} break;
|
||||
case JKQTPAsterisc8: {
|
||||
QPainterPath path;
|
||||
for (int i=0; i<star8_items*2; i+=2) {
|
||||
path.moveTo(x+star8cordsx[i]*w2, y+star8cordsy[i]*w2);
|
||||
path.lineTo(x,y);
|
||||
}
|
||||
//painter.drawLines(lines);
|
||||
painter.drawPath(path);
|
||||
} break;
|
||||
case JKQTPFilledPentagon: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star_items*2; i+=2) {
|
||||
poly<<QPointF(x+starcordsx[i]*w2, y+starcordsy[i]*w2);
|
||||
for (int i=0; i<star5_items*2; i+=2) {
|
||||
poly<<QPointF(x+star5cordsx[i]*w2, y+star5cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledHexagon: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star6_items*2; i+=2) {
|
||||
poly<<QPointF(x+star6cordsx[i]*w2, y+star6cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
case JKQTPFilledOctagon: {
|
||||
painter.setBrush(b);
|
||||
QPolygonF poly;
|
||||
for (int i=0; i<star8_items*2; i+=2) {
|
||||
poly<<QPointF(x+star8cordsx[i]*w2, y+star8cordsy[i]*w2);
|
||||
}
|
||||
painter.drawConvexPolygon(poly);
|
||||
} break;
|
||||
|
@ -538,10 +538,53 @@ QString JKQTPGraphSymbols2String(JKQTPGraphSymbols pos) {
|
||||
case JKQTPFilledDiamond: return "symbol_filled_diamond";
|
||||
case JKQTPPentagon: return "symbol_pentagon";
|
||||
case JKQTPAsterisc: return "symbol_asterisc";
|
||||
case JKQTPAsterisc6: return "symbol_asterisc6";
|
||||
case JKQTPAsterisc8: return "symbol_asterisc8";
|
||||
case JKQTPFilledPentagon: return "symbol_filled_pentagon";
|
||||
case JKQTPHexagon: return "symbol_hexagon";
|
||||
case JKQTPFilledHexagon: return "symbol_filled_hexagon";
|
||||
case JKQTPOctagon: return "symbol_octagon";
|
||||
case JKQTPFilledOctagon: return "symbol_filled_octagon";
|
||||
case JKQTPRectCross: return "symbol_rect_cross";
|
||||
case JKQTPRectPlus: return "symbol_rect_plus";
|
||||
case JKQTPNoSymbol: return "none";
|
||||
case JKQTPDiamondPlus: return "symbol_diamond_plus";
|
||||
case JKQTPDiamondCross: return "symbol_diamond_cross";
|
||||
case JKQTPCircleCross: return "symbol_circle_cross";
|
||||
case JKQTPCirclePlus: return "symbol_circle_plus";
|
||||
case JKQTPUpDownTriangle: return "symbol_updowntriangle";
|
||||
case JKQTPFilledUpDownTriangle: return "symbol_filled_updowntriangle";
|
||||
case JKQTPSantaClauseHouse: return "symbol_santaclause";
|
||||
case JKQTPFilledSantaClauseHouse: return "symbol_filled_santaclause";
|
||||
case JKQTPHourglass: return "symbol_hourglass";
|
||||
case JKQTPFilledHourglass: return "symbol_filled_hourglass";
|
||||
case JKQTPHorizontalHourglass: return "symbol_horizontal_hourglass";
|
||||
case JKQTPFilledHorizontalHourglass: return "symbol_filled_horizontal_hourglass";
|
||||
case JKQTPRectTriangle: return "symbol_rect_triangle";
|
||||
case JKQTPRectDownTriangle: return "symbol_rect_downtriangle";
|
||||
case JKQTPRectLeftTriangle: return "symbol_rect_lefttriangle";
|
||||
case JKQTPRectRightTriangle: return "symbol_rect_righttriangle";
|
||||
case JKQTPLeftTriangle: return "symbol_left_triangle";
|
||||
case JKQTPFilledLeftTriangle: return "symbol_filled_left_triangle";
|
||||
case JKQTPRightTriangle: return "symbol_right_triangle";
|
||||
case JKQTPFilledRightTriangle: return "symbol_filled_right_triangle";
|
||||
case JKQTPTripod: return "symbol_tripod";
|
||||
case JKQTPDownTripod: return "symbol_down_tripod";
|
||||
case JKQTPLeftTripod: return "symbol_left_tripod";
|
||||
case JKQTPRightTripod: return "symbol_right_tripod";
|
||||
case JKQTPFilledCurvedTriangle: return "symbol_filled_curved_triangle";
|
||||
case JKQTPFilledDownCurvedTriangle: return "symbol_filled_down_curved_triangle";
|
||||
case JKQTPFilledLeftCurvedTriangle: return "symbol_filled_left_curved_triangle";
|
||||
case JKQTPFilledRightCurvedTriangle: return "symbol_filled_right_curved_triangle";
|
||||
case JKQTPCurvedTriangle: return "symbol_curved_triangle";
|
||||
case JKQTPDownCurvedTriangle: return "symbol_down_curved_triangle";
|
||||
case JKQTPLeftCurvedTriangle: return "symbol_left_curved_triangle";
|
||||
case JKQTPRightCurvedTriangle: return "symbol_right_curved_triangle";
|
||||
case JKQTPPeace: return "symbol_peace";
|
||||
case JKQTPFemale: return "symbol_female";
|
||||
case JKQTPMale: return "symbol_male";
|
||||
case JKQTPCirclePeace: return "symbol_circle_peace";
|
||||
case JKQTPSymbolCount: JKQTPGraphSymbols2String(JKQTPMaxSymbolID);
|
||||
}
|
||||
return "";
|
||||
}
|
||||
@ -565,11 +608,54 @@ QString JKQTPGraphSymbols2NameString(JKQTPGraphSymbols pos) {
|
||||
case JKQTPFilledDiamond: return QObject::tr("filled diamond");
|
||||
case JKQTPPentagon: return QObject::tr("pentagon");
|
||||
case JKQTPFilledPentagon: return QObject::tr("filled pentagon");
|
||||
case JKQTPHexagon: return QObject::tr("hexagon");
|
||||
case JKQTPFilledHexagon: return QObject::tr("filled hexagon");
|
||||
case JKQTPOctagon: return QObject::tr("octagon");
|
||||
case JKQTPFilledOctagon: return QObject::tr("filled octagon");
|
||||
case JKQTPTarget: return QObject::tr("target");
|
||||
case JKQTPAsterisc: return QObject::tr("asterisc");
|
||||
case JKQTPAsterisc: return QObject::tr("asterisc, 5-arm");
|
||||
case JKQTPAsterisc6: return QObject::tr("asterisc, 6-arm");
|
||||
case JKQTPAsterisc8: return QObject::tr("asterisc, 8-arm");
|
||||
case JKQTPRectCross: return QObject::tr("square with cross");
|
||||
case JKQTPRectPlus: return QObject::tr("square with plus");
|
||||
case JKQTPNoSymbol: return QObject::tr("none");
|
||||
case JKQTPDiamondPlus: return QObject::tr("diamond with plus");
|
||||
case JKQTPDiamondCross: return QObject::tr("diamond with cross");
|
||||
case JKQTPCircleCross: return QObject::tr("circled cross");
|
||||
case JKQTPCirclePlus: return QObject::tr("circled plus");
|
||||
case JKQTPUpDownTriangle: return QObject::tr("up/down triangle");
|
||||
case JKQTPFilledUpDownTriangle: return QObject::tr("filled up/down triangle");
|
||||
case JKQTPSantaClauseHouse: return QObject::tr("santa clause");
|
||||
case JKQTPFilledSantaClauseHouse: return QObject::tr("filled santa clause");
|
||||
case JKQTPHourglass: return QObject::tr("hourglass");
|
||||
case JKQTPFilledHourglass: return QObject::tr("filled hourglass");
|
||||
case JKQTPHorizontalHourglass: return QObject::tr("horizontal hourglass");
|
||||
case JKQTPFilledHorizontalHourglass: return QObject::tr("filled horizontal hourglass");
|
||||
case JKQTPRectTriangle: return QObject::tr("rectangle with triangle");
|
||||
case JKQTPRectDownTriangle: return QObject::tr("rectangle with downwards triangle");
|
||||
case JKQTPRectLeftTriangle: return QObject::tr("rectangle with leftwards triangle");
|
||||
case JKQTPRectRightTriangle: return QObject::tr("rectangle with rightwards triangle");
|
||||
case JKQTPLeftTriangle: return QObject::tr("left triangle");
|
||||
case JKQTPFilledLeftTriangle: return QObject::tr("filled left triangle");
|
||||
case JKQTPRightTriangle: return QObject::tr("right triangle");
|
||||
case JKQTPFilledRightTriangle: return QObject::tr("filled right triangle");
|
||||
case JKQTPTripod: return QObject::tr("tripod");
|
||||
case JKQTPDownTripod: return QObject::tr("down tripod");
|
||||
case JKQTPLeftTripod: return QObject::tr("left tripod");
|
||||
case JKQTPRightTripod: return QObject::tr("right tripod");
|
||||
case JKQTPFilledCurvedTriangle: return QObject::tr("filled curved triangle");
|
||||
case JKQTPFilledDownCurvedTriangle: return QObject::tr("filled down curved triangle");
|
||||
case JKQTPFilledLeftCurvedTriangle: return QObject::tr("filled left curved triangle");
|
||||
case JKQTPFilledRightCurvedTriangle: return QObject::tr("filled right curved triangle");
|
||||
case JKQTPCurvedTriangle: return QObject::tr("curved triangle");
|
||||
case JKQTPDownCurvedTriangle: return QObject::tr("down curved triangle");
|
||||
case JKQTPLeftCurvedTriangle: return QObject::tr("left curved triangle");
|
||||
case JKQTPRightCurvedTriangle: return QObject::tr("right curved triangle");
|
||||
case JKQTPPeace: return QObject::tr("peace");
|
||||
case JKQTPFemale: return QObject::tr("female");
|
||||
case JKQTPMale: return QObject::tr("male");
|
||||
case JKQTPCirclePeace: return QObject::tr("circled peace");
|
||||
case JKQTPSymbolCount: JKQTPGraphSymbols2NameString(JKQTPMaxSymbolID);
|
||||
}
|
||||
return "";
|
||||
}
|
||||
@ -593,9 +679,52 @@ JKQTPGraphSymbols String2JKQTPGraphSymbols(const QString& pos) {
|
||||
if (s=="symbol_filled_diamond"||s=="filled_diamond"||s=="fd") return JKQTPFilledDiamond;
|
||||
if (s=="symbol_pentagon"||s=="pentagon"||s=="p") return JKQTPPentagon;
|
||||
if (s=="symbol_filled_pentagon"||s=="filled_pentagon"||s=="fp") return JKQTPFilledPentagon;
|
||||
if (s=="symbol_hexagon"||s=="hexagon"||s=="h") return JKQTPHexagon;
|
||||
if (s=="symbol_filled_hexagon"||s=="filled_hexagon"||s=="fh") return JKQTPFilledHexagon;
|
||||
if (s=="symbol_octagon"||s=="octagon"||s=="h") return JKQTPOctagon;
|
||||
if (s=="symbol_filled_octagon"||s=="filled_octagon"||s=="fh") return JKQTPFilledOctagon;
|
||||
if (s=="symbol_asterisc"||s=="asterisc"||s=="*") return JKQTPAsterisc;
|
||||
if (s=="symbol_asterisc6"||s=="asterisc6"||s=="*6") return JKQTPAsterisc6;
|
||||
if (s=="symbol_asterisc8"||s=="asterisc8"||s=="*8") return JKQTPAsterisc8;
|
||||
if (s=="symbol_rect_cross"||s=="rect_cross"||s=="rx") return JKQTPRectCross;
|
||||
if (s=="symbol_rect_plus"||s=="rect_plus"||s=="r+") return JKQTPRectPlus;
|
||||
if (s=="symbol_diamond_plus" || s=="diamond_plus") return JKQTPDiamondPlus;
|
||||
if (s=="symbol_diamond_cross" || s=="diamond_cross") return JKQTPDiamondCross;
|
||||
if (s=="symbol_circle_cross" || s=="circle_cross") return JKQTPCircleCross;
|
||||
if (s=="symbol_circle_plus" || s=="circle_plus") return JKQTPCirclePlus;
|
||||
if (s=="symbol_updowntriangle" || s=="updowntriangle") return JKQTPUpDownTriangle;
|
||||
if (s=="symbol_filled_updowntriangle" || s=="filled_updowntriangle") return JKQTPFilledUpDownTriangle;
|
||||
if (s=="symbol_santaclause" || s=="santaclause") return JKQTPSantaClauseHouse;
|
||||
if (s=="symbol_filled_santaclause" || s=="filled_santaclause") return JKQTPFilledSantaClauseHouse;
|
||||
if (s=="symbol_hourglass" || s=="hourglass") return JKQTPHourglass;
|
||||
if (s=="symbol_filled_hourglass" || s=="filled_hourglass") return JKQTPFilledHourglass;
|
||||
if (s=="symbol_horizontal_hourglass" || s=="horizontal_hourglass") return JKQTPHorizontalHourglass;
|
||||
if (s=="symbol_filled_horizontal_hourglass" || s=="filled_horizontal_hourglass") return JKQTPFilledHorizontalHourglass;
|
||||
if (s=="symbol_rect_triangle" || s=="rect_triangle") return JKQTPRectTriangle;
|
||||
if (s=="symbol_rect_downtriangle" || s=="rect_downtriangle") return JKQTPRectDownTriangle;
|
||||
if (s=="symbol_rect_lefttriangle" || s=="rect_lefttriangle") return JKQTPRectLeftTriangle;
|
||||
if (s=="symbol_rect_righttriangle" || s=="rect_righttriangle") return JKQTPRectRightTriangle;
|
||||
if (s=="symbol_left_triangle" || s=="left_triangle") return JKQTPLeftTriangle;
|
||||
if (s=="symbol_filled_left_triangle" || s=="filled_left_triangle") return JKQTPFilledLeftTriangle;
|
||||
if (s=="symbol_right_triangle" || s=="right_triangle") return JKQTPRightTriangle;
|
||||
if (s=="symbol_filled_right_triangle" || s=="filled_right_triangle") return JKQTPFilledRightTriangle;
|
||||
if (s=="symbol_tripod" || s=="tripod") return JKQTPTripod;
|
||||
if (s=="symbol_down_tripod" || s=="down_tripod") return JKQTPDownTripod;
|
||||
if (s=="symbol_left_tripod" || s=="left_tripod") return JKQTPLeftTripod;
|
||||
if (s=="symbol_right_tripod" || s=="right_tripod") return JKQTPRightTripod;
|
||||
if (s=="symbol_filled_curved_triangle" || s=="filled_curved_triangle") return JKQTPFilledCurvedTriangle;
|
||||
if (s=="symbol_filled_down_curved_triangle" || s=="filled_down_curved_triangle") return JKQTPFilledDownCurvedTriangle;
|
||||
if (s=="symbol_filled_left_curved_triangle" || s=="filled_left_curved_triangle") return JKQTPFilledLeftCurvedTriangle;
|
||||
if (s=="symbol_filled_right_curved_triangle" || s=="filled_right_curved_triangle") return JKQTPFilledRightCurvedTriangle;
|
||||
if (s=="symbol_curved_triangle" || s=="curved_triangle") return JKQTPCurvedTriangle;
|
||||
if (s=="symbol_down_curved_triangle" || s=="down_curved_triangle") return JKQTPDownCurvedTriangle;
|
||||
if (s=="symbol_left_curved_triangle" || s=="left_curved_triangle") return JKQTPLeftCurvedTriangle;
|
||||
if (s=="symbol_right_curved_triangle" || s=="right_curved_triangle") return JKQTPRightCurvedTriangle;
|
||||
if (s=="symbol_peace" || s=="peace") return JKQTPPeace;
|
||||
if (s=="symbol_circle_peace" || s=="circle_peace") return JKQTPCirclePeace;
|
||||
if (s=="symbol_female" || s=="female") return JKQTPFemale;
|
||||
if (s=="symbol_male" || s=="male") return JKQTPMale;
|
||||
|
||||
return JKQTPNoSymbol;
|
||||
}
|
||||
|
||||
|
@ -592,31 +592,80 @@ enum JKQTPGraphPlotstyle {
|
||||
*/
|
||||
enum JKQTPGraphSymbols {
|
||||
JKQTPNoSymbol=0, /*!< \brief plots no symbol at all (usefull together with error bars) */
|
||||
JKQTPDot=1, /*!< \brief a small dot \image html symbols/symbol_symbol_dot.png */
|
||||
JKQTPCross=2, /*!< \brief a X cross \image html symbols/symbol_symbol_cross.png */
|
||||
JKQTPPlus=3, /*!< \brief a + cross \image html symbols/symbol_symbol_plus.png */
|
||||
JKQTPCircle=4, /*!< \brief an unfilled circle \image html symbols/symbol_symbol_circle.png */
|
||||
JKQTPFilledCircle=5, /*!< \brief a filled circle \image html symbols/symbol_symbol_filled_circle.png */
|
||||
JKQTPRect=6, /*!< \brief an unfilled rectangle \image html symbols/symbol_symbol_rect.png */
|
||||
JKQTPFilledRect=7, /*!< \brief a filled rectangle \image html symbols/symbol_symbol_filled_rect.png */
|
||||
JKQTPTriangle=8, /*!< \brief an unfilled triangle (tip at top) \image html symbols/symbol_symbol_triangle.png */
|
||||
JKQTPFilledTriangle=9, /*!< \brief a filled triangle (tip at top) \image html symbols/symbol_symbol_filled_triangle.png */
|
||||
JKQTPDownTriangle=10, /*!< \brief an unfilled triangle (tip at bottom) \image html symbols/symbol_symbol_down_triangle.png */
|
||||
JKQTPFilledDownTriangle=11, /*!< \brief a filled triangle (tip at bottom) \image html symbols/symbol_symbol_filled_down_triangle.png */
|
||||
JKQTPDiamond=12, /*!< \brief an unfilled diamond \image html symbols/symbol_symbol_diamond.png */
|
||||
JKQTPFilledDiamond=13, /*!< \brief a filled diamond \image html symbols/symbol_symbol_filled_diamond.png */
|
||||
JKQTPstar=14, /*!< \brief an unfilled diamond \image html symbols/symbol_symbol_star.png */
|
||||
JKQTPFilledStar=15, /*!< \brief a filled diamond \image html symbols/symbol_symbol_filled_star.png */
|
||||
JKQTPPentagon=16, /*!< \brief an unfilled pentagon \image html symbols/symbol_symbol_pentagon.png */
|
||||
JKQTPFilledPentagon=17, /*!< \brief a filled pentagon \image html symbols/symbol_symbol_filled_pentagon.png */
|
||||
JKQTPAsterisc=18, /*!< \brief an asterisc star '*' \image html symbols/symbol_symbol_asterisc.png */
|
||||
JKQTPDot, /*!< \brief a small dot \image html symbols/symbol_dot.png */
|
||||
JKQTPCross, /*!< \brief a X cross \image html symbols/symbol_cross.png */
|
||||
JKQTPPlus, /*!< \brief a + cross \image html symbols/symbol_plus.png */
|
||||
JKQTPCircle, /*!< \brief an unfilled circle \image html symbols/symbol_circle.png */
|
||||
JKQTPFilledCircle, /*!< \brief a filled circle \image html symbols/symbol_filled_circle.png */
|
||||
JKQTPRect, /*!< \brief an unfilled rectangle \image html symbols/symbol_rect.png */
|
||||
JKQTPFilledRect, /*!< \brief a filled rectangle \image html symbols/symbol_filled_rect.png */
|
||||
JKQTPTriangle, /*!< \brief an unfilled triangle (tip at top) \image html symbols/symbol_triangle.png */
|
||||
JKQTPFilledTriangle, /*!< \brief a filled triangle (tip at top) \image html symbols/symbol_filled_triangle.png */
|
||||
JKQTPDiamond, /*!< \brief an unfilled diamond \image html symbols/symbol_diamond.png */
|
||||
JKQTPFilledDiamond, /*!< \brief a filled diamond \image html symbols/symbol_filled_diamond.png */
|
||||
JKQTPstar, /*!< \brief an unfilled diamond \image html symbols/symbol_star.png */
|
||||
JKQTPFilledStar, /*!< \brief a filled diamond \image html symbols/symbol_filled_star.png */
|
||||
JKQTPPentagon, /*!< \brief an unfilled pentagon \image html symbols/symbol_pentagon.png */
|
||||
JKQTPFilledPentagon, /*!< \brief a filled pentagon \image html symbols/symbol_filled_pentagon.png */
|
||||
JKQTPAsterisc, /*!< \brief an asterisc star with 5 arms \image html symbols/symbol_asterisc.png */
|
||||
JKQTPHourglass, /*!< \brief an hour glass symbol \image html symbols/symbol_hourglass.png */
|
||||
JKQTPFilledHourglass, /*!< \brief a filled hour glass symbol \image html symbols/symbol_filled_hourglass.png */
|
||||
JKQTPCurvedTriangle, /*!< \brief a curved triangle\image html symbols/symbol_tripod.png */
|
||||
JKQTPFilledCurvedTriangle, /*!< \brief a filled curved triangle\image html symbols/symbol_filled_tripod.png */
|
||||
JKQTPHexagon, /*!< \brief an unfilled hexagon \image html symbols/symbol_hexagon.png */
|
||||
JKQTPFilledHexagon, /*!< \brief a filled hexagon \image html symbols/symbol_filled_hexagon.png */
|
||||
|
||||
JKQTPTarget=19, /*!< \brief a target symbol (circle with cross) \image html symbols/symbol_symbol_target.png */
|
||||
JKQTPRectCross=20, /*!< \brief a square symbol with a cross inside \image html symbols/symbol_symbol_rect_cross.png */
|
||||
JKQTPRectPlus=21, /*!< \brief a square symbol with a plus inside \image html symbols/symbol_symbol_rect_plus.png */
|
||||
JKQTPRectCross, /*!< \brief a square symbol with a cross inside \image html symbols/symbol_rect_cross.png */
|
||||
JKQTPRectPlus, /*!< \brief a square symbol with a plus inside \image html symbols/symbol_rect_plus.png */
|
||||
JKQTPRectTriangle, /*!< \brief a square symbol with a triangle inside \image html symbols/symbol_rect_triangle.png */
|
||||
JKQTPRectDownTriangle, /*!< \brief a square symbol with a triangle (tip to the bottom) inside \image html symbols/symbol_rect_downtriangle.png */
|
||||
JKQTPRectLeftTriangle, /*!< \brief a square symbol with a triangle (tip to the left) inside \image html symbols/symbol_rect_lefttriangle.png */
|
||||
JKQTPRectRightTriangle, /*!< \brief a square symbol with a triangle (tip to the right) inside \image html symbols/symbol_rect_righttriangle.png */
|
||||
|
||||
JKQTPMaxSymbolID=JKQTPRectPlus,
|
||||
JKQTPDefaultSymbol=JKQTPCross,
|
||||
JKQTPCircleCross, /*!< \brief a circle symbol with a cross inside \image html symbols/symbol_circle_cross.png */
|
||||
JKQTPCirclePlus, /*!< \brief a circle symbol with a plus inside \image html symbols/symbol_circle_plus.png */
|
||||
JKQTPCirclePeace, /*!< \brief a circled peace symbol \image html symbols/symbol_circle_peace.png */
|
||||
|
||||
JKQTPDiamondPlus, /*!< \brief a diamond symbol with a plus inside \image html symbols/symbol_diamond_plus.png */
|
||||
JKQTPDiamondCross, /*!< \brief a diamond symbol with a cross inside \image html symbols/symbol_diamond_cross.png */
|
||||
|
||||
JKQTPTripod, /*!< \brief a tripod symbol \image html symbols/symbol_tripod.png */
|
||||
JKQTPDownTripod, /*!< \brief a tripod symbol, pointing down \image html symbols/symbol_down_tripod.png */
|
||||
JKQTPLeftTripod, /*!< \brief a tripod symbol, pointing to the left \image html symbols/symbol_left_tripod.png */
|
||||
JKQTPRightTripod, /*!< \brief a tripod symbol, pointing to the right \image html symbols/symbol_right_tripod.png */
|
||||
JKQTPAsterisc6, /*!< \brief an asterisc star with 6 arms \image html symbols/symbol_asterisc6.png */
|
||||
JKQTPAsterisc8, /*!< \brief an asterisc star with 8 arms \image html symbols/symbol_asterisc8.png */
|
||||
JKQTPPeace, /*!< \brief a peace symbol \image html symbols/symbol_peace.png */
|
||||
JKQTPTarget, /*!< \brief a target symbol (circle with cross) \image html symbols/symbol_target.png */
|
||||
|
||||
JKQTPDownTriangle, /*!< \brief an unfilled triangle (tip at bottom) \image html symbols/symbol_down_triangle.png */
|
||||
JKQTPFilledDownTriangle, /*!< \brief a filled triangle (tip at bottom) \image html symbols/symbol_filled_down_triangle.png */
|
||||
JKQTPLeftTriangle, /*!< \brief an unfilled triangle (tip to the left) \image html symbols/symbol_left_triangle.png */
|
||||
JKQTPFilledLeftTriangle, /*!< \brief a filled triangle (tip to the left) \image html symbols/symbol_filled_left_triangle.png */
|
||||
JKQTPRightTriangle, /*!< \brief an unfilled triangle (tip to the right) \image html symbols/symbol_right_triangle.png */
|
||||
JKQTPFilledRightTriangle, /*!< \brief a filled triangle (tip to the right) \image html symbols/symbol_filled_right_triangle.png */
|
||||
JKQTPDownCurvedTriangle, /*!< \brief a curved triangle, pointing down \image html symbols/symbol_down_tripod.png */
|
||||
JKQTPFilledDownCurvedTriangle, /*!< \brief a filled curved triangle, pointing down \image html symbols/symbol_filled_down_tripod.png */
|
||||
JKQTPLeftCurvedTriangle, /*!< \brief a curved triangle, pointing to the left \image html symbols/symbol_left_tripod.png */
|
||||
JKQTPFilledLeftCurvedTriangle, /*!< \brief a filled curved triangle, pointing to the left \image html symbols/symbol_filled_left_tripod.png */
|
||||
JKQTPRightCurvedTriangle, /*!< \brief a curved triangle, pointing to the right \image html symbols/symbol_right_tripod.png */
|
||||
JKQTPFilledRightCurvedTriangle, /*!< \brief a filled curved triangle, pointing to the right \image html symbols/symbol_filled_right_tripod.png */
|
||||
JKQTPOctagon, /*!< \brief an unfilled octagon \image html symbols/symbol_octagon.png */
|
||||
JKQTPFilledOctagon, /*!< \brief a filled octagon \image html symbols/symbol_filled_octagon.png */
|
||||
JKQTPUpDownTriangle, /*!< \brief a overlay of an up and a down triangle symbol \image html symbols/symbol_updowntriangle.png */
|
||||
JKQTPFilledUpDownTriangle, /*!< \brief a filled version of the overlay of an up and a down triangle \image html symbols/symbol_filled_updowntriangle.png */
|
||||
JKQTPHorizontalHourglass, /*!< \brief a horizontal hour glass symbol \image html symbols/symbol_horizontal_hourglass.png */
|
||||
JKQTPFilledHorizontalHourglass, /*!< \brief a filled horizontal hour glass symbol \image html symbols/symbol_filled_horizontal_hourglass.png */
|
||||
|
||||
JKQTPSantaClauseHouse, /*!< \brief a small house symbol ("Das is das haus vom Nicolaus") \image html symbols/symbol_santaclause.png */
|
||||
JKQTPFilledSantaClauseHouse, /*!< \brief a filled small house symbol ("Das is das haus vom Nicolaus") \image html symbols/symbol_filled_santaclause.png */
|
||||
|
||||
JKQTPMale, /*!< \brief a male symbol \image html symbols/symbol_male.png */
|
||||
JKQTPFemale, /*!< \brief a female symbol \image html symbols/symbol_female.png */
|
||||
|
||||
JKQTPSymbolCount, /*!< \brief can be used to iterate over all symbols using: <code>for (int i=0; i<static_cast<int>(JKQTPSymbolCount); i++) { JKQTPGraphSymbols s=static_cast<JKQTPGraphSymbols>(i); ... }</code> */
|
||||
JKQTPMaxSymbolID=JKQTPSymbolCount-1, /*!< \brief points to the last available symbol, can be used to iterate over all symbols: <code>for (int i=0; i<=static_cast<int>(JKQTPMaxSymbolID); i++) { JKQTPGraphSymbols s=static_cast<JKQTPGraphSymbols>(i); ... }</code> */
|
||||
JKQTPDefaultSymbol=JKQTPCross, /*!< \brief a default symbol used for plotting */
|
||||
};
|
||||
|
||||
/** \brief converts a JKQTPGraphSymbols variable into a identifier string
|
||||
|
Before Width: | Height: | Size: 112 KiB After Width: | Height: | Size: 239 KiB |
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 18 KiB |