Changeset 1921 in Sophya for trunk/SophyaPI/PI/pidrwtools.cc
- Timestamp:
- Mar 6, 2002, 5:53:29 PM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaPI/PI/pidrwtools.cc
r1907 r1921 2 2 // Outils de manipulation des PIDrawer R. Ansari 06/98 3 3 // LAL (Orsay) / IN2P3-CNRS DAPNIA/SPP (Saclay) / CEA 4 4 // modifs pour 5 5 #include <stdlib.h> 6 6 … … 103 103 104 104 int wszx = 5*spx+3.5*bsx; 105 int wszy = (2+ 5*0.85)*bsy+(7+5*0.85)*spy;105 int wszy = (2+6*0.85)*bsy+(7+6*0.85)*spy; 106 106 SetSize(wszx, wszy); 107 107 … … 254 254 mOpt[7]->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic); 255 255 256 int kb;257 256 cpx = 2*spx; 258 257 cpy += spy+bsyo; 258 // OP 03/2002 259 260 mOpt[8] = new PIOptMenu(this, "bwt-opt-8", bsx*1.75, bsy, cpx, cpy); 261 mOpt[8]->AppendItem("Def.ArrowMrk", 900); 262 mOpt[8]->AppendItem("Basic-Arrow", 901); 263 mOpt[8]->AppendItem("Triangle-Arrow", 902); 264 mOpt[8]->AppendItem("FTriangle-Arrow", 903); 265 mOpt[8]->AppendItem("ShapedArrow", 904); 266 mOpt[8]->AppendItem("FShapedArrow", 905); 267 mOpt[8]->SetValue(900); 268 mOpt[8]->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic); 269 270 cpx += spx+1.75*bsx; 271 mOpt[9] = new PIOptMenu(this, "bwt-opt-9", bsx*1.75, bsy, cpx, cpy); 272 mOpt[9]->AppendItem("Arrow-1pt ", 951); 273 mOpt[9]->AppendItem("Arrow-3pt ", 952); 274 mOpt[9]->AppendItem("Arrow-5pt", 953); 275 mOpt[9]->AppendItem("Arrow-7pt", 954); 276 mOpt[9]->AppendItem("Arrow-9pt", 955); 277 mOpt[9]->AppendItem("Arrow-11pt", 956); 278 mOpt[9]->AppendItem("Arrow-13pt", 957); 279 mOpt[9]->AppendItem("Arrow-15pt", 958); 280 mOpt[9]->AppendItem("Arrow-17pt", 959); 281 mOpt[9]->SetValue(952 ); 282 mOpt[9]->SetBinding(PIBK_elastic, PIBK_elastic, PIBK_elastic, PIBK_elastic); 283 284 cpx = 2*spx; 285 cpy += spy+bsyo; 286 287 // end OP 288 int kb; 259 289 bsy = bsyo; spy = spyo; 260 290 mButdr[0] = new PIButton(this, "-", 1501, bsy, bsy, cpx, cpy); … … 315 345 for(i=0; i<6; i++) delete mButcf[i]; 316 346 for(i=0; i<2; i++) delete mButdr[i]; 317 for(i=0; i< 8; i++) delete mOpt[i];347 for(i=0; i<10 ; i++) delete mOpt[i]; 318 348 for(i=0; i<2; i++) delete mCasc[i]; 319 349 delete mNlb; … … 349 379 static PIFontSize fntsz[6] = { PI_NotDefFontSize, PI_TinySizeFont, PI_SmallSizeFont, 350 380 PI_NormalSizeFont, PI_LargeSizeFont, PI_HugeSizeFont }; 381 382 static PIArrowMarker arrmrk[6]= { PI_NotDefArrowMarker, PI_BasicArrowMarker, 383 PI_TriangleArrowMarker, PI_FTriangleArrowMarker, 384 PI_ArrowShapedArrowMarker, PI_FArrowShapedArrowMarker }; 385 351 386 352 387 /* --Methode-- */ … … 475 510 for(kk=0; kk<13; kk++) 476 511 if (lat == line[kk]) { mOpt[5]->SetValue(600+kk); break; } 512 513 PIArrowMarker arr = gratt.GetArrowMarker(); 514 for(kk==0 ; kk<6 ; kk++) 515 if(arr == arrmrk[kk]) {mOpt[8]->SetValue(900+kk);} 516 517 kk = gratt.GetArrowMarkerSize(); 518 if(kk<1) kk=1; 519 if(kk>17) kk=17; 520 kk = (kk+1)/2; 521 mOpt[9]->SetValue(950 + kk); 477 522 478 523 return; … … 511 556 if ( (k < 0) || (k > 12) ) k = 0; 512 557 gratt.SetLineAtt(PILineAtt(line[k])); 558 559 ii=mOpt[8]->GetValue()-900; 560 jj=mOpt[9]->GetValue()-950; 561 562 gratt.SetArrowMarkerAtt(2*jj-1,arrmrk[ii]); 563 513 564 drw->SetGraphicAtt(gratt); 565 514 566 if (fgref) mCurBW->Refresh(); 515 567 else drw->Refresh();
Note:
See TracChangeset
for help on using the changeset viewer.