Changeset 1971 in Sophya for trunk/SophyaPI/PIext/pistdimgapp.h
- Timestamp:
- Apr 30, 2002, 2:34:41 PM (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaPI/PIext/pistdimgapp.h
r1642 r1971 31 31 32 32 33 enum {Disp_Next=0, Disp_Win=1, Disp_Same=2, Disp_Stack=3, Disp_Inset=4};33 enum DispWinEnum {Disp_Default, Disp_Next, Disp_Win, Disp_Same, Disp_Stack, Disp_Inset}; 34 34 35 35 typedef map<long, PIWindow*, less<long> > WindMList; … … 47 47 virtual void SetBlocked(); 48 48 49 int DispImage(P2DArrayAdapter* nouv, string const & name, int opt, int oid=0); 50 int DispScDrawer(PIDrawer* scd, string const & name, int opt, string title="", int oid=0); 51 int Disp3DDrawer(PIDrawer3D* scd, string const & name, int opt, string title="", int oid=0); 49 int DispImage(P2DArrayAdapter* nouv, string const & name, string const & opt, int oid=0); 50 int DispScDrawer(PIDrawer* scd, string const & name, string const & opt, 51 string title="", int oid=0); 52 int Disp3DDrawer(PIDrawer3D* scd, string const & name, string const & opt, 53 string title="", int oid=0); 52 54 53 55 // Fonction d'ajout de texte (provisoire - Aout 99) 54 void AddText(string const & txt, double xp, double yp );56 void AddText(string const & txt, double xp, double yp, string const& opt); 55 57 // Ajout de lignes, rectangles, cercles (provisoires - Aout 2001) 56 void AddLine(double xp1, double yp1, double xp2, double yp2); 57 void AddRectangle(double xp1, double yp1, double xp2, double yp2, bool fgfill=false); 58 void AddCircle(double xc, double yc, double r, bool fgfill=false); 58 void AddLine(double xp1, double yp1, double xp2, double yp2, string const& opt); 59 void AddRectangle(double xp1, double yp1, double xp2, double yp2, string const& opt, 60 bool fgfill=false); 61 void AddCircle(double xc, double yc, double r, string const& opt, 62 bool fgfill=false); 59 63 60 64 // Fonction Ajout de titre de trace … … 66 70 void CreateGraphWin(int nx=1, int ny=1, int sx=0, int sy = 0); 67 71 void CreateStackWin(int sx=0, int sy = 0); 68 PIWindow * GetWindow( inttyp, int& sx, int& sy, int& px, int& py, int& flag, char * nom);72 PIWindow * GetWindow(DispWinEnum typ, int& sx, int& sy, int& px, int& py, int& flag, char * nom); 69 73 void SetZone(int nzx=1, int nzy=1); 70 74 void StackWinNext(); … … 93 97 inline PPInMgrWind* PPInMgrW() { return mPpinmgrw; } 94 98 99 // Gestion (show/hide) de la fenetre Stat/ZoomWindow 100 void StatZoomWindowSetVisible(bool fg=true); 101 95 102 // Redirection ou Non de StdOut/StdErr 96 103 void RedirectStdOutErr(bool fg = true); … … 99 106 void CatchSignals(bool fgfpe=true, bool fgsegv=true); 100 107 101 // Gestion d attributs graphiques courants102 void SetColAtt(PIColors fg=PI_NotDefColor,103 PIColors bg=PI_NotDefColor);104 void SetLineAtt(PILineAtt lat=PI_NotDefLineAtt);105 void SetFontName(PIFontName fn=PI_DefaultFont);106 void SetFontAtt(PIFontSize fsz=PI_NotDefFontSize,107 PIFontAtt fat=PI_NotDefFontAtt);108 void SetMarkerAtt(int sz=-1, PIMarker mrk=PI_NotDefMarker);109 inline void SetColMapId(CMapId cid=CMAP_OTHER) { mCmapid = cid; }110 inline void SetReverseColMapFlag(bool fg=false) { mRevCmap = fg; }111 void SetZoomAtt(int zoom=0);112 void SetAxesAtt(unsigned int axfl=kBoxAxes | kExtTicks | kLabels);113 void SetXYLimits(double xmin=-1., double xmax=1., double ymin=-1., double ymax=1.);114 108 void SetInsetLimits(double xmin=0.4, double xmax=0.6, double ymin=0.4, double ymax=0.6); 115 void SetImageCenterPosition(int x=-1, int y=-1);116 inline void UseXYLimits(bool fg=false) { mFXYlim=fg; }117 inline void UseImageCenter(bool fg=false) { mFImgCenter=fg; }118 inline void SetXLogScale(bool logx=false) { maXlog = logx; }119 inline void SetYLogScale(bool logy=false) { maYlog = logy; }120 109 inline void SetAutoAddTitle(bool aatit=true) { mAddTitle = aatit; } 121 122 // Pour sauvegarder-restauration de l'etat des attributs graphiques 123 void SaveGraphicAtt(); 124 void RestoreGraphicAtt(); 110 void SetAxesAtt(unsigned int axfl) { mAxesFlags = axfl; } 111 // void SaveGraphicAtt(); 112 // void RestoreGraphicAtt(); 113 void SetDefaultGraphicAttributes(string const & opt); 114 void SetDefaultAxesAttributes(string const & opt); 115 DispWinEnum ParseDisplayOption(string const & opt, vector<string>& opts); 125 116 126 117 // Gestion fichiers PS … … 141 132 void MBProcess6(PIMessage msg, PIMsgHandler* sender, void* data=NULL); 142 133 134 143 135 144 136 NamedObjMgr* mObjMgr; … … 148 140 PIMenu* mc; 149 141 142 PIContainer* statcont; // Container pour les widgets zoom, gimv, cmapv ... 150 143 PIPixmap* zoom; 151 144 PIPixmap* gimv; 152 145 PICMapView* cmapv; 146 PILabel* labstat; 153 147 154 148 PIFileChooser * pfc_fits; // Pour les fichiers FITS … … 156 150 PIFileChooser * pfc_ps; // Pour les PostScript 157 151 152 PIContainer* consolecont; // Container pour la PIConsole 158 153 PIConsole* mCons; 159 154 bool redirecout; // true if stdout/err redirected to mCons; … … 176 171 PPInMgrWind* mPpinmgrw; 177 172 178 // Gestion d attributs graphiques courants, etat sauvegarde 179 PIColors mFCol, mBCol, mSFCol, mSBCol; 180 PILineAtt mLAtt, mSLAtt; 181 PIFontName mFName, mSFName; 182 PIFontSize mFSz, mSFSz; 183 PIFontAtt mFAtt, mSFAtt; 184 int mMSz, mSMSz; 185 PIMarker mMrk,mSMrk; 186 CMapId mCmapid, mSCmapid; 187 bool mRevCmap, mSRevCmap; 188 int mZoom, mSZoom; 189 unsigned int mAxesFlags, mSAxesFlags; 190 double mXmin, mXmax, mYmin, mYmax; 191 double mSXmin, mSXmax, mSYmin, mSYmax; 173 // Attributs graphiques, etc ... 192 174 double mIXmin, mIXmax, mIYmin, mIYmax; 193 double mSIXmin, mSIXmax, mSIYmin, mSIYmax; 194 int mXImgCenter, mYImgCenter; 195 int mSXImgCenter, mSYImgCenter; 196 bool mFXYlim, mSFXYlim; 197 bool mFImgCenter, mSFImgCenter; 198 bool maXlog, mSaXlog; 199 bool maYlog, mSaYlog; 200 bool mAddTitle, mSAddTitle; 175 bool mAddTitle; 176 unsigned int mAxesFlags; 201 177 178 vector<string> mDefaultAtt; 179 vector<string> mAxesAtt; 180 181 // Controles et gestion divers 202 182 PIMessage mFCMsg; // Message for processing FileOpen 203 int mFgScSz; // Dlag ScreenSize183 int mFgScSz; // Flag ScreenSize 204 184 bool mFgCWImg; // true -> Current Widget is PIImage 205 185 };
Note:
See TracChangeset
for help on using the changeset viewer.