1 | #include "machdefs.h"
|
---|
2 | #include <stdlib.h>
|
---|
3 | #include <stdio.h>
|
---|
4 | #include <string.h>
|
---|
5 |
|
---|
6 | #include <typeinfo>
|
---|
7 |
|
---|
8 | #include <string>
|
---|
9 | #include <vector>
|
---|
10 |
|
---|
11 | #include "strutil.h"
|
---|
12 | #include "timing.h"
|
---|
13 | #include "perrors.h"
|
---|
14 | #include "ctimer.h"
|
---|
15 |
|
---|
16 | #include "psighand.h"
|
---|
17 |
|
---|
18 | #include "cimage.h" // pour pouvoir faire extract
|
---|
19 |
|
---|
20 | #include "pistdimgapp.h"
|
---|
21 | #include "pihisto2d.h"
|
---|
22 | #include "psfile.h"
|
---|
23 | #include "piimgtools.h"
|
---|
24 | #include "pidrwtools.h"
|
---|
25 |
|
---|
26 | #include "pistzwin.h"
|
---|
27 |
|
---|
28 | #include "piinit.h"
|
---|
29 | #include "piversion.h"
|
---|
30 | #include "piaversion.h"
|
---|
31 |
|
---|
32 |
|
---|
33 | static char ImgDir[256];
|
---|
34 | static char WorkDir[256];
|
---|
35 |
|
---|
36 |
|
---|
37 | /* ........................................................... */
|
---|
38 | /* Classe PIStdImgApp */
|
---|
39 | /* ........................................................... */
|
---|
40 |
|
---|
41 | /* --Methode-- */
|
---|
42 | PIStdImgApp::PIStdImgApp(int narg, char* arg[])
|
---|
43 | : PIApplication(420, 320, narg, arg)
|
---|
44 | {
|
---|
45 |
|
---|
46 | // Les menus
|
---|
47 | m[0] = new PIMenu(Menubar(),"Fichier");
|
---|
48 | m[0]->AppendItem("Help", 10100);
|
---|
49 | m[0]->AppendItem("Open-Fits", 10120);
|
---|
50 | m[0]->AppendItem("Open-PPF", 10130);
|
---|
51 | m[0]->AppendItem("Close", 10110);
|
---|
52 | m[0]->AppendItem("delete", 10111);
|
---|
53 | // m[0]->AppendItem("Options", 10101);
|
---|
54 | m[0]->AppendItem("Exit", 10105);
|
---|
55 |
|
---|
56 | m[1] = new PIMenu(Menubar(),"Objets");
|
---|
57 | m[1]->AppendItem("ObjectManager", 10201);
|
---|
58 | m[1]->AppendItem("OpenOutPPF", 10220);
|
---|
59 | m[1]->AppendItem("CloseOutPPF", 10230);
|
---|
60 |
|
---|
61 | m[2] = new PIMenu(Menubar(),"Tools");
|
---|
62 | m[2]->AppendItem("Show ImageTools", 10301);
|
---|
63 | m[2]->AppendItem("Show DrawerTools", 10302);
|
---|
64 | m[2]->AppendItem("Ext.Pave", 10304);
|
---|
65 | m[2]->AppendItem("Ext.Pave+Org", 10305);
|
---|
66 | m[2]->SetSensitivityMsg(10305, false);
|
---|
67 | m[2]->AppendItem("Cuts X,Y", 10306);
|
---|
68 | m[2]->SetSensitivityMsg(10306, false);
|
---|
69 | mc = new PIMenu(m[2], "StackTools");
|
---|
70 | mc->AppendItem("DispNext", 10320);
|
---|
71 | mc->AppendItem("Blink 0.5s", 10321);
|
---|
72 | mc->AppendItem("Blink 1s", 10322);
|
---|
73 | mc->AppendItem("Blink 2s", 10324);
|
---|
74 | mc->AppendItem("Stop Blink", 10329);
|
---|
75 | mc->AppendItem("RemoveCurrent", 10330);
|
---|
76 | m[2]->AppendPDMenu(mc);
|
---|
77 | m[2]->SetSensitivity("StackTools", false);
|
---|
78 |
|
---|
79 | m[3] = new PIMenu(Menubar(),"Window");
|
---|
80 | m[3]->AppendItem("StackWindow", 10400);
|
---|
81 | m[3]->AppendItem("Window", 10411);
|
---|
82 | m[3]->AppendItem("Window 2x1", 10421);
|
---|
83 | m[3]->AppendItem("Window 1x2", 10412);
|
---|
84 | m[3]->AppendItem("Window 2x2", 10422);
|
---|
85 | m[3]->AppendItem("Window 3x1", 10431);
|
---|
86 | m[3]->AppendItem("Window 3x3", 10433);
|
---|
87 |
|
---|
88 | m[4] = new PIMenu(Menubar(),"PostScript");
|
---|
89 | m[4]->AppendItem("OpenPS", 10501);
|
---|
90 | m[4]->AppendItem("ClosePS", 10505);
|
---|
91 | m[4]->AppendItem("Window->PS", 10511);
|
---|
92 | m[4]->AppendItem("Image->PS", 10515);
|
---|
93 | m[4]->AppendItem("Window->EPS", 10512);
|
---|
94 | m[4]->AppendItem("Image->EPS", 10516);
|
---|
95 | m[4]->SetSensitivityMsg(10515, false);
|
---|
96 | m[4]->SetSensitivityMsg(10516, false);
|
---|
97 |
|
---|
98 | m[5] = new PIMenu(Menubar(),"Special");
|
---|
99 | m[5]->AppendItem("CloseAll", 10601);
|
---|
100 | m[5]->AppendCheckItem("Red.Out/Err", 10602);
|
---|
101 | m[5]->AppendCheckItem("Catch SigFPE", 10603);
|
---|
102 | m[5]->AppendCheckItem("Catch SigSEGV", 10604);
|
---|
103 | m[5]->AppendCheckItem("ObjMgr Verb", 10605);
|
---|
104 |
|
---|
105 | m[6] = new PIMenu(Menubar(),"Modules");
|
---|
106 |
|
---|
107 | AppendMenu(m[0]);
|
---|
108 | AppendMenu(m[1]);
|
---|
109 | AppendMenu(m[2]);
|
---|
110 | AppendMenu(m[3]);
|
---|
111 | AppendMenu(m[4]);
|
---|
112 | AppendMenu(m[5]);
|
---|
113 | // AppendMenu(m[6]); Menu Modules vide pour le moment
|
---|
114 |
|
---|
115 | int scsx, scsy;
|
---|
116 | ScreenSz(scsx, scsy);
|
---|
117 | if (scsy <= 600) mFgScSz = 0;
|
---|
118 | else if (scsy <= 800) mFgScSz = 1;
|
---|
119 | else if (scsy <= 1024) mFgScSz = 2;
|
---|
120 | else mFgScSz = 3;
|
---|
121 | int msx = 420+mFgScSz*60;
|
---|
122 | int msy = 320+mFgScSz*40;
|
---|
123 | MainWin()->SetSize(msx, msy);
|
---|
124 |
|
---|
125 | int bss = 100+mFgScSz*15;
|
---|
126 | gimv = new PIPixmap(MainWin(), "GloV", bss, bss, 5, 5);
|
---|
127 | gimv->SetBinding(PIBK_fixed,PIBK_fixed,PIBK_free, PIBK_free);
|
---|
128 | zoom = new PIPixmap(MainWin(), "Zoom", bss, bss, bss+10, 5);
|
---|
129 | zoom->SetBinding(PIBK_fixed,PIBK_fixed,PIBK_free, PIBK_free);
|
---|
130 | cmapv = new PICMapView(MainWin(), "CMapView", msx-10, 14+mFgScSz*2, 5, bss+10);
|
---|
131 | cmapv->SetBinding(PIBK_fixed,PIBK_fixed,PIBK_fixed, PIBK_free);
|
---|
132 |
|
---|
133 | int cpy = bss+10+14+mFgScSz*2+5;
|
---|
134 |
|
---|
135 | // Creation d'une console avec gestion des commandes
|
---|
136 | mCons = new PIConsole(MainWin(), "Console", 30200, 512, 132, msx, msy-cpy, 0, cpy );
|
---|
137 | mCons->SetBinding(PIBK_fixed,PIBK_fixed,PIBK_fixed, PIBK_fixed);
|
---|
138 | mCons->AcceptCmd(true, 50);
|
---|
139 | redirecout = false;
|
---|
140 | // RedirectStdOutErr(true); pas par defaut
|
---|
141 |
|
---|
142 | char buff[128];
|
---|
143 | mCons->AddStr(" ............ starting piapp .............\n", PIVA_Blue );
|
---|
144 | sprintf(buff, "Version: piapp=%g PI=%g PEIDA=%g \n", (double)PIAPP_VERSIONNUMBER,
|
---|
145 | (double)PI_VERSIONNUMBER, (float)PeidaVersion());
|
---|
146 | mCons->AddStr(buff, PIVA_Blue );
|
---|
147 | mCons->AddStr(" ..........................................\n", PIVA_Blue );
|
---|
148 | // PrintPeidaVersion();
|
---|
149 |
|
---|
150 |
|
---|
151 | mObjMgr = new NamedObjMgr;
|
---|
152 | mCmd = new PIACmd(mObjMgr, this);
|
---|
153 |
|
---|
154 | // Pas trop de message de la part de NamedObjMgr
|
---|
155 | m[5]->SetStateMsg(10605, false);
|
---|
156 | mObjMgr->SetVerbose(false);
|
---|
157 |
|
---|
158 | char* varenv;
|
---|
159 | ImgDir[0] = WorkDir[0] = '\0';
|
---|
160 | if ( (varenv=getenv("PEIDA_IMAGES")) != NULL ) strncpy(ImgDir, varenv, 256);
|
---|
161 | if ( (varenv=getenv("PEIDA_WORK")) != NULL ) strncpy(WorkDir, varenv, 256);
|
---|
162 |
|
---|
163 | pfc = new PIFileChooser(this,"FileChooser", 5000);
|
---|
164 |
|
---|
165 | mObjmgrw = new ObjMgrWind(this);
|
---|
166 | mPpinmgrw = new PPInMgrWind(this);
|
---|
167 |
|
---|
168 | // Attention : A faire apres creation de ObjMgrWind !!!
|
---|
169 | mObjMgr->SetImgApp(this);
|
---|
170 |
|
---|
171 | // Gestion des feneteres widgets et drawers
|
---|
172 | mWId = mDId = mBWId = 0;
|
---|
173 | mCurWin = NULL;
|
---|
174 | mCurWdg = NULL;
|
---|
175 | mLastWdg = NULL;
|
---|
176 | mGrW = NULL;
|
---|
177 | mStW = NULL;
|
---|
178 | mGrIdx = mStIdx = -1;
|
---|
179 |
|
---|
180 | mFCMsg = 0;
|
---|
181 | mFgCWImg = false;
|
---|
182 |
|
---|
183 | // Gestion fichiers PS
|
---|
184 | num_eps = 0;
|
---|
185 | name_ps = "";
|
---|
186 | name_ps = "pia.ps";
|
---|
187 | mpsfile = new PSFile(name_ps.c_str(),PI_Portrait, PI_A4, 2., 2.);
|
---|
188 |
|
---|
189 | // Gestion OUT-PPF
|
---|
190 | mPpfout = NULL;
|
---|
191 | name_outppf = "";
|
---|
192 |
|
---|
193 | // Attributs graphiques courants
|
---|
194 | mFCol = mBCol = PI_NotDefColor;
|
---|
195 | mLAtt = PI_NotDefLineAtt;
|
---|
196 | mFSz = PI_NotDefFontSize;
|
---|
197 | mFAtt = PI_NotDefFontAtt;
|
---|
198 | mMSz = -1;
|
---|
199 | mMrk = PI_NotDefMarker;
|
---|
200 | mCmapid = CMAP_OTHER;
|
---|
201 | mZoom = 0;
|
---|
202 | mAxesFlags = kBoxAxes | kExtTicks | kLabels;
|
---|
203 | SetXYLimits(-1, 1., -1., 1.);
|
---|
204 | SetInsetLimits(0.4, 0.6, 0.4, 0.6);
|
---|
205 | maXlog = maYlog = false;
|
---|
206 | SaveGraphicAtt();
|
---|
207 |
|
---|
208 | // Initialisation
|
---|
209 | PIAppInitiator * piai = new PIAppInitiator(this);
|
---|
210 | SetReady();
|
---|
211 | }
|
---|
212 |
|
---|
213 | /* --Methode-- */
|
---|
214 | PIStdImgApp::~PIStdImgApp()
|
---|
215 | {
|
---|
216 | int i;
|
---|
217 |
|
---|
218 | delete mc;
|
---|
219 | for(i=0; i<7; i++)
|
---|
220 | if (m[i]) delete m[i];
|
---|
221 |
|
---|
222 | WindMList::iterator it;
|
---|
223 | for(it = mWList.begin(); it != mWList.end(); it++) delete (*it).second;
|
---|
224 |
|
---|
225 | delete mObjMgr;
|
---|
226 | delete mCmd;
|
---|
227 |
|
---|
228 | delete zoom;
|
---|
229 | delete gimv;
|
---|
230 | delete cmapv;
|
---|
231 |
|
---|
232 | delete pfc;
|
---|
233 |
|
---|
234 | delete mCons;
|
---|
235 |
|
---|
236 | delete mObjmgrw;
|
---|
237 | delete mPpinmgrw;
|
---|
238 |
|
---|
239 | // Les fichiers
|
---|
240 | if (mpsfile) delete mpsfile;
|
---|
241 | if (mPpfout) delete mPpfout;
|
---|
242 |
|
---|
243 | }
|
---|
244 |
|
---|
245 | /* --Methode-- */
|
---|
246 | void PIStdImgApp::Process(PIMessage msg, PIMsgHandler* sender, void* data)
|
---|
247 | {
|
---|
248 | PIWdg *sndw;
|
---|
249 | PIMessage tmsg, smm;
|
---|
250 |
|
---|
251 | tmsg = msg;
|
---|
252 | msg = UserMsg(msg);
|
---|
253 | smm = ModMsg(tmsg);
|
---|
254 |
|
---|
255 | //printf("SuperDebug: msg=%d Mod=%d State=%d\n", (int)msg, (int)smm, (int)GetState());
|
---|
256 | if ((GetState()) && (msg != mFCMsg)) { PIBeep(); return; }
|
---|
257 |
|
---|
258 | // Messages active-window
|
---|
259 | if (smm == PIMsg_Active)
|
---|
260 | {
|
---|
261 | sndw = dynamic_cast<PIWdg *>(sender);
|
---|
262 | switch(sndw->kind())
|
---|
263 | {
|
---|
264 | case PIWindow::ClassId :
|
---|
265 | mCurWin = dynamic_cast<PIWindow *>(sndw);
|
---|
266 | break;
|
---|
267 |
|
---|
268 | case PIScDrawWdg::ClassId :
|
---|
269 | case PIDraw3DWdg::ClassId :
|
---|
270 | mCurWdg = dynamic_cast<PIBaseWdg *>(sender);
|
---|
271 | // cerr << "*DBG11* ImgTools -> NonSensitive " << sndw->kind() << endl;
|
---|
272 | if (mFgCWImg) {
|
---|
273 | // cerr << "*DBG* ImgTools -> NonSensitive " << endl;
|
---|
274 | m[2]->SetSensitivityMsg(10305, false);
|
---|
275 | m[2]->SetSensitivityMsg(10306, false);
|
---|
276 | m[4]->SetSensitivityMsg(10515, false);
|
---|
277 | m[4]->SetSensitivityMsg(10516, false);
|
---|
278 | mFgCWImg = false;
|
---|
279 | }
|
---|
280 | break;
|
---|
281 | case PIImage::ClassId :
|
---|
282 | mCurWdg = dynamic_cast<PIBaseWdg *>(sender);
|
---|
283 | if (!mFgCWImg) {
|
---|
284 | // cerr << "*DBG* ImgTools -> Sensitive " << endl;
|
---|
285 | m[2]->SetSensitivityMsg(10305, true);
|
---|
286 | m[2]->SetSensitivityMsg(10306, true);
|
---|
287 | m[4]->SetSensitivityMsg(10515, true);
|
---|
288 | m[4]->SetSensitivityMsg(10516, true);
|
---|
289 | mFgCWImg = true;
|
---|
290 | }
|
---|
291 | break;
|
---|
292 | /*
|
---|
293 | default :
|
---|
294 | mCurWdg = NULL;
|
---|
295 | if (mFgCWImg) {
|
---|
296 | m[2]->SetSensitivityMsg(10305, false);
|
---|
297 | m[2]->SetSensitivityMsg(10306, false);
|
---|
298 | m[4]->SetSensitivityMsg(10515, false);
|
---|
299 | m[4]->SetSensitivityMsg(10516, false);
|
---|
300 | mFgCWImg = false;
|
---|
301 | }
|
---|
302 | break;
|
---|
303 | */
|
---|
304 | }
|
---|
305 | }
|
---|
306 | // Message window-close
|
---|
307 | else if (smm == PIMsg_Close)
|
---|
308 | {
|
---|
309 | sndw = (PIWdg *)sender;
|
---|
310 | if(sndw->kind() == PIWindow::ClassId)
|
---|
311 | {
|
---|
312 | mCurWin = (PIWindow *)sender;
|
---|
313 | if (mCurWin == mStW) m[2]->SetSensitivity("StackTools", false);
|
---|
314 | DeleteWindow(mCurWin);
|
---|
315 | }
|
---|
316 | else
|
---|
317 | printf("PIStdImgApp/Bug ? CloseMsd received from NonWindow (%d %d %lx) \n",
|
---|
318 | (int)tmsg, (int)sndw->kind(), (long)sender);
|
---|
319 | }
|
---|
320 |
|
---|
321 | // Traitement des messages des menus
|
---|
322 | else if ( (msg >= 10100) && (msg < 10200) ) MBProcess1(msg, sender, data);
|
---|
323 | else if ( (msg >= 10200) && (msg < 10300) ) MBProcess2(msg, sender, data);
|
---|
324 | else if ( (msg >= 10300) && (msg < 10400) ) MBProcess3(msg, sender, data);
|
---|
325 | else if ( (msg >= 10400) && (msg < 10500) ) MBProcess4(msg, sender, data);
|
---|
326 | else if ( (msg >= 10500) && (msg < 10600) ) MBProcess5(msg, sender, data);
|
---|
327 | else if ( (msg >= 10600) && (msg < 10700) ) MBProcess6(msg, sender, data);
|
---|
328 | else if ( msg == 30200 ) { // Objet PIConsole
|
---|
329 | string s = mCons->GetCmdString();
|
---|
330 | string s2 = "\nExecuting " + s + "\n";
|
---|
331 | mCons->AddStr(s2.c_str(), PIVA_Blue, true);
|
---|
332 | SetBusy();
|
---|
333 | #ifdef SANS_EVOLPLANCK
|
---|
334 | TRY {
|
---|
335 | mCmd->Interpret(s);
|
---|
336 | } CATCH(merr) {
|
---|
337 | fflush(stdout);
|
---|
338 | cout << endl;
|
---|
339 | cerr << endl;
|
---|
340 | string es = PeidaExc(merr);
|
---|
341 | cerr << "PIStdImgApp::Process()/ Cmd->Do() Exception :" << es << " (" << merr << ")" << endl ;
|
---|
342 | }
|
---|
343 | #else
|
---|
344 | try {
|
---|
345 | mCmd->Interpret(s);
|
---|
346 | }
|
---|
347 | catch ( PException exc ) {
|
---|
348 | fflush(stdout);
|
---|
349 | cout << endl;
|
---|
350 | cerr << endl;
|
---|
351 | cerr << "PIStdImgApp::Process()/ Cmd->Interpret() Exception :" << exc.Msg() << endl;
|
---|
352 | }
|
---|
353 | #endif
|
---|
354 | SetReady();
|
---|
355 | }
|
---|
356 |
|
---|
357 | else printf("PIStdImgApp::Process() BUG?? Msg %d (%d-%d) \n",
|
---|
358 | (int)tmsg,(int)msg,(int)smm);
|
---|
359 |
|
---|
360 |
|
---|
361 | return;
|
---|
362 | }
|
---|
363 |
|
---|
364 | /* --Methode-- */
|
---|
365 | void PIStdImgApp::SetReady()
|
---|
366 | {
|
---|
367 | mCons->SetSensitive();
|
---|
368 | gimv->SetSensitive();
|
---|
369 | PIApplication::SetReady();
|
---|
370 | }
|
---|
371 |
|
---|
372 | /* --Methode-- */
|
---|
373 | void PIStdImgApp::SetBusy()
|
---|
374 | {
|
---|
375 | mCons->SetUnSensitive();
|
---|
376 | gimv->SetUnSensitive();
|
---|
377 | PIApplication::SetBusy();
|
---|
378 | }
|
---|
379 |
|
---|
380 | /* --Methode-- */
|
---|
381 | void PIStdImgApp::SetBlocked()
|
---|
382 | {
|
---|
383 | mCons->SetUnSensitive();
|
---|
384 | gimv->SetUnSensitive();
|
---|
385 | PIApplication::SetBlocked();
|
---|
386 | }
|
---|
387 |
|
---|
388 |
|
---|
389 | /* --Methode-- */
|
---|
390 | int PIStdImgApp::DispImage(P2DArrayAdapter* nouv, string const & name, int opt, int oid)
|
---|
391 | {
|
---|
392 | PIImage* pii;
|
---|
393 | PIWindow* win;
|
---|
394 | int sx, sy, px, py, flag;
|
---|
395 |
|
---|
396 | if (nouv == NULL)
|
---|
397 | {
|
---|
398 | printf("PIStdImgApp::DispImage_Error Cannot Display NULL image \n");
|
---|
399 | return(-1);
|
---|
400 | }
|
---|
401 |
|
---|
402 | if ( (nouv->XSize() <= 0) || (nouv->YSize() <= 0))
|
---|
403 | {
|
---|
404 | printf("PIStdImgApp::DispImage_Error Pb Size Sz=%d*%d \n",
|
---|
405 | nouv->XSize(), nouv->YSize());
|
---|
406 | return(-1);
|
---|
407 | }
|
---|
408 |
|
---|
409 | int zm = 1;
|
---|
410 | if (mZoom == 0) { // Facteur de zoom auto
|
---|
411 | zm = (nouv->XSize() > nouv->YSize()) ? nouv->XSize() : nouv->YSize();
|
---|
412 | zm = (zm >= 250) ? 250/zm : 1;
|
---|
413 | }
|
---|
414 | else zm = mZoom;
|
---|
415 |
|
---|
416 | if (zm == 0) zm = 1;
|
---|
417 | if (zm < -10) zm = -10;
|
---|
418 | if (zm > 10) zm = 10;
|
---|
419 |
|
---|
420 | if (zm > 0) { sx = nouv->XSize()*zm; sy = nouv->YSize()*zm; }
|
---|
421 | else {
|
---|
422 | sx = (int)((float)nouv->XSize()*(-1./float(zm)));
|
---|
423 | sy = (int)((float)nouv->YSize()*(-1./float(zm)));
|
---|
424 | }
|
---|
425 | if (sx > 400+mFgScSz*100) sx = 400+mFgScSz*100;
|
---|
426 | if (sy > 400+mFgScSz*100) sy = 400+mFgScSz*100;
|
---|
427 | px = py = 0;
|
---|
428 | win = GetWindow(opt, sx, sy, px, py, flag, (char *)name.c_str());
|
---|
429 | pii = new PIImage(win, (char *)name.c_str(), sx, sy, px,py);
|
---|
430 | pii->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic);
|
---|
431 | pii->SetZoomWin(zoom, false);
|
---|
432 | pii->SetGloVWin(gimv, false);
|
---|
433 | pii->SetCMapWin(cmapv, false);
|
---|
434 | pii->SetZoom(zm, false);
|
---|
435 | if ( mCmapid != CMAP_OTHER ) pii->SetColMapId(mCmapid, false);
|
---|
436 | pii->ShowCursor(true);
|
---|
437 | pii->SetUserData(NULL, oid);
|
---|
438 | pii->SetImage(nouv, true);
|
---|
439 | // printf("!!DBG!! PIImage Pos= %d %d Size= %d %d \n", pii->XPos(), pii->YPos(), pii->XSize(), pii->YSize() );
|
---|
440 | mCurWin = win;
|
---|
441 | mCurWdg = pii;
|
---|
442 | mLastWdg = pii;
|
---|
443 | mBWId++;
|
---|
444 | mBWList[mBWId] = pii;
|
---|
445 | return(mBWId);
|
---|
446 | }
|
---|
447 |
|
---|
448 |
|
---|
449 | /* --Methode-- */
|
---|
450 | int PIStdImgApp::DispScDrawer(PIDrawer* scd, string const & name, int opt, string title, int oid)
|
---|
451 | {
|
---|
452 | if (scd == NULL)
|
---|
453 | {
|
---|
454 | printf("PIStdImgApp::DispScDrawer_Error Cannot Add NULL ScDrawer \n");
|
---|
455 | return(-1);
|
---|
456 | }
|
---|
457 |
|
---|
458 | // Changement d'attributs graphiques courants du drawer
|
---|
459 | if (mFCol != PI_NotDefColor) scd->SetColAtt(mFCol, mBCol);
|
---|
460 | if (mLAtt != PI_NotDefLineAtt) scd->SetLineAtt(mLAtt);
|
---|
461 | if ( (mFSz != PI_NotDefFontSize) && (mFAtt != PI_NotDefFontAtt) ) scd->SetFontAtt(mFSz, mFAtt);
|
---|
462 | if ( (mMrk != PI_NotDefMarker) && (mMSz >= 0) ) scd->SetMarkerAtt(mMSz, mMrk);
|
---|
463 | if ( mCmapid != CMAP_OTHER ) scd->SetColMapId(mCmapid);
|
---|
464 |
|
---|
465 |
|
---|
466 | if ( (!mLastWdg) && ( (opt == Disp_Same) || (opt == Disp_Inset) ) ) opt = Disp_Next;
|
---|
467 | // Trace en superpoistion
|
---|
468 | if ( (opt == Disp_Same) && (mLastWdg) ) {
|
---|
469 | if (mLastWdg->kind() == PIScDrawWdg::ClassId) ((PIScDrawWdg*)mLastWdg)->AddScDrawer(scd, true);
|
---|
470 | else mLastWdg->AddDrawer(scd, true, true, true);
|
---|
471 | scd->Refresh();
|
---|
472 | mDId++;
|
---|
473 | mDrwList[mDId] = scd;
|
---|
474 | return(-mDId);
|
---|
475 | }
|
---|
476 | // Trace en medaillon
|
---|
477 | else if ( (opt == Disp_Inset) && (mLastWdg) ) {
|
---|
478 | PIGrCoord x1, x2, y1, y2;
|
---|
479 | x1 = mIXmin; x2 = mIXmax;
|
---|
480 | y2 = 1.-mIYmin; y1 = 1.-mIYmax;
|
---|
481 | scd->SetAxesFlags(mAxesFlags);
|
---|
482 | if (maXlog || maYlog) scd->SetLogScale(maXlog, maYlog); // Echelle log
|
---|
483 | if (mFXYlim) // Forcage limites XY
|
---|
484 | scd->SetLimits(mXmin, mXmax, mYmin, mYmax);
|
---|
485 | else scd->UpdateLimits();
|
---|
486 | mLastWdg->AddDrawer(scd, x1, y1, x2, y2, true, false, true);
|
---|
487 | scd->Refresh();
|
---|
488 | mDId++;
|
---|
489 | mDrwList[mDId] = scd;
|
---|
490 | return(-mDId);
|
---|
491 | }
|
---|
492 |
|
---|
493 | PIWindow* win;
|
---|
494 | PIScDrawWdg* scw;
|
---|
495 | int sx, sy, px, py, flag;
|
---|
496 | sx = 200+mFgScSz*100;
|
---|
497 | sy = 200+mFgScSz*100;
|
---|
498 | win = GetWindow(opt, sx, sy, px, py, flag, (char *)name.c_str());
|
---|
499 | if (typeid(*scd) != typeid(PIHisto2D))
|
---|
500 | scw = new PIScDrawWdg(win, (char *)name.c_str(), sx, sy, px, py);
|
---|
501 | else scw = new PIH2DWdg(win, (char *)name.c_str(), sx, sy, px, py);
|
---|
502 | scw->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic);
|
---|
503 | scw->SetUserData(NULL, oid);
|
---|
504 | if (maXlog || maYlog) scw->SetLogScale(maXlog, maYlog); // Echelle log
|
---|
505 | if (mFXYlim) // Forcage limites XY
|
---|
506 | scw->SetLimits(mXmin, mXmax, mYmin, mYmax);
|
---|
507 | scw->SetAxesFlags(mAxesFlags);
|
---|
508 |
|
---|
509 | if (typeid(*scd) != typeid(PIHisto2D)) scw->AddScDrawer(scd, true);
|
---|
510 | else ((PIH2DWdg*)scw)->SetPIHisto((PIHisto2D*)scd);
|
---|
511 | // Titre du plot
|
---|
512 | if (title.length() <= 0) title = name; string t2="";
|
---|
513 | scw->SetTitles(title, t2);
|
---|
514 | // scw->Refresh(); ? Pas necessaire Reza 19/08/98, 05/05/99 $CHECK$
|
---|
515 | mCurWin = win;
|
---|
516 | mCurWdg = scw;
|
---|
517 | mLastWdg = scw;
|
---|
518 | mBWId++;
|
---|
519 | mBWList[mBWId] = scw;
|
---|
520 | return(mBWId);
|
---|
521 | }
|
---|
522 |
|
---|
523 | /* --Methode-- */
|
---|
524 | int PIStdImgApp::Disp3DDrawer(PIDrawer3D* dr3, string const & name, int opt, string title, int oid)
|
---|
525 | {
|
---|
526 | if (dr3 == NULL)
|
---|
527 | {
|
---|
528 | printf("PIStdImgApp::Disp3DDrawer_Error Cannot Add NULL 3DDrawer \n");
|
---|
529 | return(-1);
|
---|
530 | }
|
---|
531 |
|
---|
532 | // Changement d'attributs graphiques courants du drawer
|
---|
533 | if (mFCol != PI_NotDefColor) dr3->SetColAtt(mFCol, mBCol);
|
---|
534 | if (mLAtt != PI_NotDefLineAtt) dr3->SetLineAtt(mLAtt);
|
---|
535 | if ( (mFSz != PI_NotDefFontSize) && (mFAtt != PI_NotDefFontAtt) ) dr3->SetFontAtt(mFSz, mFAtt);
|
---|
536 | if ( (mMrk != PI_NotDefMarker) && (mMSz >= 0) ) dr3->SetMarkerAtt(mMSz, mMrk);
|
---|
537 | if ( mCmapid != CMAP_OTHER ) dr3->SetColMapId(mCmapid);
|
---|
538 |
|
---|
539 | if ( (!mLastWdg) && ( (opt == Disp_Same) || (opt == Disp_Inset) ) ) opt = Disp_Next;
|
---|
540 | // Trace en superpoistion
|
---|
541 | if ( (opt == Disp_Same) && (mLastWdg) ) {
|
---|
542 | if (mLastWdg->kind() == PIDraw3DWdg::ClassId) ((PIDraw3DWdg*)mLastWdg)->AddDrawer3D(dr3, true);
|
---|
543 | else mLastWdg->AddDrawer(dr3, true, true, true);
|
---|
544 | dr3->Refresh();
|
---|
545 | mDId++;
|
---|
546 | mDrwList[mDId] = dr3;
|
---|
547 | return(-mDId);
|
---|
548 | }
|
---|
549 | // Trace en medaillon
|
---|
550 | else if ( (opt == Disp_Inset) && (mLastWdg) ) {
|
---|
551 | PIGrCoord x1, x2, y1, y2;
|
---|
552 | x1 = mIXmin; x2 = mIXmax;
|
---|
553 | y2 = 1.-mIYmin; y1 = 1.-mIYmax;
|
---|
554 | dr3->SetAxesFlags(mAxesFlags);
|
---|
555 | dr3->UpdateLimits();
|
---|
556 | mLastWdg->AddDrawer(dr3, x1, y1, x2, y2, true, false, true);
|
---|
557 | dr3->Refresh();
|
---|
558 | mDId++;
|
---|
559 | mDrwList[mDId] = dr3;
|
---|
560 | return(-mDId);
|
---|
561 | }
|
---|
562 |
|
---|
563 |
|
---|
564 | PIWindow* win;
|
---|
565 | int sx, sy, px, py, flag;
|
---|
566 | sx = 200+mFgScSz*100;
|
---|
567 | sy = 200+mFgScSz*100;
|
---|
568 | win = GetWindow(opt, sx, sy, px, py, flag, (char *)name.c_str());
|
---|
569 | PIDraw3DWdg* wd3 = new PIDraw3DWdg(win, (char *)name.c_str(), sx, sy, px, py);
|
---|
570 | wd3->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic);
|
---|
571 | wd3->SetUserData(NULL, oid);
|
---|
572 | wd3->AddDrawer3D(dr3, true);
|
---|
573 | // Titre du plot
|
---|
574 | if (title.length() <= 0) title = name; string t2="";
|
---|
575 | wd3->SetTitles(title, t2);
|
---|
576 | // wd3->Refresh(); ?Pas necessaire $CHECK$ 05/05/99
|
---|
577 | mCurWin = win;
|
---|
578 | mCurWdg = wd3;
|
---|
579 | mLastWdg = wd3;
|
---|
580 | mBWId++;
|
---|
581 | mBWList[mBWId] = wd3;
|
---|
582 | return(mBWId);
|
---|
583 | }
|
---|
584 |
|
---|
585 | /* --Methode-- */
|
---|
586 | void PIStdImgApp::AddText(string const & txt, double xp, double yp)
|
---|
587 | {
|
---|
588 | if (!mLastWdg) return;
|
---|
589 | PIElDrawer *eld=NULL;
|
---|
590 | PIScDrawWdg* sdw=NULL;
|
---|
591 | PIDraw3DWdg* w3d=NULL;
|
---|
592 | PIImage* imgw;
|
---|
593 | switch(mLastWdg->kind()) {
|
---|
594 | case PIScDrawWdg::ClassId :
|
---|
595 | sdw = dynamic_cast<PIScDrawWdg *>(mLastWdg);
|
---|
596 | if (sdw) eld = sdw->BaseDrawer();
|
---|
597 | break;
|
---|
598 | case PIDraw3DWdg::ClassId :
|
---|
599 | w3d = dynamic_cast<PIDraw3DWdg *>(mLastWdg);
|
---|
600 | if (w3d) eld = w3d->BaseDrawer();
|
---|
601 | break;
|
---|
602 | case PIImage::ClassId :
|
---|
603 | imgw = dynamic_cast<PIImage *>(mLastWdg);
|
---|
604 | if (imgw) eld = imgw->MyElDrawer();
|
---|
605 | break;
|
---|
606 | default :
|
---|
607 | break;
|
---|
608 | }
|
---|
609 | if (eld) {
|
---|
610 | if ( (mFSz != PI_NotDefFontSize) && (mFAtt != PI_NotDefFontAtt) ) eld->SetFontAtt(mFSz, mFAtt);
|
---|
611 | eld->ElAddText(xp,yp,txt.c_str(),mFCol);
|
---|
612 | eld->Refresh();
|
---|
613 | }
|
---|
614 | }
|
---|
615 |
|
---|
616 | /* --Methode-- */
|
---|
617 | void PIStdImgApp::CreateGraphWin(int nx, int ny, int sx, int sy)
|
---|
618 | {
|
---|
619 | if (nx < 1) nx = 1;
|
---|
620 | if (ny < 1) ny = 1;
|
---|
621 | if (nx > 8) nx = 8;
|
---|
622 | if (ny > 8) ny = 8;
|
---|
623 | if ( (sx < 50) && (sy < 50) ) sx = sy = 400+mFgScSz*100;
|
---|
624 | char buff[64];
|
---|
625 | mWId++;
|
---|
626 | int px, py;
|
---|
627 | MainWin()->GetScreenPos(px, py);
|
---|
628 | sprintf(buff, "PI-GraphicWin (%d)",mWId);
|
---|
629 | PIZoneWindow* win = new PIZoneWindow(this, buff, PIWK_normal, nx, ny, sx, sy, px+MainWin()->XSize()+30, 0);
|
---|
630 | win->SetUserData(NULL, ny*10+nx); // UserFlag= nY*10 + nX
|
---|
631 | mWList[mWId*10+1] = (PIWindow*)win;
|
---|
632 | win->SetAutoDelChilds(true);
|
---|
633 | // win->Show();
|
---|
634 | mGrW = win;
|
---|
635 | mGrIdx = 0;
|
---|
636 | }
|
---|
637 |
|
---|
638 | /* --Methode-- */
|
---|
639 | void PIStdImgApp::CreateStackWin(int sx, int sy)
|
---|
640 | {
|
---|
641 | if ( (sx < 50) && (sy < 50) ) sx = sy = 300+mFgScSz*100;
|
---|
642 | char buff[64];
|
---|
643 | mWId++;
|
---|
644 | int px, py;
|
---|
645 | MainWin()->GetScreenPos(px, py);
|
---|
646 | sprintf(buff, "PI-StackWin (%d)",mWId);
|
---|
647 | PIStackWindow* win = new PIStackWindow(this, buff, PIWK_normal, sx, sy, px+MainWin()->XSize()+30, 100);
|
---|
648 | win->SetUserData(NULL, 9999); // UserFlag= 9999
|
---|
649 | mWList[mWId*10+2] = (PIWindow*)win;
|
---|
650 | win->SetAutoDelChilds(true);
|
---|
651 | // win->Show();
|
---|
652 | mStW = win;
|
---|
653 | m[2]->SetSensitivity("StackTools", true);
|
---|
654 | mStIdx = 0;
|
---|
655 | }
|
---|
656 |
|
---|
657 | /* --Methode-- */
|
---|
658 | PIWindow* PIStdImgApp::GetWindow(int typ, int& sx, int& sy, int& px, int& py, int& flag, char * nom)
|
---|
659 | {
|
---|
660 | PIWindow* rw;
|
---|
661 |
|
---|
662 | switch (typ) {
|
---|
663 | case Disp_Next : // Fenetre graphique courante
|
---|
664 | {
|
---|
665 | if (mGrW == NULL) CreateGraphWin();
|
---|
666 | int nx, ny;
|
---|
667 | mGrW->NbZone(nx, ny);
|
---|
668 | PIWdg* nw = mGrW->NextChildPosSize(px, py, sx, sy);
|
---|
669 | // cerr << "**DBG** PIStdImgApp::GetWindow() DispNext : nw = " << (long)nw << endl;
|
---|
670 | if (nw) DeleteBaseWidget((PIBaseWdg*)nw, false, false);
|
---|
671 | flag = mGrIdx;
|
---|
672 | mGrIdx = (mGrIdx+1)%(nx*ny);
|
---|
673 | rw = mGrW;
|
---|
674 | break;
|
---|
675 | }
|
---|
676 |
|
---|
677 | case Disp_Stack : // Fenetre de type stack (empilement)
|
---|
678 | {
|
---|
679 | if (mStW == NULL) CreateStackWin(sx, sy);
|
---|
680 | px = py = 0;
|
---|
681 | sx = mStW->XSize();
|
---|
682 | sy = mStW->YSize();
|
---|
683 | flag = mStIdx;
|
---|
684 | mStIdx++;
|
---|
685 | rw = mStW;
|
---|
686 | }
|
---|
687 | break;
|
---|
688 |
|
---|
689 | default : // Fenetre ordinaire
|
---|
690 | {
|
---|
691 | int pwx, pwy;
|
---|
692 | MainWin()->GetScreenPos(pwx, pwy);
|
---|
693 | if ( (sx < 50) && (sy < 50) ) sx = sy = 300+mFgScSz*100;
|
---|
694 | rw = new PIWindow(this, nom, PIWK_normal, sx, sy, pwx+MainWin()->XSize()+30, 300);
|
---|
695 | rw->SetUserData(NULL, 0); // UserFlag= 0
|
---|
696 | mWId++;
|
---|
697 | mWList[mWId*10] = rw;
|
---|
698 | rw->SetAutoDelChilds(true);
|
---|
699 | // rw->Show();
|
---|
700 | px = py = 0;
|
---|
701 | flag = 0;
|
---|
702 | break;
|
---|
703 | }
|
---|
704 | }
|
---|
705 |
|
---|
706 | rw->Show();
|
---|
707 | mCurWin = rw;
|
---|
708 | return(rw);
|
---|
709 | }
|
---|
710 |
|
---|
711 | /* --Methode-- */
|
---|
712 | void PIStdImgApp::SetZone(int nzx, int nzy)
|
---|
713 | {
|
---|
714 | if (!mGrW) CreateGraphWin(nzx, nzy);
|
---|
715 | else {
|
---|
716 | int k;
|
---|
717 | PIWdg* cwd;
|
---|
718 | for(k=0; k<mGrW->NbChilds(); k++) {
|
---|
719 | if ((cwd = mGrW->GetChild(k)) == NULL) continue;
|
---|
720 | DeleteBaseWidget((PIBaseWdg*)cwd, false, false);
|
---|
721 | }
|
---|
722 | mGrW->SetZone(nzx, nzy);
|
---|
723 | }
|
---|
724 | }
|
---|
725 |
|
---|
726 | /* --Methode-- */
|
---|
727 | void PIStdImgApp::StackWinNext()
|
---|
728 | {
|
---|
729 | if (mStW) mStW->DispNext();
|
---|
730 | }
|
---|
731 |
|
---|
732 | /* --Methode-- */
|
---|
733 | void PIStdImgApp::DeleteWindow(PIWindow* w)
|
---|
734 | {
|
---|
735 | if (w == NULL) return;
|
---|
736 | w->Hide();
|
---|
737 | bool ownwindow=false; // To Check if this is one of our windows
|
---|
738 | WindMList::iterator it;
|
---|
739 | for(it = mWList.begin(); it != mWList.end(); it++)
|
---|
740 | if ((*it).second == w) { mWList.erase(it); ownwindow = true; break; }
|
---|
741 | if (w == mGrW) { mGrW = NULL; mGrIdx = -1; }
|
---|
742 | if (w == mStW) { mStW = NULL; mStIdx = -1; m[2]->SetSensitivity("StackTools", false); }
|
---|
743 | if (w == mCurWin) mCurWin = NULL;
|
---|
744 |
|
---|
745 | if (!ownwindow) return; // We do nothing if this is not a window we have created ...
|
---|
746 |
|
---|
747 | int k;
|
---|
748 | PIWdg* cwd;
|
---|
749 | for(k=0; k<w->NbChilds(); k++) {
|
---|
750 | if ((cwd = w->GetChild(k)) == NULL) continue;
|
---|
751 | DeleteBaseWidget((PIBaseWdg*)cwd,false,false);
|
---|
752 | }
|
---|
753 | delete w;
|
---|
754 | return;
|
---|
755 | }
|
---|
756 |
|
---|
757 | /* --Methode-- */
|
---|
758 | void PIStdImgApp::DeleteBaseWidget(PIBaseWdg* w, bool dw, bool dwin)
|
---|
759 | {
|
---|
760 | if (w == NULL) return;
|
---|
761 | BWMList::iterator it;
|
---|
762 | for(it = mBWList.begin(); it != mBWList.end(); it++)
|
---|
763 | if ((*it).second == w) { mBWList.erase(it); break; }
|
---|
764 | int k;
|
---|
765 | PIDrawer* drw;
|
---|
766 | for(k=0; k<w->NbDrawers(); k++) {
|
---|
767 | if ((drw = w->GetDrawer(k)) == NULL) continue;
|
---|
768 | DrwMList::iterator itt;
|
---|
769 | for(itt = mDrwList.begin(); itt != mDrwList.end(); itt++)
|
---|
770 | if ((*itt).second == drw) { mDrwList.erase(itt); break; }
|
---|
771 | }
|
---|
772 |
|
---|
773 | if (w == mCurWdg) {
|
---|
774 | mCurWdg = NULL;
|
---|
775 | if (mFgCWImg) {
|
---|
776 | m[4]->SetSensitivityMsg(10515, false);
|
---|
777 | m[4]->SetSensitivityMsg(10516, false);
|
---|
778 | mFgCWImg = false;
|
---|
779 | }
|
---|
780 | }
|
---|
781 |
|
---|
782 | if (w == mLastWdg) mLastWdg = NULL;
|
---|
783 |
|
---|
784 | PIWdg* pw=NULL;
|
---|
785 | if (dwin) pw = (PIWdg*)(w->Parent());
|
---|
786 | //DBG printf("DeleteBaseWidget(%lx)-DBG kind = %d - %d %d \n", (long)w, w->kind(), (int)dw, (int)dwin);
|
---|
787 | if (dw) delete w;
|
---|
788 | if (pw && (pw->kind() == PIWindow::ClassId )) {
|
---|
789 | PIWindow* pww = (PIWindow*) pw;
|
---|
790 | if ((pww != (PIWindow*)mGrW) && (pww != (PIWindow*)mStW) && (pww->NbChilds()==0))
|
---|
791 | DeleteWindow((PIWindow*)pw);
|
---|
792 | }
|
---|
793 | return;
|
---|
794 | }
|
---|
795 |
|
---|
796 |
|
---|
797 |
|
---|
798 | /* --Methode-- */
|
---|
799 | void PIStdImgApp::DelWRsId(int k)
|
---|
800 | {
|
---|
801 | //DBG cerr << "-DBG- PIStdImgApp::DelWRsId(" << k << ")" << endl;
|
---|
802 | if (k > 0) { // C'est un BaseWidget
|
---|
803 | BWMList::iterator it;
|
---|
804 | it = mBWList.find(k);
|
---|
805 | if (it == mBWList.end()) return;
|
---|
806 | PIBaseWdg* wd = (*it).second;
|
---|
807 | //DBG cerr << "-DBG- PIStdImgApp::DelWRsId Deleting BaseWidget " << (long)(wd) << endl ;
|
---|
808 | DeleteBaseWidget(wd, true, true);
|
---|
809 | }
|
---|
810 | else { // C'est un drawer
|
---|
811 | DrwMList::iterator it;
|
---|
812 | it = mDrwList.find(-k);
|
---|
813 | if (it == mDrwList.end()) return;
|
---|
814 | delete (*it).second;
|
---|
815 | mDrwList.erase(it);
|
---|
816 | // cerr << "+DBG+ PIStdImgApp::DelWRsId Deleting Drawer " << (long)((*it).second) << endl ;
|
---|
817 | }
|
---|
818 | }
|
---|
819 | /* --Methode-- */
|
---|
820 | bool PIStdImgApp::CheckWRsId(int k)
|
---|
821 | {
|
---|
822 | if (k > 0) { // C'est un BaseWidget
|
---|
823 | BWMList::iterator it;
|
---|
824 | it = mBWList.find(k);
|
---|
825 | if (it == mBWList.end()) return(false);
|
---|
826 | else return(true);
|
---|
827 | }
|
---|
828 | else { // C'est un drawer
|
---|
829 | DrwMList::iterator it;
|
---|
830 | it = mDrwList.find(-k);
|
---|
831 | if (it == mDrwList.end()) return(false);
|
---|
832 | else return(true);
|
---|
833 | }
|
---|
834 | }
|
---|
835 |
|
---|
836 |
|
---|
837 | /* --Methode-- */
|
---|
838 | void PIStdImgApp::RedirectStdOutErr(bool fg)
|
---|
839 | {
|
---|
840 | if (fg) {
|
---|
841 | RedirectOutStream(mCons);
|
---|
842 | RedirectErrStream(mCons);
|
---|
843 | m[5]->SetStateMsg(10602, true);
|
---|
844 | redirecout = true;
|
---|
845 | }
|
---|
846 | else {
|
---|
847 | RedirectOutStream(NULL);
|
---|
848 | RedirectErrStream(NULL);
|
---|
849 | m[5]->SetStateMsg(10602, false);
|
---|
850 | redirecout = false;
|
---|
851 | }
|
---|
852 | return;
|
---|
853 | }
|
---|
854 |
|
---|
855 | /* --Methode-- */
|
---|
856 | void PIStdImgApp::CatchSignals(bool fgfpe, bool fgsegv)
|
---|
857 | {
|
---|
858 | PeidaConfigureSignalhandling(fgfpe, fgsegv, true, true);
|
---|
859 | m[5]->SetStateMsg(10603, fgfpe);
|
---|
860 | m[5]->SetStateMsg(10604, fgsegv);
|
---|
861 | }
|
---|
862 |
|
---|
863 | /* --Methode-- */
|
---|
864 | void PIStdImgApp::CloseAllWindows()
|
---|
865 | {
|
---|
866 | WindMList::iterator it;
|
---|
867 | for(it = mWList.begin(); it != mWList.end(); it++) delete (*it).second;
|
---|
868 | mWList.clear();
|
---|
869 | mBWList.clear();
|
---|
870 | mDrwList.clear();
|
---|
871 | mGrW = NULL;
|
---|
872 | mStW = NULL;
|
---|
873 | mCurWin = NULL;
|
---|
874 | mCurWdg = NULL;
|
---|
875 | mLastWdg = NULL;
|
---|
876 | m[4]->SetSensitivityMsg(10515, false);
|
---|
877 | m[4]->SetSensitivityMsg(10516, false);
|
---|
878 | }
|
---|
879 |
|
---|
880 | /* --Methode-- */
|
---|
881 | void PIStdImgApp::MBProcess1(PIMessage msg, PIMsgHandler* /*sender*/, void* data)
|
---|
882 | {
|
---|
883 |
|
---|
884 | switch(msg)
|
---|
885 | {
|
---|
886 | case 10100 :
|
---|
887 | mCmd->ShowHelpWindow();
|
---|
888 | break;
|
---|
889 |
|
---|
890 | case 10120 :
|
---|
891 | pfc->SetPath(ImgDir);
|
---|
892 | pfc->AcceptNewFile(false);
|
---|
893 | mFCMsg = 10125;
|
---|
894 | pfc->SetMsg(mFCMsg);
|
---|
895 | SetBlocked();
|
---|
896 | pfc->Show();
|
---|
897 | break;
|
---|
898 |
|
---|
899 | case 10125 :
|
---|
900 | SetBusy();
|
---|
901 | if (data) {
|
---|
902 | string nomobj="";
|
---|
903 | ObjMgr()->ReadFits(pfc->GetFileName(), nomobj);
|
---|
904 | ObjMgr()->DisplayObj(nomobj, "win");
|
---|
905 | }
|
---|
906 | mFCMsg = 0;
|
---|
907 | SetReady();
|
---|
908 | break;
|
---|
909 |
|
---|
910 | case 10130 :
|
---|
911 | pfc->SetPath(WorkDir);
|
---|
912 | pfc->AcceptNewFile(false);
|
---|
913 | mFCMsg = 10135;
|
---|
914 | pfc->SetMsg(mFCMsg);
|
---|
915 | SetBlocked();
|
---|
916 | pfc->Show();
|
---|
917 | break;
|
---|
918 |
|
---|
919 | case 10135 :
|
---|
920 | mFCMsg = 0;
|
---|
921 | if (data) {
|
---|
922 | PPInMgrW()->SetFile(pfc->GetFileName());
|
---|
923 | PPInMgrW()->Show();
|
---|
924 | }
|
---|
925 | SetReady();
|
---|
926 | break;
|
---|
927 |
|
---|
928 | case 10110 :
|
---|
929 | DeleteWindow(mCurWin);
|
---|
930 | break;
|
---|
931 |
|
---|
932 | case 10111 :
|
---|
933 | if (mCurWdg) {
|
---|
934 | int oid = mCurWdg->UserFlag();
|
---|
935 | DeleteBaseWidget(mCurWdg);
|
---|
936 | mObjMgr->DelObj_Id(oid);
|
---|
937 | }
|
---|
938 | break;
|
---|
939 |
|
---|
940 | case 10105:
|
---|
941 | Stop();
|
---|
942 | break;
|
---|
943 |
|
---|
944 | }
|
---|
945 | return;
|
---|
946 | }
|
---|
947 |
|
---|
948 |
|
---|
949 |
|
---|
950 | /* --Methode-- */
|
---|
951 | void PIStdImgApp::MBProcess2(PIMessage msg, PIMsgHandler* /*sender*/, void* data)
|
---|
952 | {
|
---|
953 |
|
---|
954 | switch (msg) {
|
---|
955 | case 10201 :
|
---|
956 | ObjMgrW()->Show();
|
---|
957 | break;
|
---|
958 |
|
---|
959 | case 10220 :
|
---|
960 | pfc->SetPath(WorkDir);
|
---|
961 | pfc->AcceptNewFile(true);
|
---|
962 | mFCMsg = 10225;
|
---|
963 | pfc->SetMsg(mFCMsg);
|
---|
964 | SetBlocked();
|
---|
965 | pfc->Show();
|
---|
966 | break;
|
---|
967 |
|
---|
968 | case 10225 :
|
---|
969 | SetBusy();
|
---|
970 | if (data) {
|
---|
971 | if (mPpfout) {
|
---|
972 | printf("PIStdImg/Info: Closing POutPersist-File %s \n", name_outppf.c_str());
|
---|
973 | delete mPpfout;
|
---|
974 | }
|
---|
975 | name_outppf = pfc->GetFileName();
|
---|
976 | mPpfout = NULL;
|
---|
977 | printf("PIStdImg/Info: Opening POutPersist-File %s \n", name_outppf.c_str());
|
---|
978 | mPpfout = new POutPersist(name_outppf);
|
---|
979 | }
|
---|
980 | mFCMsg = 0;
|
---|
981 | SetReady();
|
---|
982 | break;
|
---|
983 |
|
---|
984 | case 10230 :
|
---|
985 | if (!mPpfout) break;
|
---|
986 | printf("PIStdImg/Info: Closing POutPersist-File %s \n", name_outppf.c_str());
|
---|
987 | delete mPpfout;
|
---|
988 | name_outppf = "";
|
---|
989 | mPpfout = NULL;
|
---|
990 | break;
|
---|
991 |
|
---|
992 |
|
---|
993 | default:
|
---|
994 | cerr << "PIStdImgApp::MBProcess2() BUG?? Msg= " << msg << endl;
|
---|
995 | break;
|
---|
996 | }
|
---|
997 |
|
---|
998 | return;
|
---|
999 | }
|
---|
1000 |
|
---|
1001 | /* --Methode-- */
|
---|
1002 | void PIStdImgApp::MBProcess3(PIMessage msg, PIMsgHandler* /*sender*/, void* /*data*/)
|
---|
1003 | {
|
---|
1004 |
|
---|
1005 | switch (msg) {
|
---|
1006 | case 10301 :
|
---|
1007 | PIImgTools::ShowPIImgTools();
|
---|
1008 | break;
|
---|
1009 | case 10302 :
|
---|
1010 | PIDrwTools::ShowPIDrwTools();
|
---|
1011 | break;
|
---|
1012 |
|
---|
1013 | case 10304 :
|
---|
1014 | case 10305 :
|
---|
1015 | {
|
---|
1016 | PIImage* curpimg = NULL;
|
---|
1017 | if (!mCurWdg) return;
|
---|
1018 | if (mCurWdg->kind() != PIImage::ClassId) return;
|
---|
1019 | curpimg = (PIImage*)mCurWdg;
|
---|
1020 | if (curpimg == NULL) return;
|
---|
1021 | P2DArrayAdapter* img = curpimg->Image();
|
---|
1022 | if (img == NULL) return;
|
---|
1023 | int dx = curpimg->XSzPave();
|
---|
1024 | int dy = curpimg->YSzPave();
|
---|
1025 | int x0 = curpimg->XPave()-dx/2;
|
---|
1026 | int y0 = curpimg->YPave()-dy/2;
|
---|
1027 | if (x0 < 0) x0 = 0;
|
---|
1028 | if (y0 < 0) y0 = 0;
|
---|
1029 | int x1 = x0+dx;
|
---|
1030 | int y1 = y0+dy;
|
---|
1031 | if (x1 > img->XSize()) x1 = img->XSize();
|
---|
1032 | if (y1 > img->YSize()) y1 = img->YSize();
|
---|
1033 | dx = x1-x0; dy = y1-y0;
|
---|
1034 | ImageR4* pim = new ImageR4(dx, dy);
|
---|
1035 | int ii, jj;
|
---|
1036 | for(jj=0; jj<dy; jj++)
|
---|
1037 | for(ii=0; ii<dx; ii++) (*pim)(ii,jj) = (*img)(ii+x0, jj+y0);
|
---|
1038 | if (msg == 10305) { // Calcul des coordonnees du sous-pave
|
---|
1039 | double xc1, yc1;
|
---|
1040 | img->Coord(x0, y0, xc1, yc1);
|
---|
1041 | pim->SetOrg((int)xc1, (int)yc1);
|
---|
1042 | }
|
---|
1043 | string nom = mCurWdg->Nom() + "_pave";
|
---|
1044 | ObjMgr()->AddObj(pim, nom);
|
---|
1045 | ObjMgr()->DisplayObj(nom, "w");
|
---|
1046 | break;
|
---|
1047 | }
|
---|
1048 |
|
---|
1049 | case 10306 :
|
---|
1050 | {
|
---|
1051 | PIImage* curpimg = NULL;
|
---|
1052 | if (!mCurWdg) return;
|
---|
1053 | if (mCurWdg->kind() != PIImage::ClassId) return;
|
---|
1054 | curpimg = (PIImage*)mCurWdg;
|
---|
1055 | if (curpimg == NULL) return;
|
---|
1056 | curpimg->ShowCuts(true);
|
---|
1057 | break;
|
---|
1058 | }
|
---|
1059 |
|
---|
1060 | case 10320 :
|
---|
1061 | if (mStW) mStW->DispNext();
|
---|
1062 | break;
|
---|
1063 |
|
---|
1064 | case 10321 :
|
---|
1065 | case 10322 :
|
---|
1066 | case 10324 :
|
---|
1067 | // case 10328 :
|
---|
1068 | if (mStW) mStW->StartAutoDisp((msg-10320)*500);
|
---|
1069 | break;
|
---|
1070 |
|
---|
1071 | case 10329 :
|
---|
1072 | if (mStW) mStW->StopAutoDisp();
|
---|
1073 | break;
|
---|
1074 |
|
---|
1075 | case 103330 :
|
---|
1076 | if (mStW) {
|
---|
1077 | PIWdg* cw = mStW->CurrentWdg();
|
---|
1078 | if (cw) DeleteBaseWidget((PIBaseWdg*)cw);
|
---|
1079 | }
|
---|
1080 | break;
|
---|
1081 |
|
---|
1082 | default:
|
---|
1083 | cerr << "PIStdImgApp::MBProcess3() BUG?? Msg= " << msg << endl;
|
---|
1084 | break;
|
---|
1085 | }
|
---|
1086 | return;
|
---|
1087 | }
|
---|
1088 |
|
---|
1089 | /* --Methode-- */
|
---|
1090 | void PIStdImgApp::MBProcess4(PIMessage msg, PIMsgHandler* /*sender*/, void* /*data*/)
|
---|
1091 | {
|
---|
1092 |
|
---|
1093 | switch (msg) {
|
---|
1094 |
|
---|
1095 | case 10400 :
|
---|
1096 | CreateStackWin();
|
---|
1097 | break;
|
---|
1098 |
|
---|
1099 | case 10411 :
|
---|
1100 | CreateGraphWin(1,1);
|
---|
1101 | break;
|
---|
1102 | case 10421 :
|
---|
1103 | CreateGraphWin(1,2);
|
---|
1104 | break;
|
---|
1105 | case 10412 :
|
---|
1106 | CreateGraphWin(2,1);
|
---|
1107 | break;
|
---|
1108 | case 10422 :
|
---|
1109 | CreateGraphWin(2,2);
|
---|
1110 | break;
|
---|
1111 | case 10431 :
|
---|
1112 | CreateGraphWin(1,3);
|
---|
1113 | break;
|
---|
1114 | case 10433 :
|
---|
1115 | CreateGraphWin(3,3);
|
---|
1116 | break;
|
---|
1117 |
|
---|
1118 | default:
|
---|
1119 | cerr << "PIStdImgApp::MBProcess4() BUG?? Msg= " << msg << endl;
|
---|
1120 | break;
|
---|
1121 | }
|
---|
1122 | return;
|
---|
1123 | }
|
---|
1124 |
|
---|
1125 |
|
---|
1126 | /* --Methode-- */
|
---|
1127 | void PIStdImgApp::MBProcess5(PIMessage msg, PIMsgHandler* /*sender*/, void* data)
|
---|
1128 | {
|
---|
1129 | char nomps[64],strg[512];
|
---|
1130 | PSFile *mps;
|
---|
1131 | int sxt, syt, syo, syo1, sx[4], sy[4];
|
---|
1132 |
|
---|
1133 | switch (msg)
|
---|
1134 | {
|
---|
1135 | case 10501 :
|
---|
1136 | pfc->SetPath(WorkDir);
|
---|
1137 | pfc->AcceptNewFile(true);
|
---|
1138 | mFCMsg = 10525;
|
---|
1139 | pfc->SetMsg(mFCMsg);
|
---|
1140 | SetBlocked();
|
---|
1141 | pfc->Show();
|
---|
1142 | break;
|
---|
1143 |
|
---|
1144 | case 10525 :
|
---|
1145 | SetBusy();
|
---|
1146 | if (data) {
|
---|
1147 | if (mpsfile) {
|
---|
1148 | printf("PIStdImg/Info: Closing PS-File %s \n", name_ps.c_str());
|
---|
1149 | delete mpsfile;
|
---|
1150 | }
|
---|
1151 | name_ps = pfc->GetFileName();
|
---|
1152 | printf("PIStdImg/Info: Opening PS-File %s \n", name_ps.c_str());
|
---|
1153 | mpsfile = new PSFile(name_ps.c_str(), PI_Portrait, PI_A4, 2., 2.);
|
---|
1154 | }
|
---|
1155 | mFCMsg = 0;
|
---|
1156 | SetReady();
|
---|
1157 | break;
|
---|
1158 |
|
---|
1159 | case 10505 :
|
---|
1160 | if (!mpsfile) break;
|
---|
1161 | printf("PIStdImg/Info: Closing PS-File %s \n", name_ps.c_str());
|
---|
1162 | delete mpsfile;
|
---|
1163 | mpsfile = NULL;
|
---|
1164 | name_ps = "";
|
---|
1165 | break;
|
---|
1166 |
|
---|
1167 | case 10511 : // Window -> PS
|
---|
1168 | case 10512 : // Window -> EPS
|
---|
1169 | if (CurrentWindow() == NULL) break;
|
---|
1170 | if (msg == 10512)
|
---|
1171 | {
|
---|
1172 | num_eps++;
|
---|
1173 | sprintf(nomps,"pia%d.eps", num_eps);
|
---|
1174 | printf("PIStdImg/Info: Creating EPSFile %s (CurWin-> EPS) \n", nomps);
|
---|
1175 | mps = new PSFile(nomps);
|
---|
1176 | }
|
---|
1177 | else {
|
---|
1178 | if (mpsfile == NULL) {
|
---|
1179 | name_ps = "pia.ps";
|
---|
1180 | mpsfile = new PSFile(name_ps.c_str(), PI_Portrait, PI_A4, 0., 0.);
|
---|
1181 | printf("PIStdImg/Info: File PS %s opened \n", name_ps.c_str());
|
---|
1182 | }
|
---|
1183 | printf("PIStdImg/Info: CurWin-> PSFile %s\n", name_ps.c_str());
|
---|
1184 | mps = mpsfile;
|
---|
1185 | }
|
---|
1186 | CurrentWindow()->PSPrint(mps,0,0);
|
---|
1187 |
|
---|
1188 | if (msg == 10512) delete mps; // fichier eps
|
---|
1189 | break;
|
---|
1190 |
|
---|
1191 | case 10515 : // Image -> PS
|
---|
1192 | case 10516 : // Image -> EPS
|
---|
1193 | {
|
---|
1194 | PIImage* curpimg = NULL;
|
---|
1195 | if (!mCurWdg) return;
|
---|
1196 | if (mCurWdg->kind() != PIImage::ClassId) return;
|
---|
1197 | curpimg = (PIImage*)mCurWdg;
|
---|
1198 | if (curpimg == NULL) return;
|
---|
1199 | if (msg == 10516)
|
---|
1200 | {
|
---|
1201 | num_eps++;
|
---|
1202 | sprintf(nomps,"pia%d.eps", num_eps);
|
---|
1203 | printf("PIStdImg/Info: Creating EPSFile %s (CurImage-> EPS)\n", nomps);
|
---|
1204 | mps = new PSFile(nomps);
|
---|
1205 | }
|
---|
1206 | else {
|
---|
1207 | if (mpsfile == NULL) {
|
---|
1208 | name_ps = "pia.ps";
|
---|
1209 | mpsfile = new PSFile(name_ps.c_str(),PI_Portrait, PI_A4, 2., 2.);
|
---|
1210 | printf("PIStdImg/Info: File PS %s opened \n", name_ps.c_str());
|
---|
1211 | }
|
---|
1212 | printf("PIStdImg/Info: CurImage-> PSFile %s\n", name_ps.c_str());
|
---|
1213 | mps = mpsfile;
|
---|
1214 | }
|
---|
1215 |
|
---|
1216 | sx[0] = gimv->XSize();
|
---|
1217 | sy[0] = gimv->YSize();
|
---|
1218 | sx[1] = zoom->XSize();
|
---|
1219 | sy[1] = zoom->YSize();
|
---|
1220 | sx[2] = cmapv->XSize();
|
---|
1221 | sy[2] = cmapv->YSize();
|
---|
1222 | sx[3] = curpimg->XSize();
|
---|
1223 | sy[3] = curpimg->YSize();
|
---|
1224 | if (sy[1] > sy[0]) { syo1 = sy[1]+50; syo = sy[1]+sy[2]+60; }
|
---|
1225 | else { syo1 = sy[0]+50; syo = sy[0]+sy[2]+60; }
|
---|
1226 | syt = sy[3]+syo;
|
---|
1227 | sxt = sx[3];
|
---|
1228 | if (sxt < (sx[0]+sx[1]+20)) sxt = sx[0]+sx[1]+20;
|
---|
1229 | if (sxt < sx[2]) sxt = sx[2];
|
---|
1230 |
|
---|
1231 | // Pour ecrire le titre
|
---|
1232 | mps->NewPage((float)sxt, (float)syt, PI_Portrait);
|
---|
1233 | mps->NewBloc(0,0, (float)sxt, 30., (float)sxt, 30.);
|
---|
1234 | sprintf(strg,"Image: %s - Pave %d %d \n", curpimg->Nom().c_str(),
|
---|
1235 | curpimg->XPave(), curpimg->YPave());
|
---|
1236 | mps->DrawString(10., 25., strg, PI_Black, PI_DefaultFont, PI_BoldFont, 20);
|
---|
1237 | mps->EndBloc();
|
---|
1238 |
|
---|
1239 | // Les quatre fenetres glovimage, zoom, cmap, image
|
---|
1240 | gimv->PSPrint(mps, -gimv->XPos(), -gimv->YPos()+40);
|
---|
1241 | zoom->PSPrint(mps, -zoom->XPos()+sx[0]+20, -zoom->YPos()+40);
|
---|
1242 | cmapv->PSPrint(mps, -cmapv->XPos(), -cmapv->YPos()+syo1);
|
---|
1243 | curpimg->PSPrint(mps, -curpimg->XPos(), -curpimg->YPos()+syo);
|
---|
1244 |
|
---|
1245 | if (msg == 10516) delete mps; // fichier eps
|
---|
1246 | break;
|
---|
1247 | }
|
---|
1248 |
|
---|
1249 | default:
|
---|
1250 | cerr << "PIStdImgApp::MBProcess5() BUG?? Msg= " << msg << endl;
|
---|
1251 | break;
|
---|
1252 | }
|
---|
1253 |
|
---|
1254 | }
|
---|
1255 |
|
---|
1256 |
|
---|
1257 | /* --Methode-- */
|
---|
1258 | void PIStdImgApp::MBProcess6(PIMessage msg, PIMsgHandler* /*sender*/, void* data)
|
---|
1259 | {
|
---|
1260 | switch (msg) {
|
---|
1261 | case 10601:
|
---|
1262 | CloseAllWindows();
|
---|
1263 | break;
|
---|
1264 | case 10602:
|
---|
1265 | RedirectStdOutErr(*((bool*)data));
|
---|
1266 | break;
|
---|
1267 | case 10603:
|
---|
1268 | case 10604:
|
---|
1269 | CatchSignals(m[5]->GetStateMsg(10603), m[5]->GetStateMsg(10604));
|
---|
1270 | break;
|
---|
1271 | case 10605:
|
---|
1272 | mObjMgr->SetVerbose(m[5]->GetStateMsg(10605));
|
---|
1273 | break;
|
---|
1274 | default:
|
---|
1275 | cerr << "PIStdImgApp::MBProcess6() BUG?? Msg= " << msg << endl;
|
---|
1276 | break;
|
---|
1277 | }
|
---|
1278 | return;
|
---|
1279 | }
|
---|
1280 |
|
---|
1281 |
|
---|
1282 | /* --Methode-- */
|
---|
1283 | void PIStdImgApp::SetColAtt(PIColors fg, PIColors bg)
|
---|
1284 | {
|
---|
1285 | mFCol = fg;
|
---|
1286 | mBCol = bg;
|
---|
1287 | }
|
---|
1288 | /* --Methode-- */
|
---|
1289 | void PIStdImgApp::SetLineAtt(PILineAtt lat)
|
---|
1290 | {
|
---|
1291 | mLAtt = lat;
|
---|
1292 | }
|
---|
1293 | /* --Methode-- */
|
---|
1294 | void PIStdImgApp::SetFontAtt(PIFontSize fsz, PIFontAtt fat)
|
---|
1295 | {
|
---|
1296 | mFSz = fsz;
|
---|
1297 | mFAtt = fat;
|
---|
1298 | }
|
---|
1299 | /* --Methode-- */
|
---|
1300 | void PIStdImgApp::SetMarkerAtt(int sz, PIMarker mrk)
|
---|
1301 | {
|
---|
1302 | mMSz = sz;
|
---|
1303 | mMrk = mrk;
|
---|
1304 | }
|
---|
1305 | /* --Methode-- */
|
---|
1306 | void PIStdImgApp::SetColMapId(CMapId cid)
|
---|
1307 | {
|
---|
1308 | mCmapid = cid;
|
---|
1309 | }
|
---|
1310 | /* --Methode-- */
|
---|
1311 | void PIStdImgApp::SetZoomAtt(int zoom)
|
---|
1312 | {
|
---|
1313 | if ( (zoom > 10) || (zoom < -10) ) zoom = 0;
|
---|
1314 | mZoom = zoom;
|
---|
1315 | }
|
---|
1316 | /* --Methode-- */
|
---|
1317 | void PIStdImgApp::SetAxesAtt(unsigned int axfl)
|
---|
1318 | {
|
---|
1319 | mAxesFlags = axfl;
|
---|
1320 | }
|
---|
1321 | /* --Methode-- */
|
---|
1322 | void PIStdImgApp::SetXYLimits(double xmin, double xmax, double ymin, double ymax)
|
---|
1323 | {
|
---|
1324 | mXmin = xmin; mXmax= xmax;
|
---|
1325 | mYmin = ymin; mYmax= ymax;
|
---|
1326 | }
|
---|
1327 |
|
---|
1328 | /* --Methode-- */
|
---|
1329 | void PIStdImgApp::SetInsetLimits(double xmin, double xmax, double ymin, double ymax)
|
---|
1330 | {
|
---|
1331 | mIXmin = xmin; mIXmax= xmax;
|
---|
1332 | mIYmin = ymin; mIYmax= ymax;
|
---|
1333 | }
|
---|
1334 |
|
---|
1335 | /* --Methode-- */
|
---|
1336 | void PIStdImgApp::SaveGraphicAtt()
|
---|
1337 | {
|
---|
1338 | mSFCol = mFCol;
|
---|
1339 | mSBCol = mBCol;
|
---|
1340 | mSLAtt = mLAtt;
|
---|
1341 | mSFSz = mFSz;
|
---|
1342 | mSFAtt = mFAtt;
|
---|
1343 | mSMSz = mMSz;
|
---|
1344 | mSMrk = mMrk;
|
---|
1345 | mSCmapid = mCmapid;
|
---|
1346 | mSZoom = mZoom;
|
---|
1347 | mSAxesFlags = mAxesFlags;
|
---|
1348 | mSXmin = mXmin; mSXmax = mXmax;
|
---|
1349 | mSYmin = mYmin; mSYmax = mYmax;
|
---|
1350 | mSIXmin = mIXmin; mSIXmax = mIXmax;
|
---|
1351 | mSIYmin = mIYmin; mSIYmax = mIYmax;
|
---|
1352 | mSFXYlim = mFXYlim;
|
---|
1353 | mSaXlog = maXlog;
|
---|
1354 | mSaYlog = maYlog;
|
---|
1355 | }
|
---|
1356 |
|
---|
1357 | /* --Methode-- */
|
---|
1358 | void PIStdImgApp::RestoreGraphicAtt()
|
---|
1359 | {
|
---|
1360 | mFCol = mSFCol;
|
---|
1361 | mBCol = mSBCol;
|
---|
1362 | mLAtt = mSLAtt;
|
---|
1363 | mFSz = mSFSz;
|
---|
1364 | mFAtt = mSFAtt;
|
---|
1365 | mMSz = mSMSz;
|
---|
1366 | mMrk = mSMrk;
|
---|
1367 | mCmapid = mSCmapid;
|
---|
1368 | mZoom = mSZoom;
|
---|
1369 | mAxesFlags = mSAxesFlags;
|
---|
1370 | mXmin = mSXmin; mXmax = mSXmax;
|
---|
1371 | mYmin = mSYmin; mYmax = mSYmax;
|
---|
1372 | mIXmin = mSIXmin; mIXmax = mSIXmax;
|
---|
1373 | mIYmin = mSIYmin; mIYmax = mSIYmax;
|
---|
1374 | mFXYlim = mSFXYlim;
|
---|
1375 | maXlog = mSaXlog;
|
---|
1376 | maYlog = mSaYlog;
|
---|
1377 | }
|
---|