Index: trunk/SophyaPI/PI/piaxes.cc
===================================================================
--- trunk/SophyaPI/PI/piaxes.cc	(revision 2085)
+++ trunk/SophyaPI/PI/piaxes.cc	(revision 2088)
@@ -5,7 +5,7 @@
 
 #include "machdefs.h"
-#include "piaxes.h"
 #include <stdio.h>
 #include <math.h>
+#include "piaxes.h"
 
 inline void dble_SWAP(double a, double b) {double tmp=a; a=b; b=tmp;}
@@ -63,6 +63,6 @@
   
     if (flags & kMajTicks) {
-        DrawHTicks(g, (yMin+yMax)/2., xMajTickLen, xMajTickLen, xFirstMajTick, xMajTickStep);
-        DrawVTicks(g, (xMin+xMax)/2., yMajTickLen, yMajTickLen, yFirstMajTick, yMajTickStep);
+        DrawHTicks(g, (yMin+yMax)/2., xMajTickLen, xMajTickLen, xMajTicks);
+        DrawVTicks(g, (xMin+xMax)/2., yMajTickLen, yMajTickLen, yMajTicks);
     }
     
@@ -70,6 +70,6 @@
   
     if (flags & kMinTicks) {
-        DrawHTicks(g, (yMin+yMax)/2., xMinTickLen, xMinTickLen, xFirstMinTick, xMinTickStep);
-        DrawVTicks(g, (xMin+xMax)/2., yMinTickLen, yMinTickLen, yFirstMinTick, yMinTickStep);
+        DrawHTicks(g, (yMin+yMax)/2., xMinTickLen, xMinTickLen, xMinTicks);
+        DrawVTicks(g, (xMin+xMax)/2., yMinTickLen, yMinTickLen, yMinTicks);
     }
     
@@ -78,11 +78,11 @@
     if (flags & kLabels) {
       if (!aYdir)
-        DrawHLabels(g, (yMin+yMax)/2.-xMajTickLen*2, xFirstMajTick, xMajTickStep,PI_VerticalTop);
+        DrawHLabels(g, (yMin+yMax)/2.-xMajTickLen*2, xMajTicks, PI_VerticalTop);
       else 
-        DrawHLabels(g, (yMin+yMax)/2.+xMajTickLen*2, xFirstMajTick, xMajTickStep,PI_VerticalTop);
+        DrawHLabels(g, (yMin+yMax)/2.+xMajTickLen*2, xMajTicks, PI_VerticalTop);
       if (!aXdir)
-        DrawVLabels(g, (xMin+xMax)/2.-yMajTickLen*2, yFirstMajTick, yMajTickStep,PI_HorizontalRight);
+        DrawVLabels(g, (xMin+xMax)/2.-yMajTickLen*2, yMajTicks, PI_HorizontalRight);
       else 
-        DrawVLabels(g, (xMin+xMax)/2.+yMajTickLen*2, yFirstMajTick, yMajTickStep,PI_HorizontalRight);
+        DrawVLabels(g, (xMin+xMax)/2.+yMajTickLen*2, yMajTicks, PI_HorizontalRight);
     }
     
@@ -116,8 +116,8 @@
   
     if (flags & kMajTicks) {
-        DrawHTicks(g, yMin, intXMajTickLen, extXMajTickLen, xFirstMajTick, xMajTickStep);
-        DrawHTicks(g, yMax, extXMajTickLen, intXMajTickLen, xFirstMajTick, xMajTickStep);
-        DrawVTicks(g, xMin, extYMajTickLen, intYMajTickLen, yFirstMajTick, yMajTickStep);
-        DrawVTicks(g, xMax, intYMajTickLen, extYMajTickLen, yFirstMajTick, yMajTickStep);
+        DrawHTicks(g, yMin, intXMajTickLen, extXMajTickLen, xMajTicks);
+        DrawHTicks(g, yMax, extXMajTickLen, intXMajTickLen, xMajTicks);
+        DrawVTicks(g, xMin, extYMajTickLen, intYMajTickLen, yMajTicks);
+        DrawVTicks(g, xMax, intYMajTickLen, extYMajTickLen, yMajTicks);
     }
     
@@ -125,8 +125,8 @@
   
     if (flags & kMinTicks) {
-        DrawHTicks(g, yMin, intXMinTickLen, extXMinTickLen, xFirstMinTick, xMinTickStep);
-        DrawHTicks(g, yMax, extXMinTickLen, intXMinTickLen, xFirstMinTick, xMinTickStep);
-        DrawVTicks(g, xMin, extYMinTickLen, intYMinTickLen, yFirstMinTick, yMinTickStep);
-        DrawVTicks(g, xMax, intYMinTickLen, extYMinTickLen, yFirstMinTick, yMinTickStep);
+        DrawHTicks(g, yMin, intXMinTickLen, extXMinTickLen, xMinTicks);
+        DrawHTicks(g, yMax, extXMinTickLen, intXMinTickLen, xMinTicks);
+        DrawVTicks(g, xMin, extYMinTickLen, intYMinTickLen, yMinTicks);
+        DrawVTicks(g, xMax, intYMinTickLen, extYMinTickLen, yMinTicks);
     }
 
@@ -136,18 +136,14 @@
     if (flags & kLabels) {
       if (!aYdir) {
-        DrawHLabels(g, g->DeltaUCY(yMin, -xMajTickLen*2), xFirstMajTick, xMajTickStep,PI_VerticalTop);
-        //DrawHLabels(g, g->DeltaUCY(yMax,  xMajTickLen*2), xFirstMajTick, xMajTickStep,PI_VerticalBottom);
+        DrawHLabels(g, g->DeltaUCY(yMin, -xMajTickLen*2), xMajTicks, PI_VerticalTop);
       }
       else {
-        //DrawHLabels(g, g->DeltaUCY(yMin, -xMajTickLen*2), xFirstMajTick, xMajTickStep,PI_VerticalBottom);
-        DrawHLabels(g, g->DeltaUCY(yMax,  xMajTickLen*2), xFirstMajTick, xMajTickStep,PI_VerticalTop);
+        DrawHLabels(g, g->DeltaUCY(yMax,  xMajTickLen*2), xMajTicks, PI_VerticalTop);
       }
       if (!aXdir) {
-        DrawVLabels(g, g->DeltaUCX(xMin, -yMajTickLen*2), yFirstMajTick, yMajTickStep,PI_HorizontalRight);
-        //DrawVLabels(g, g->DeltaUCX(xMax,  yMajTickLen*2), yFirstMajTick, yMajTickStep,PI_HorizontalLeft);
+        DrawVLabels(g, g->DeltaUCX(xMin, -yMajTickLen*2), yMajTicks, PI_HorizontalRight);
       }
       else {
-        //DrawVLabels(g, g->DeltaUCX(xMin, -yMajTickLen*2), yFirstMajTick, yMajTickStep,PI_HorizontalLeft);
-        DrawVLabels(g, g->DeltaUCX(xMax,  yMajTickLen*2), yFirstMajTick, yMajTickStep,PI_HorizontalRight);
+        DrawVLabels(g, g->DeltaUCX(xMax,  yMajTickLen*2), yMajTicks, PI_HorizontalRight);
       }
     }
@@ -171,14 +167,8 @@
 
   int ntick_x = (aXlog) ? 6 : 10;
-  BestTicks(xMin,xMax,ntick_x,xMajTickStep,xFirstMajTick);
-  xMinTickStep = xMajTickStep/5;
-  xFirstMinTick = floor(xMin / xMinTickStep) * xMinTickStep;
-  if(xFirstMinTick < xMin) xFirstMinTick += xMinTickStep;
+  BestTicks(xMin,xMax,ntick_x,xMajTicks,xMinTicks);
 
   int ntick_y = (aYlog) ? 6 : 12;
-  BestTicks(yMin,yMax,ntick_y,yMajTickStep,yFirstMajTick);
-  yMinTickStep = yMajTickStep/5;
-  yFirstMinTick = floor(yMin / yMinTickStep) * yMinTickStep;
-  if(yFirstMinTick < yMin) yFirstMinTick += yMinTickStep;
+  BestTicks(yMin,yMax,ntick_y,yMajTicks,yMinTicks);
 
   yMajTickLen = (xMax-xMin)/100;
@@ -191,41 +181,49 @@
 /* --Methode-- */
 void PIAxes::DrawHTicks(PIGraphicUC* g, double y, double tickUp, 
-			double tickDown, double xBeg, double xStep)
-{
-  for (double x=xBeg; x<=xMax+xStep/10.; x += xStep)
-    g->DrawLine(x, g->DeltaUCY(y, -tickDown), x, g->DeltaUCY(y, tickUp));
+			double tickDown, vector<double>& xticks)
+{
+  if(xticks.size()<=0) return;
+  for(unsigned int i=0;i<xticks.size();i++) {
+    if(xticks[i]>xMax) break;
+    g->DrawLine(xticks[i],g->DeltaUCY(y,-tickDown),xticks[i],g->DeltaUCY(y,tickUp));
+  }
 }
 
 /* --Methode-- */
 void PIAxes::DrawVTicks(PIGraphicUC* g, double x, double tickLeft, 
-			double tickRight, double yBeg, double yStep)
-{
-  for (double y=yBeg; y<=yMax; y += yStep)
-    g->DrawLine(g->DeltaUCX(x, -tickLeft), y, g->DeltaUCX(x,tickRight), y);
-}
-
-/* --Methode-- */
-void PIAxes::DrawHLabels(PIGraphicUC* g, double y, double xBeg, 
-			 double xStep, unsigned long just)
-{
-
+			double tickRight, vector<double>& yticks)
+{
+  if(yticks.size()<=0) return;
+  for(unsigned int i=0;i<yticks.size();i++) {
+    if(yticks[i]>yMax) break;
+    g->DrawLine(g->DeltaUCX(x,-tickLeft),yticks[i],g->DeltaUCX(x,tickRight),yticks[i]);
+  }
+}
+
+/* --Methode-- */
+void PIAxes::DrawHLabels(PIGraphicUC* g, double y, vector<double>& xticks, unsigned long just)
+{
+
+  if(xticks.size()<=1) return;
   // Choix du bon format pour les labels des axes;
   char label[64]; string format; double fac=1.; bool p10=false;
-  int npuiss = BonFormatAxes(xBeg,xMax,xStep,format,2,1);
+  double xstep=xticks[1]-xticks[0];
+  int npuiss = BonFormatAxes(xticks[0],xMax,xstep,format,2,1);
   if(npuiss<-2 || npuiss>3) {p10 = true; fac=pow(10.,(double)npuiss);}
-  else BonFormatAxes(xBeg,xMax,xStep,format,0,1);
+  else BonFormatAxes(xticks[0],xMax,xstep,format,0,1);
 
   double xOffset = 0;
-  double xlastlabelfin = xBeg - 2.*(xMax-xBeg);
-  for(double x=xBeg; x<=xMax+xStep/10.; x+=xStep) {
+  double xlastlabelfin = xticks[0] - 2.*(xMax-xticks[0]);
+  for(unsigned int i=0;i<xticks.size();i++) {
+    if(xticks[i]>xMax) break;
     //Attention erreur d'arrondi x->0 (on code 5.1698e-26 au lieu de 0)
-    double xx = (fabs(x/xStep)<1.e-5) ? 0.: x;
+    double xx = (fabs(xticks[i]/xstep)<1.e-5) ? 0.: xticks[i];
     sprintf(label,format.c_str(),xx/fac);
-    for(int kk=0;kk<64;kk++) if(label[kk]==' ') {label[kk]='\0'; break;}
+    Arrange_Label(label);
     double largeur = g->CalcStringWidth(label);
     if(aXdir) xOffset = largeur/2; else xOffset=-largeur/2;
-    if(x+xOffset > xlastlabelfin) {
-      g->DrawString(x,y,label,PI_HorizontalCenter|just);
-      xlastlabelfin = x + xOffset + 1.1*largeur;
+    if(xticks[i]+xOffset > xlastlabelfin) {
+      g->DrawString(xticks[i],y,label,PI_HorizontalCenter|just);
+      xlastlabelfin = xticks[i] + xOffset + 1.1*largeur;
     }
   }
@@ -244,19 +242,21 @@
 
 /* --Methode-- */
-void PIAxes::DrawVLabels(PIGraphicUC* g, double x, double yBeg, 
-			 double yStep, unsigned long just)
-{
-
+void PIAxes::DrawVLabels(PIGraphicUC* g, double x, vector<double>& yticks, unsigned long just)
+{
+
+  if(yticks.size()<=1) return;
   // Choix du bon format pour les labels des axes;
   char label[64]; string format; double fac=1.; bool p10=false;
-  int npuiss = BonFormatAxes(yBeg,yMax,yStep,format,2,1);
+  double ystep=yticks[1]-yticks[0];
+  int npuiss = BonFormatAxes(yticks[0],yMax,ystep,format,2,1);
   if(npuiss<-2 || npuiss>3) {p10 = true; fac=pow(10.,(double)npuiss);}
-  else BonFormatAxes(yBeg,yMax,yStep,format,0,1);
-
-  for(double y=yBeg; y<=yMax; y += yStep) {
-    double yy = (fabs(y/yStep)<1.e-5) ? 0.: y;
+  else BonFormatAxes(yticks[0],yMax,ystep,format,0,1);
+
+  for(unsigned int i=0;i<yticks.size();i++) {
+    if(yticks[i]>yMax) break;
+    double yy = (fabs(yticks[i]/ystep)<1.e-5) ? 0.: yticks[i];
     sprintf(label,format.c_str(),yy/fac);
-    for(int kk=0;kk<64;kk++) if(label[kk]==' ') {label[kk]='\0'; break;}
-    g->DrawString(x,y,label,PI_VerticalCenter|just);
+    Arrange_Label(label);
+    g->DrawString(x,yticks[i],label,PI_VerticalCenter|just);
   }
 
@@ -276,12 +276,17 @@
 {
   PILineAtt savlineatt = g->GetLineAtt();
-//  g->SelLine(PI_ThinDashedLine);
   g->SelLine(PI_ThinDottedLine);
 
-  for (double x=xFirstMajTick; x<=xMax; x += xMajTickStep)
-    g->DrawLine(x, yMin, x, yMax);
-
-  for (double y=yFirstMajTick; y<=yMax; y += yMajTickStep)
-    g->DrawLine(xMin, y, xMax, y);
+  if(xMajTicks.size()>0)
+    for(unsigned int i=0;i<xMajTicks.size();i++) {
+      if(xMajTicks[i]>xMax) break;
+      g->DrawLine(xMajTicks[i], yMin, xMajTicks[i], yMax);
+    }
+
+  if(yMajTicks.size()>0)
+    for(unsigned int i=0;i<yMajTicks.size();i++) {
+      if(yMajTicks[i]>yMax) break;
+      g->DrawLine(xMin, yMajTicks[i], xMax, yMajTicks[i]);
+    }
 
   g->SelLine(savlineatt);
@@ -292,38 +297,49 @@
 /* --Methode-Static-- */
 void PIAxes::BestTicks(double xmin,double xmax,int nticks
-                        ,double& steptick,double& xfirsttick)
+                      ,vector<double>& majticks,vector<double>& minticks)
 // *** Calcul de l'intervalle entre les ticks et de la valeur du premier tick
 {
-double d=xmax-xmin; if(d<1.e-100) d=1.e-100; //if (d<1.e-39) d=1.e-39;
-double ld  = log10(d);
-double fld = floor( ((ld<0.)? -ld: ld) );
-double del,del0;
-if(ld>=0.) {fld-=1.; del0=del=pow(10.,fld);}
-  else     {fld+=2.; del0=del=pow(10.,-fld);}
-// *** Intervalle entre les ticks
-// xmin  xmax    d       ld       fld -->fld  del0
-// 1     1500    1499    3.17     3      2    10^2
-// 1     9500    9499    3.98     3      2    10^2
-// 1     1.005   0.005   -2.3     2      4    10^-4
-// 1     1.995   0.995   -0.0022  0      2    10^-2
-// - Et recherche de la valeur del={del0,2*del0,...,20*del0}
-// telle que "nticks*del" soit le plus petit nombre ">=d"
-// Par exemple, si nticks=10:
-// 1-/ pour le 2sd cas ou d=9499 et del0=100 :
-// del        =    100    200    500    1000    2000
-// nticks*del =   1000   2000   5000   10000   20000
-// d/del      =   94.9   47.4   18.9 | 9.499   4.749  ==> majt = 1000
-// 2-/ pour le 3ieme cas ou d=5e-3 et del0=1e-4 :
-// del        =  1e-4   2e-4   5e-4  1e-3   2e-3
-// nticks*del =  1e-3   2e-3   5e-3  1e-2   2e-2
-// d/del      =  50     25   | 10    5      2.5       ==> majt = 5e-4
-int k=0;
-double fac[4] = {2.,5.,10.,20.};
-while(d/del>(double)nticks && k<4 ) {del=fac[k]*del0; k++;}
-steptick=del;
-//***  Valeur du premier tick
-xfirsttick = floor(xmin/steptick); if(xmin<0.) xfirsttick+=1.;
-xfirsttick *= steptick;
-if(xfirsttick<xmin) xfirsttick += steptick;
+ double d=xmax-xmin; if(d<1.e-100) d=1.e-100; //if (d<1.e-39) d=1.e-39;
+ double ld  = log10(d);
+ double fld = floor( ((ld<0.)? -ld: ld) );
+ double del,del0;
+ majticks.resize(0); minticks.resize(0);
+ if(ld>=0.) {fld-=1.; del0=del=pow(10.,fld);}
+   else     {fld+=2.; del0=del=pow(10.,-fld);}
+ // *** Intervalle entre les ticks
+ // xmin  xmax    d       ld       fld -->fld  del0
+ // 1     1500    1499    3.17     3      2    10^2
+ // 1     9500    9499    3.98     3      2    10^2
+ // 1     1.005   0.005   -2.3     2      4    10^-4
+ // 1     1.995   0.995   -0.0022  0      2    10^-2
+ // - Et recherche de la valeur del={del0,2*del0,...,20*del0}
+ // telle que "nticks*del" soit le plus petit nombre ">=d"
+ // Par exemple, si nticks=10:
+ // 1-/ pour le 2sd cas ou d=9499 et del0=100 :
+ // del        =    100    200    500    1000    2000
+ // nticks*del =   1000   2000   5000   10000   20000
+ // d/del      =   94.9   47.4   18.9 | 9.499   4.749  ==> majt = 1000
+ // 2-/ pour le 3ieme cas ou d=5e-3 et del0=1e-4 :
+ // del        =  1e-4   2e-4   5e-4  1e-3   2e-3
+ // nticks*del =  1e-3   2e-3   5e-3  1e-2   2e-2
+ // d/del      =  50     25   | 10    5      2.5       ==> majt = 5e-4
+ int k=0;
+ double fac[4] = {2.,5.,10.,20.};
+ while(d/del>(double)nticks && k<4 ) {del=fac[k]*del0; k++;}
+ double steptick=del;
+ //***  Valeur du premier tick
+ double xfirsttick = floor(xmin/steptick); if(xmin<0.) xfirsttick+=1.;
+ xfirsttick *= steptick;
+ if(xfirsttick<xmin) xfirsttick += steptick;
+ majticks.push_back(xfirsttick);
+ while(xfirsttick<=xmax)
+   {xfirsttick+= steptick; majticks.push_back(xfirsttick);}
+ //***  Gestion des ticks mineurs
+ double steptickmin = steptick/5.;
+ double xfirsttickmin = floor(xmin/steptickmin) * steptickmin;
+ if(xfirsttickmin<xmin) xfirsttickmin += steptickmin;
+ minticks.push_back(xfirsttickmin);
+ while(xfirsttickmin<=xmax)
+   {xfirsttickmin+= steptickmin; minticks.push_back(xfirsttickmin);}
 }
 
@@ -424,2 +440,69 @@
 }
 
+void PIAxes::Arrange_Label(char *label)
+// Enleve les blancs et les zeros inutiles a la fin d'un label
+{
+ size_t lenl=strlen(label);
+ if(lenl==0) return;
+
+ // --- On enleve les blancs et plus au debut du label
+ if(label[0]==' ' || label[0]=='+') {
+   char *str=new char[lenl+2];
+   strcpy(str,label);
+   unsigned i=0;
+   for(i=0;i<lenl;i++) if(str[i]!=' ' && str[i]!='+') break;
+   strcpy(label,&str[i]);
+   delete [] str;
+   lenl=strlen(label);
+   if(lenl==0) return;
+ }
+
+ // --- On enleve les blancs a la fin du label
+ if(label[lenl-1]==' ') {
+   for(unsigned int i=lenl-1;i>=0;i--) {
+     if(label[i]!=' ') break;
+     label[i]='\0';
+   }
+   lenl=strlen(label);
+ }
+
+ // --- On enleve les e... E... non-significatifs
+ // ex: a.be-zzz  a.be+zzz  a.bezzz avec zzz=0,00,000,...
+ // Attention on n'enleve pas si: a.be+10
+ // Attention on ne fait rien si: e+10
+ char* e=index(label,'e');
+ if(e==NULL) e=index(label,'E');
+ if(e) {
+   for(unsigned int i=lenl-1;i>=0;i--) {
+     if(isdigit(label[i]) && label[i]!='0') break;
+     if(label[i]=='e' || label[i]=='E')
+       {label[i]='\0'; lenl=strlen(label); break;}
+   }
+ }
+
+ // --- On enleve les zeros non-significatifs a la fin du label
+ // On enleve des zeros ou le point si: ab. ab.czzz avec zzz=0,00,000,...
+ // Attention on n'enleve pas de zeros si: abzzz
+ // Attention a ne pas enlever des zeros si on a ab.ccce+a0
+ // Attention on traite 0eaaa -> 0
+ if(index(label,'.')==NULL) return;  // Recherche d'un point
+ string stre;
+ if(e) {if(e==label) return; stre=e; *e='\0'; lenl=strlen(label);}
+ for(unsigned int i=lenl-1;i>=0;i--) {
+   if(label[i]=='0') label[i]='\0';
+   else if(label[i]=='.') {
+     if(i>0) label[i]='\0';
+     else {
+       // Attention: ".e+10" -> "1e+10" MAIS "." -> "0"
+       if(e) strcpy(label,"1"); else strcpy(label,"0");
+     }
+     break;
+   }
+   else break;  // Ni un point ni un zero
+ }
+ if(e) {
+   if(strlen(label)==1) if(label[0]=='0') return;
+   strcat(label,stre.c_str());
+ }
+
+}
Index: trunk/SophyaPI/PI/piaxes.h
===================================================================
--- trunk/SophyaPI/PI/piaxes.h	(revision 2085)
+++ trunk/SophyaPI/PI/piaxes.h	(revision 2088)
@@ -9,4 +9,5 @@
 #include "pigraphuc.h"
 #include "pigratt.h"
+#include <vector>
 
 enum {
@@ -41,19 +42,23 @@
   //  virtual void      DrawHorizontalAxe(double xmin, double xmax, double y, 
 
-//  --- Methodes static ----
-//  Calcul des Distances optimales des subdivisions 
+//  Calcul des Distances optimales des subdivisions (STATIC)
   static void BestTicks(double xmin,double xmax,int nticks
-                       ,double& steptick,double& xfirsttick);
-//  Calcul du format optimal pour les axes
+			,vector<double>& majticks,vector<double>& minticks);
+
+//  Calcul du format optimal pour les axes (STATIC)
   static int BonFormatAxes(double xmin,double xmax,double xstep
-                          ,string& format,int typf=0,int add_digit=0);
+			   ,string& format,int typf=0,int add_digit=0);
+
+//  Mise en forme optimale du format (STATIC)
+  static void Arrange_Label(char *label);
+
 protected:
   void Setup(PIGraphicUC* g, double xmin, double xmax, 
 	     double ymin, double ymax);
 
-  void DrawHTicks(PIGraphicUC* g, double y, double tickUp, double tickDown, double xBeg, double xStep);
-  void DrawVTicks(PIGraphicUC* g, double x, double tickLeft, double tickRight, double yBeg, double yStep);
-  void DrawHLabels(PIGraphicUC* g, double y, double xBeg, double xStep, unsigned long just=0);
-  void DrawVLabels(PIGraphicUC* g, double x, double yBeg, double yStep, unsigned long just=0);
+  void DrawHTicks(PIGraphicUC* g, double y, double tickUp, double tickDown, vector<double>& xticks);
+  void DrawVTicks(PIGraphicUC* g, double x, double tickLeft, double tickRight, vector<double>& yticks);
+  void DrawHLabels(PIGraphicUC* g, double y, vector<double>& xticks, unsigned long just=0);
+  void DrawVLabels(PIGraphicUC* g, double x, vector<double>& yticks, unsigned long just=0);
   void DrawGrid(PIGraphicUC* g);
 
@@ -63,11 +68,10 @@
   bool   axesAFSz;
   
-  double xFirstMajTick, xFirstMinTick;
-  double yFirstMajTick, yFirstMinTick;
-  double xMajTickStep, xMinTickStep;
-  double yMajTickStep, yMinTickStep;
+  vector<double> xMajTicks;
+  vector<double> xMinTicks;
+  vector<double> yMajTicks;
+  vector<double> yMinTicks;
   double xMajTickLen,  xMinTickLen;
   double yMajTickLen,  yMinTickLen;
-
 };
 
Index: trunk/SophyaPI/PI/pieldrw.cc
===================================================================
--- trunk/SophyaPI/PI/pieldrw.cc	(revision 2085)
+++ trunk/SophyaPI/PI/pieldrw.cc	(revision 2088)
@@ -85,17 +85,23 @@
   for( k=0; k<opt.size(); k++ ) {
     string opts = opt[k];
-    if ( (opts == "stdaxes") || (opts == "defaxes") || (opts == "boxaxes") ) 
+    if ( (opts == "stdaxes") || (opts == "defaxes") || (opts == "boxaxes") )
       SetAxesFlags(kBoxAxes | kExtTicks | kLabels);
-    else if (opts == "simpleaxes") 
+    else if (opts == "simpleaxes")
       SetAxesFlags(kAxesDflt);
-    else if (opts == "boxaxesgrid") 
+    else if (opts == "finesimpleaxes")
+      SetAxesFlags(kAxesDflt | kMinTicks);
+    else if (opts == "boxaxesgrid")
       SetAxesFlags(kBoxAxes | kExtTicks | kLabels | kGridOn);
     else if (opts == "fineaxes") 
       SetAxesFlags(kBoxAxes | kTicks | kLabels | kMinTicks | kMajTicks);
-    else if ((opts == "grid") || (opts == "fineaxesgrid")) 
+    else if ((opts == "grid") || (opts == "fineaxesgrid"))
       SetAxesFlags(kBoxAxes | kTicks | kLabels | kMinTicks | kMajTicks | kGridOn);
-    else if (opts == "autofontsize") 
+    else if (opts == "simpleaxesgrid")
+      SetAxesFlags(kAxesDflt | kGridOn);
+    else if (opts == "finesimpleaxesgrid")
+      SetAxesFlags(kAxesDflt | kMinTicks | kGridOn);
+    else if (opts == "autofontsize")
       SetAxesAutoFontSize(true);
-    else if (opts == "fixedfontsize") 
+    else if (opts == "fixedfontsize")
       SetAxesAutoFontSize(false);
     else if (opts == "title") ShowTitles(true);
