Index: /trunk/SophyaPI/PI/pidrawer.cc
===================================================================
--- /trunk/SophyaPI/PI/pidrawer.cc	(revision 2386)
+++ /trunk/SophyaPI/PI/pidrawer.cc	(revision 2387)
@@ -101,4 +101,6 @@
   if (mGrUC)  delete mGrUC;
   if (ckdeact) PIDrwTools::UpdateActiveDrawer();
+  // On supprime la fenetre PIDrwOptionStringWindow le cas echeant
+  PIDrwOptionStringWindow::RemoveDrwOptionStringWindow(this);
 }
 
Index: /trunk/SophyaPI/PI/pidrwtools.cc
===================================================================
--- /trunk/SophyaPI/PI/pidrwtools.cc	(revision 2386)
+++ /trunk/SophyaPI/PI/pidrwtools.cc	(revision 2387)
@@ -7,4 +7,6 @@
 #include "pidrwtools.h"
 #include <iostream>
+#include <list>
+#include <typeinfo>
 #include "piscdrawwdg.h"
 #include "pi3dwdg.h"
@@ -119,5 +121,5 @@
 
 int wszx = 5*spx+3.5*bsx; 
-int wszy = (2+6*0.85)*bsy+(7+6*0.85)*spy;
+int wszy = (3+6*0.85)*bsy+(8+6*0.85)*spy;
 SetSize(wszx, wszy);
 
@@ -331,25 +333,30 @@
 cpy += bsy+spy;
 cpx = 2*spx;
-int butszx = 0.7*bsx;
+int butszx = bsx;
+int busp = (wszx-4*spx-3*butszx)/2;
 mButcf[0] = new PIButton(this, "GetAtt", 2500, butszx, bsy, cpx, cpy);
-cpx += butszx+spx;
+cpx += butszx+busp;
 mButcf[1] = new PIButton(this, "SetAtt", 2600, butszx, bsy, cpx, cpy);
-cpx += butszx+spx;
+cpx += butszx+busp;
 mButcf[2] = new PIButton(this, "Select", 2700, butszx, bsy, cpx, cpy);
 mButcf[2]->ActivatePress(true);
-cpx += butszx+spx;
-butszx = wszx-cpx-2*spx;
+
+butszx = 1.2*bsx;
+cpx = (wszx-2*butszx-4*spx)/2;
+cpy += bsy+spy;
+mButcf[4] = new PIButton(this, "OptionString", 2900, butszx, bsy, cpx, cpy);
+cpx += butszx+4*spx;
 mButcf[3] = new PIButton(this, "ShowControl", 2800, butszx, bsy, cpx, cpy);
 
-butszx = 1.4*bsx;
+butszx = 1.6*bsx;
 cpx = (wszx-2*butszx-4*spx)/2;
 cpy += 2*spy+bsy;
-mButcf[4] = new PIButton(this, "Refresh", 3000, bsx*1.2, bsyo, cpx, cpy);
-cpx += butszx+2*spx;
-mButcf[5] = new PIButton(this, "Dismiss", 3777, butszx, bsyo, cpx, cpy);
-
+mButcf[5] = new PIButton(this, "Refresh", 3000, butszx, bsyo, cpx, cpy);
+cpx += butszx+4*spx;
+mButcf[6] = new PIButton(this, "Dismiss", 3777, butszx, bsyo, cpx, cpy);
+
+for(kb=0; kb<7; kb++) 
+  mButcf[kb]->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic);
 for(kb=0; kb<6; kb++) 
-  mButcf[kb]->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic);
-for(kb=0; kb<5; kb++) 
   mButcf[kb]->SetUnSensitive();
 
@@ -364,5 +371,5 @@
 if (cwdrwt == this)  cwdrwt = NULL;
 int i;
-for(i=0; i<6; i++) delete mButcf[i]; 
+for(i=0; i<7; i++) delete mButcf[i]; 
 for(i=0; i<2; i++) delete mButdr[i]; 
 for(i=0; i<10 ; i++)  delete mOpt[i];
@@ -461,7 +468,7 @@
     if (butsensnew < 2) {
       for(kb=0; kb<2;kb++)  mButdr[kb]->SetUnSensitive();
-      for(kb=0; kb<4;kb++)  mButcf[kb]->SetUnSensitive();
-      if (butsensnew == 0) mButcf[4]->SetUnSensitive();
-      else mButcf[4]->SetSensitive();
+      for(kb=0; kb<5;kb++)  mButcf[kb]->SetUnSensitive();
+      if (butsensnew == 0) mButcf[5]->SetUnSensitive();
+      else mButcf[5]->SetSensitive();
     }
     else { 
@@ -469,4 +476,5 @@
       for(kb=0; kb<3;kb++)  mButcf[kb]->SetSensitive();
       mButcf[4]->SetSensitive();
+      mButcf[5]->SetSensitive();
     }
   }
@@ -479,4 +487,5 @@
 
 PIDrawer* dr = NULL;
+
 
 mOpt[0]->SetValue(100);
@@ -493,4 +502,5 @@
 
 if (!dr)  return;
+
 int ii,jj,kk;
 PIGraphicAtt const & gratt = dr->GetGraphicAtt();
@@ -628,4 +638,8 @@
       break;
 
+    case 2900 :
+      if ((mCurBW != NULL) && (mCurBW->GetDrawer(mNDr) != NULL) ) 
+        PIDrwOptionStringWindow::ShowDrwOptionStringWindow(mCurBW->GetDrawer(mNDr));
+
     case 3000 :
       SetGraphicAtt(true);
@@ -654,3 +668,170 @@
 
 
-
+//---------------------------------------------------------------
+//---------------- Classe PIDrwOptionStringWindow ---------------
+//---------------------------------------------------------------
+
+//++
+// Class	PIDrwOptionStringWindow
+// Lib		PI
+// include	pidrwtools.h
+//
+//	Classe de fenêtre de dialogue permettant de modifier interactivement
+//	Les attributs graphique des "Drawer" par l'appel à *DecodeOptionString()*.
+//--
+// Links	Parents
+// PIWindow
+//--
+//++
+// Links	Voir aussi
+// PIDrawer
+// PIDrwTools
+//--
+
+//++
+// Titre	Méthodes statiques
+//--
+//++
+// void  ShowDrwOptionStringWindow(PIDrawer* drw)	
+//	Méthode statique permettant l'affichage de la fenêtre de changement des
+//	attributs graphiques à travers *PIDrawer::DecodeOptionString()*
+//	pour le drawer "drw".
+// void  RemoveDrwOptionStringWindow(
+//	Suppression de la fenêtre associé à "drw" (appelée par le destructeur
+//	des PIDrawer)
+//--
+
+static list<PIDrwOptionStringWindow* > drwoswlist;
+
+/* --Methode-- */
+void PIDrwOptionStringWindow::ShowDrwOptionStringWindow(PIDrawer* drw)
+{
+  if (drw == NULL) return;
+  list<PIDrwOptionStringWindow* >::iterator it;
+  for(it=drwoswlist.begin(); it!= drwoswlist.end(); it++) 
+    if ((*it)->GetDrawer() == drw) { 
+      (*it)->Show(); 
+      return; 
+    }
+  PIDrwOptionStringWindow* osw = 
+    new PIDrwOptionStringWindow(PIApplicationGetApp(), drw);
+  drwoswlist.push_back(osw);
+  osw->Show();
+}
+
+/* --Methode-- */
+void PIDrwOptionStringWindow::RemoveDrwOptionStringWindow(PIDrawer* drw)
+{
+  if (drw == NULL) return;
+  list<PIDrwOptionStringWindow* >::iterator it;
+  for(it=drwoswlist.begin(); it!= drwoswlist.end(); it++) 
+    if ((*it)->GetDrawer() == drw) { 
+      (*it)->Hide();
+      delete *it;
+      drwoswlist.erase(it); 
+      break;
+    }
+  return;
+}
+
+/* --Methode-- */
+PIDrwOptionStringWindow::PIDrwOptionStringWindow(PIApplication* par, PIDrawer* drw)
+  : PIWindow((PIMsgHandler *)par, "DrwOptionString", PIWK_normal, 400, 200, 100, 200) 
+  , mDrw(drw)
+{
+  int bsx, bsy;
+  int tsx, tsy;
+  int spx, spy;
+  PIApplicationPrefCompSize(bsx, bsy);
+  spx = bsx/8;   spy = bsy/6;
+  tsx = 6*bsx+2*spx;  tsy = 6*bsy+4*spy;
+  SetSize(tsx,tsy);
+  int cpx = spx;
+  int cpy = spy;
+  mTxt[0] = new PIText(this, "drwoshelp", true, true, bsx*6.0, 4*bsy, cpx, cpy);  
+  mTxt[0]->SetTextEditable(false);
+  mTxt[0]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
+  mTxt[0]->SetText("");
+  cpy += 4*bsy+spy;
+  mTxt[1] = new PIText(this, "drwosset", bsx*6.0, bsy, cpx, cpy);  
+  mTxt[1]->SetTextEditable(true);
+  mTxt[1]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
+  mTxt[1]->SetText("");
+  cpy += bsy+spy;
+  mLab = new PILabel(this, "drwntyp", bsx*2.2, bsy, cpx, cpy);
+  mLab->SetBorderWidth(1);
+  mLab->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
+  mLab->SetLabel("");
+  cpx += 2.6*bsx;
+  mBut[0] = new PIButton(this, "SetOption", 555, bsx*1.5, bsy, cpx, cpy);
+  mBut[0]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
+  cpx += 1.8*bsx;
+  mBut[1] = new PIButton(this, "Dimiss", 777, bsx*1.5, bsy, cpx, cpy);
+  mBut[1]->SetBinding(PIBK_elastic,PIBK_elastic, PIBK_elastic,PIBK_elastic);
+}
+
+/* --Methode-- */
+PIDrwOptionStringWindow::~PIDrwOptionStringWindow()
+{
+  delete mTxt[0];
+  delete mTxt[1];
+  delete mLab;
+  delete mBut[0];
+  delete mBut[1];
+}
+/* --Methode-- */
+void PIDrwOptionStringWindow::Show()
+{
+  if (mDrw) {
+    string hs;
+    mDrw->GetOptionsHelpInfo(hs);
+    mTxt[0]->SetText(hs);
+    mTxt[1]->SetText("");
+    hs = mDrw->Nom();
+    hs += " (T=";
+    hs += typeid(*mDrw).name();
+    hs += ")";
+    mLab->SetLabel(hs);
+  }
+  PIWindow::Show();
+}
+
+
+/* --Methode-- */
+void PIDrwOptionStringWindow::Process(PIMessage msg, PIMsgHandler* sender, void* data)
+{
+  PIMessage mod = ModMsg(msg);
+  msg = UserMsg(msg);
+
+  switch (msg) {
+  case 777:
+    Hide();
+    break;
+  case 555:
+    if (mDrw) {
+      vector<string> vops;
+      string ops = mTxt[1]->GetText();
+      //cout << " DBG-A " << ops << endl; 
+      size_t len = ops.length();
+      size_t cp = ops.find_first_not_of(' ', 0);
+      if ((cp < 0) || (cp >= len) ) break;
+      size_t tp = ops.find(' ', cp);
+      while ((tp > cp) && (tp < len)) {
+	vops.push_back(ops.substr(cp, tp-cp));
+	cp = tp+1; 
+	tp = ops.find(' ', cp);
+      }
+      if (cp < len) vops.push_back(ops.substr(cp));
+      //      cout << " DBG-B " << vops.size() << endl;
+      //for(int kk=0; kk< vops.size() ; kk++) 
+      //	cout << " DBG-C[" << kk << "] " << vops[kk] << endl; 
+      mDrw->DecodeOptionString(vops, false);
+      ops = "<< " + ops + " >> Decoded";
+      mTxt[1]->SetText(ops);
+      mDrw->Refresh();
+    }
+  default :
+    break;
+      
+  }
+}
Index: /trunk/SophyaPI/PI/pidrwtools.h
===================================================================
--- /trunk/SophyaPI/PI/pidrwtools.h	(revision 2386)
+++ /trunk/SophyaPI/PI/pidrwtools.h	(revision 2387)
@@ -13,8 +13,10 @@
 #include "pibwdggen.h"
 
-// --------- fenetre de dialogue pour modifs axes et options des Drawers ----------
+// ------ fenetres de dialogue pour modifs options/attributs des Drawers ----------
 // --------------------------------------------------------------------------------
 
+class PIDrawer;  // Declaration des objets drawer
 
+// fenetre de gestion interactive des attributs graphique
 class PIDrwTools : public PIWindow 
 {
@@ -45,5 +47,5 @@
   PILabel* mDrName;
   PIButton* mButdr[2];
-  PIButton* mButcf[6];
+  PIButton* mButcf[7];
   int mNDr;
 // mButSens  - Pour l'etat de sensibilite des boutons 
@@ -55,3 +57,26 @@
 };
 
+// Classe pour le changement interactive des attributs par appel 
+// a DecodeOptionString 
+
+class PIDrwOptionStringWindow : public PIWindow 
+{
+public:
+  static void ShowDrwOptionStringWindow(PIDrawer* drw);
+  static void RemoveDrwOptionStringWindow(PIDrawer* drw);
+
+  PIDrwOptionStringWindow(PIApplication* par, PIDrawer* drw);
+  ~PIDrwOptionStringWindow();
+  virtual void  Show();
+  inline PIDrawer* GetDrawer() { return mDrw; }
+
+protected:
+  virtual void  Process(PIMessage msg, PIMsgHandler* sender, void* data=NULL);
+private:
+  PIText* mTxt[2]; 
+  PILabel* mLab;
+  PIButton* mBut[2];
+  PIDrawer* mDrw;
+};
+
 #endif
Index: /trunk/SophyaPI/PI/pieldrw.cc
===================================================================
--- /trunk/SophyaPI/PI/pieldrw.cc	(revision 2386)
+++ /trunk/SophyaPI/PI/pieldrw.cc	(revision 2387)
@@ -595,4 +595,25 @@
   return(ndec+ndec1);
 }
+/* --Methode-- */
+void PIElDrawer::GetOptionsHelpInfo(string& info)
+{
+  info += " ---- PIElDrawer options help info : \n" ;
+  info += " >> Axe and grid configuration: \n";
+  info += "   axesnone  stdaxes defaxes \n";
+  info += "   boxaxes boxaxesgrid fineaxes fineaxesgrid \n";
+  info += "   centeredaxes finecenteredaxes centeredaxesgrid \n";
+  info += "   finecenteredaxesgrid  grid/nogrid \n";
+  info += " >> Axe ticks/labels: \n"; 
+  info += "   labels/nolabels  ticks/noticks minorticks/nominorticks \n";
+  info += "   extticks/intticks/extintticks nbticks=X_NbTicks,Y_NbTicks \n";
+  info += "   tickslen=MajorTickLenFrac,MinorTickLenFraC \n";
+  info += " >> Axe label font size: \n";
+  info += "    autofontsize=FontSizeFrac fixedfontsize \n";
+  info += " >> Up/Down title: title tit notitle notit \n";
+  info += "    ... Color/Font/line attributes : \n";
+// On recupere ensuite la chaine info de la classe de base
+  PIDrawer::GetOptionsHelpInfo(info);
+  return;  
+}
 
 /* --Methode-- */
Index: /trunk/SophyaPI/PI/pieldrw.h
===================================================================
--- /trunk/SophyaPI/PI/pieldrw.h	(revision 2386)
+++ /trunk/SophyaPI/PI/pieldrw.h	(revision 2387)
@@ -217,4 +217,6 @@
 //   Methode de decodage des options
   virtual int        DecodeOptionString(vector<string> & opt, bool rmdecopt=true);
+//   Texte d'aide des options disponibles
+  virtual void	     GetOptionsHelpInfo(string& info);
 
   virtual void       DrawAxes(PIGraphicUC* g); // Trace d'axes avec label axe X,Y
