Index: Interface_Web/trunk/pspaWT/sources/userInterface/src/GWt_pspaApplication.cc
===================================================================
--- Interface_Web/trunk/pspaWT/sources/userInterface/src/GWt_pspaApplication.cc	(revision 416)
+++ Interface_Web/trunk/pspaWT/sources/userInterface/src/GWt_pspaApplication.cc	(revision 417)
@@ -702,94 +702,94 @@
 
 
-// parametre drawPoints : true = on trace des points (phase space) ; false = on trace des lignes (enveloppes...) 
-void PspaApplication::chartPlot2vec(WContainerWidget* toto, vector<double>& xcor, vector<double>& ycor, bool drawPoints,string title,string legendx, string legendy,int width, int height, bool makeIcon)
-{
-    int nbpts = xcor.size();
-    cout << " PspaApplication::chartPlot2vec nbpts = " << nbpts << endl;
-    WStandardItemModel *model = new WStandardItemModel(nbpts, 2, toto);
-    for (int i = 0; i < nbpts; ++i) {
-        model->setData(i, 0, xcor.at(i));
-        model->setData(i, 1, ycor.at(i));
-        //    cout << " PspaApplication::chartPlot2vec el= " << i+1 << " x= " << xcor.at(i) << " y= " << ycor.at(i) << endl;
-    }
-    
-    WCartesianChart *chart = new WCartesianChart(toto);
-    if (!makeIcon) {
-        chart->setTitle(title);
-    }
-    chart->initLayout();
-    
-    chart->setModel(model);        // set the model
-    chart->setXSeriesColumn(0);    // set the column that holds the X data
-    if (!makeIcon) {
-        chart->setLegendEnabled(true); // enable the legend
-    } else {
-        chart->setLegendEnabled(false); // enable the legend
-    }
-    
-    chart->setType(ScatterPlot);   // set type to ScatterPlot
-    
-    // Typically, for mathematical functions, you want the axes to cross
-    // at the 0 mark:
-    chart->axis(XAxis).setLocation(ZeroValue);
-    chart->axis(YAxis).setLocation(ZeroValue);
-
-    // Provide space for the X and Y axis and title.
-    chart->setPlotAreaPadding(80, Left);  // ?
-    chart->setPlotAreaPadding(40, Bottom);
-    chart->setPlotAreaPadding(60, Top);
-    if ( drawPoints ) {
-      WDataSeries s(1, PointSeries, Y1Axis);
-      chart->addSeries(s);    
-    } else {
-      WDataSeries s(1, LineSeries, Y1Axis);
-      chart->addSeries(s);    
-    }
-    chart->resize(width, height); // WPaintedWidget must be given explicit size
-    
-    
-    WAxis& axis = chart->axis(XAxis);
-    axis.setLabelFormat("%.3f");
-    //       axis.setGridLinesEnabled(true);
-    axis.setTitle(legendx);
-    
-    WAxis& axey = chart->axis(YAxis);
-    axey.setTitle(legendy);
-    // axis = chart->axis(YAxis);
-    // axis.setLabelFormat("%.3f");
-    // axis.setGridLinesEnabled(true);
-    // axis.setTitle(legendy);
-    
-    if (makeIcon) {
-      chart->setPlotAreaPadding(0);
-      chart->setAxisPadding(0);
-      WFont xAxisFont = chart->axis(XAxis).labelFont();
-      xAxisFont.setSize(8);
-      WFont yAxisFont = chart->axis(YAxis).labelFont();
-      yAxisFont.setSize(8);
-      chart->axis(XAxis).setLabelFont(xAxisFont);
-      chart->axis(YAxis).setLabelFont(yAxisFont);
-    }
-
-#ifdef HAS_IMAGEMAGIC
-/*    Wt::WRasterImage pngImage("png", 600, 600);
-    Wt::WPainter p(&pngImage);
-    chart->paint(p);
-    std::string name;
-    name = workingDir_ + "/chart-"+sessionId ()+".png";
-    std::ofstream f(name.c_str(), std::ios::out |std::ios::trunc | std::ios::binary);
-    pngImage.write(f);    
-    new WText("<a href='workingArea/chart-"+sessionId ()+".png' target='_blank'>Afficher l'image</a>",toto);
-    
-  Wt::WPdfImage pdfImage("30cm", "30cm");
-    Wt::WPainter p1(&pdfImage);
-    pdfImage.init();
-    chart->paint(p1);
-    name = workingDir_ + "/chart-"+sessionId ()+".pdf";
-    std::ofstream f1(name.c_str(), std::ios::out |std::ios::trunc | std::ios::binary);
-    pdfImage.write(f1);
- */
-#endif
-}
+// // parametre drawPoints : true = on trace des points (phase space) ; false = on trace des lignes (enveloppes...) 
+// void PspaApplication::chartPlot2vec(WContainerWidget* toto, vector<double>& xcor, vector<double>& ycor, bool drawPoints,string title,string legendx, string legendy,int width, int height, bool makeIcon)
+// {
+//     int nbpts = xcor.size();
+//     cout << " PspaApplication::chartPlot2vec nbpts = " << nbpts << endl;
+//     WStandardItemModel *model = new WStandardItemModel(nbpts, 2, toto);
+//     for (int i = 0; i < nbpts; ++i) {
+//         model->setData(i, 0, xcor.at(i));
+//         model->setData(i, 1, ycor.at(i));
+//         //    cout << " PspaApplication::chartPlot2vec el= " << i+1 << " x= " << xcor.at(i) << " y= " << ycor.at(i) << endl;
+//     }
+    
+//     WCartesianChart *chart = new WCartesianChart(toto);
+//     if (!makeIcon) {
+//         chart->setTitle(title);
+//     }
+//     chart->initLayout();
+    
+//     chart->setModel(model);        // set the model
+//     chart->setXSeriesColumn(0);    // set the column that holds the X data
+//     if (!makeIcon) {
+//         chart->setLegendEnabled(true); // enable the legend
+//     } else {
+//         chart->setLegendEnabled(false); // enable the legend
+//     }
+    
+//     chart->setType(ScatterPlot);   // set type to ScatterPlot
+    
+//     // Typically, for mathematical functions, you want the axes to cross
+//     // at the 0 mark:
+//     chart->axis(XAxis).setLocation(ZeroValue);
+//     chart->axis(YAxis).setLocation(ZeroValue);
+
+//     // Provide space for the X and Y axis and title.
+//     chart->setPlotAreaPadding(80, Left);  // ?
+//     chart->setPlotAreaPadding(40, Bottom);
+//     chart->setPlotAreaPadding(60, Top);
+//     if ( drawPoints ) {
+//       WDataSeries s(1, PointSeries, Y1Axis);
+//       chart->addSeries(s);    
+//     } else {
+//       WDataSeries s(1, LineSeries, Y1Axis);
+//       chart->addSeries(s);    
+//     }
+//     chart->resize(width, height); // WPaintedWidget must be given explicit size
+    
+    
+//     WAxis& axis = chart->axis(XAxis);
+//     axis.setLabelFormat("%.3f");
+//     //       axis.setGridLinesEnabled(true);
+//     axis.setTitle(legendx);
+    
+//     WAxis& axey = chart->axis(YAxis);
+//     axey.setTitle(legendy);
+//     // axis = chart->axis(YAxis);
+//     // axis.setLabelFormat("%.3f");
+//     // axis.setGridLinesEnabled(true);
+//     // axis.setTitle(legendy);
+    
+//     if (makeIcon) {
+//       chart->setPlotAreaPadding(0);
+//       chart->setAxisPadding(0);
+//       WFont xAxisFont = chart->axis(XAxis).labelFont();
+//       xAxisFont.setSize(8);
+//       WFont yAxisFont = chart->axis(YAxis).labelFont();
+//       yAxisFont.setSize(8);
+//       chart->axis(XAxis).setLabelFont(xAxisFont);
+//       chart->axis(YAxis).setLabelFont(yAxisFont);
+//     }
+
+// #ifdef HAS_IMAGEMAGIC
+// /*    Wt::WRasterImage pngImage("png", 600, 600);
+//     Wt::WPainter p(&pngImage);
+//     chart->paint(p);
+//     std::string name;
+//     name = workingDir_ + "/chart-"+sessionId ()+".png";
+//     std::ofstream f(name.c_str(), std::ios::out |std::ios::trunc | std::ios::binary);
+//     pngImage.write(f);    
+//     new WText("<a href='workingArea/chart-"+sessionId ()+".png' target='_blank'>Afficher l'image</a>",toto);
+    
+//   Wt::WPdfImage pdfImage("30cm", "30cm");
+//     Wt::WPainter p1(&pdfImage);
+//     pdfImage.init();
+//     chart->paint(p1);
+//     name = workingDir_ + "/chart-"+sessionId ()+".pdf";
+//     std::ofstream f1(name.c_str(), std::ios::out |std::ios::trunc | std::ios::binary);
+//     pdfImage.write(f1);
+//  */
+// #endif
+// }
 
 
@@ -950,5 +950,6 @@
 */
   
-  Wt::WPdfImage pdfImage("1000", "600");
+//  Wt::WPdfImage pdfImage("1000", "600");
+  WPdfImage pdfImage("1000", "600");
   {
    Wt::WPainter p1(&pdfImage);
