Changeset 2545 in Sophya for trunk/SophyaPI/PIext


Ignore:
Timestamp:
Jun 1, 2004, 5:50:42 PM (21 years ago)
Author:
ansari
Message:

1/ Ajout commande textdrawer ds basexecut.cc
2/ Adaptation aux modifs pour autosacleX/Y,Z pour Drawer3D

Reza, 1 Juin 2004

Location:
trunk/SophyaPI/PIext
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaPI/PIext/basexecut.cc

    r2536 r2545  
    1717#include "piyfxdrw.h"
    1818#include "pibargraph.h"
     19#include "pitxtdrw.h"
    1920
    2021#include "histos.h"
     
    751752  string grname = "BarGraph";
    752753  mImgApp->DispScDrawer(bgd, grname, tokens[0]);
     754}
     755else if (kw == "textdrawer") {
     756  if (tokens.size() < 2) {
     757    cout << "Usage: textdrawer gr_opt line1 [line2 ...]" << endl;
     758    return(0);
     759  }
     760  PITextDrawer* txd = new PITextDrawer;
     761  for(int k=1; k<tokens.size(); k++)
     762    txd->AddLine(tokens[k]);
     763  string grname = "TextDrawer";
     764  tokens[0] += " inset";
     765  mImgApp->DispScDrawer(txd, grname, tokens[0]);
    753766}
    754767
     
    16171630mpiac->RegisterCommand(kw, usage, this, "Obj. Display");
    16181631kw = "bargraph";
    1619 usage = "Bar-Graph view of a sequence of values ";
     1632usage = "Bar-Graph view of a sequence of values (test)";
    16201633usage += "\n Usage : bargraph graphic_attributes v1 [v2 v3 ...] ";
    16211634usage += "\n  Related commands: disp nt2d vecplot"; 
     1635mpiac->RegisterCommand(kw, usage, this, "Obj. Display");
     1636kw = "textdrawer";
     1637usage = "Multi line text darwer (test)";
     1638usage += "\n Usage : textdrawer graphic_attributes line1 [line2 line3 ...] ";
     1639usage += "\n  Related commands: disp "; 
    16221640mpiac->RegisterCommand(kw, usage, this, "Obj. Display");
    16231641
     
    19071925usage += "o <Alt>O : Shows the PIImageTools (image display parameter controls) \n";
    19081926usage += "o <Alt>G : Show the PIDrawerTools (Graphic attributes of overlayed graphics (Drawers)) \n";
     1927usage += "o <Alt>D : Shows the drawer manipulation pop-up menu \n";
    19091928usage += "o <Alt>V : Copy/Paste / Text paste at the current cursor position \n";
    19101929usage += "o <Alt>C : Copy/Paste / Copies the selected regions content as text in the copy/paste buffer \n";
     
    19261945usage += "o <Alt>R : Refresh display \n";
    19271946usage += "o <Alt>O : Displays a specific control window (default: PIDrawerTools) \n";
    1928 usage += "           Specific controls for 2-D histograms \n";
     1947usage += "           (2-D histograms, contour plot ...) \n";
    19291948usage += "o <Alt>G : Show the PIDrawerTools (Graphic attributes of displayed Drawers) \n";
    19301949usage += "           Drawer 0 manages the axes, as well as the added text \n";
     1950usage += "o <Alt>D : Shows the drawer manipulation pop-up menu \n";
    19311951usage += "o <Alt>V : Copy/Paste / Text paste at the current position \n";
    19321952usage += "o <Alt>Z : Removes added graphic elements (handled by BaseDrawer - 0) \n";
     
    19481968usage += ">>>> Keyboard controls : \n";
    19491969usage += "o <Alt>R : Resets the 3-D view and refreshes the display \n";
     1970usage += "o <Alt>O : Displays a specific control window (default: PIDrawerTools) \n";
     1971usage += "           (2-D histograms, contour plot ...) \n";
    19501972usage += "o <Alt>G : Show the PIDrawerTools (Graphic attributes of displayed Drawers) \n";
    1951 usage += "o <Alt>O : = <Alt>G \n";
     1973usage += "           Drawer 0 manages the axes, as well as the added text \n";
     1974usage += "o <Alt>D : Shows the drawer manipulation pop-up menu \n";
    19521975usage += "o <Alt>V : Copy/Paste / Text paste at the current position (Drawer 0)\n";
    19531976usage += "o <Alt>Z : Removes added graphic elements (handled by BaseDrawer - 0) \n";
  • trunk/SophyaPI/PIext/pintup3d.cc

    r2524 r2545  
    4848  mNT = nt;
    4949  mAdDO = ad;
    50   mAutoScaleXY = mAutoScaleZ = true;
     50  aScxy = aScz = true;
    5151  UseSizeScale(true, 5);
    5252  UseColorScale(true);
     
    142142
    143143  ComputeScaleFactor(xmin, xmax, ymin, ymax, zmin, zmax,
    144                      mAutoScaleXY, mAutoScaleZ, mScy, mScz);
     144                     aScxy, aScz, mScy, mScz);
    145145 
    146146  // cout << " DEBUG - NTup3D X:" << XMin3() << "-" << XMax3() " s=" << mScx
     
    313313      UseSizeScale(true, nbn);
    314314    }
    315     else if (opts == "rescalexy") mAutoScaleXY = true;
    316     else if (opts == "norescalexy") mAutoScaleXY = false;
    317     else if (opts == "rescalez") mAutoScaleZ = true;
    318     else if (opts == "norescalez") mAutoScaleZ = false;
     315    else if (opts == "rescalexy") aScxy = true;
     316    else if (opts == "norescalexy") aScxy = false;
     317    else if (opts == "rescalez") aScz = true;
     318    else if (opts == "norescalez") aScz = false;
    319319    else {
    320320      // Si option non decode
     
    346346 } else opt.push_back("nosizescale");
    347347
    348  if(mAutoScaleXY) opt.push_back("rescalexy");
     348 if(aScxy) opt.push_back("rescalexy");
    349349   else opt.push_back("norescalexy");
    350350
    351  if(mAutoScaleZ) opt.push_back("rescalez");
     351 if(aScz) opt.push_back("rescalez");
    352352   else opt.push_back("norescalez");
    353353
  • trunk/SophyaPI/PIext/pintup3d.h

    r2524 r2545  
    3838  NTupleInterface* mNT;
    3939  bool mAdDO;
    40   bool mAutoScaleXY, mAutoScaleZ;
    4140  int xK, yK, zK;           // Index du nom de variable en X/Y/Z ds le ntuple
    4241  int xebK, yebK, zebK;     // Index du nom de variable en ErrBarX/Y/Z ds le ntuple
Note: See TracChangeset for help on using the changeset viewer.