Changeset 2349 in Sophya for trunk/SophyaPI/PI/piaxes.h


Ignore:
Timestamp:
Mar 18, 2003, 3:22:08 PM (23 years ago)
Author:
ansari
Message:

Correction-amelioration de trace des ticks d'axes - Possibilites
de specifier ticks interne ou externes, ainsi que taille des ticks
et taille de fonte pour autofontsize

Reza - 18 Mars 2003

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaPI/PI/piaxes.h

    r2164 r2349  
    1212
    1313enum {
    14   kStdAxes     = 0x0001,
     14  kCentAxes    = 0x0001,
    1515  kBoxAxes     = 0x0002,
    1616  kTicks       = 0x0004,
     
    2121  kLabels      = 0x1000,
    2222  kGridOn      = 0x2000,
    23   kAxesDflt    = kStdAxes | kTicks | kLabels,       // Axes trace par defaut
    24   kAxesNone    = 0                                  // Pas de trace d axe 
     23// Axes trace par defaut
     24  kAxesDflt    = kBoxAxes | kTicks | kMajTicks | kIntTicks | kLabels,       
     25  kStdAxes     = kAxesDflt,       
     26  kAxesNone    = 0         // Pas de trace d axe 
    2527};
    2628
     
    3335
    3436  virtual void      DrawXYAxes(PIGraphicUC* g, PIGraphicAtt& gratt,
    35                                unsigned int flags, bool afsz);
     37                               unsigned int flags=kAxesDflt, bool afsz=true);
    3638
    3739  virtual void      DrawXYAxes(PIGraphicUC* g, PIGraphicAtt& gratt,
    38                                unsigned int flags, bool afsz,
    3940                               double xmin, double xmax,
    40                                double ymin, double ymax);
     41                               double ymin, double ymax,
     42                               unsigned int flags=kAxesDflt, bool afsz=true);
    4143
    4244
     
    4547  virtual void      DrawYCaption(PIGraphicUC* g, PIGraphicAtt& att, unsigned int flags,
    4648                                 string const& YLabel);
     49
     50  //  Taille des ticks d'axes (en fraction de taille d'axe)
     51  void  ConfigureTicks(int ntickx=10, int nticky=12,
     52                       double majtl=0.0125, double mintl=0.007);
     53  void  ConfigureAutoFontSize(double fszf=0.04);
    4754
    4855  //  virtual void      DrawHorizontalAxe(double xmin, double xmax, double y,
     
    8087  bool   axesAFSz;
    8188 
     89  int xNTicks, yNTicks;             // Nb de ticks en X, Y
     90  double fMajTickLen, fMinTickLen;  // Taille des ticks, en fraction de Max-Min
     91  double fontSz;                    // Taille pour autofontsize, frac Max-Min
    8292  vector<double> xMajTicks;
    8393  vector<double> xMinTicks;
Note: See TracChangeset for help on using the changeset viewer.