Changeset 8698 for trunk/MagicSoft/Mars/mhbase/MH3.cc
- Timestamp:
- 08/23/07 11:26:38 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mhbase/MH3.cc
r8695 r8698 88 88 // Class Version 3: 89 89 // ---------------- 90 // - Byte_t fStyleBits 90 // - Byte_t fStyleBits 91 // + MBinning fBins[3] 91 92 // 92 93 ///////////////////////////////////////////////////////////////////////////// … … 145 146 fData[2] = NULL; 146 147 148 fBins[0] = NULL; 149 fBins[1] = NULL; 150 fBins[2] = NULL; 151 147 152 fName = gsDefName; 148 153 fTitle = gsDefTitle; … … 172 177 fData[1] = NULL; 173 178 fData[2] = NULL; 179 180 fBins[0] = NULL; 181 fBins[1] = NULL; 182 fBins[2] = NULL; 174 183 175 184 fName = gsDefName; … … 197 206 fData[2] = NULL; 198 207 208 fBins[0] = NULL; 209 fBins[1] = NULL; 210 fBins[2] = NULL; 211 199 212 switch (fDimension) 200 213 { … … 233 246 fData[2] = NULL; 234 247 248 fBins[0] = NULL; 249 fBins[1] = NULL; 250 fBins[2] = NULL; 251 235 252 fName = gsDefName; 236 253 fTitle = gsDefTitle; … … 260 277 fData[2] = new MDataPhrase(memberz); 261 278 279 fBins[0] = NULL; 280 fBins[1] = NULL; 281 fBins[2] = NULL; 282 262 283 fName = gsDefName; 263 284 fTitle = gsDefTitle; … … 339 360 { 340 361 case 3: 341 binsz = (MBinning*)plist->FindObject(bz, "MBinning");362 binsz = fBins[2] ? fBins[2] : (MBinning*)plist->FindObject(bz, "MBinning"); 342 363 if (!binsz) 343 364 { … … 354 375 fHist->SetBit(kIsLogz); 355 376 case 2: 356 binsy = (MBinning*)plist->FindObject(by, "MBinning");377 binsy = fBins[1] ? fBins[1] : (MBinning*)plist->FindObject(by, "MBinning"); 357 378 if (!binsy) 358 379 { … … 369 390 fHist->SetBit(kIsLogy); 370 391 case 1: 371 binsx = (MBinning*)plist->FindObject(bx, "MBinning");392 binsx = fBins[0] ? fBins[0] : (MBinning*)plist->FindObject(bx, "MBinning"); 372 393 if (!binsx) 373 394 { … … 507 528 { 508 529 GetRangeX(*fHist, lo, hi); 509 cout << "====> " << GetName() << " " << fHist->GetName() << ": " << lo << " " << hi <<" " << fHist->GetNbinsX() << endl;510 530 fHist->GetXaxis()->SetRange(lo-2, hi+1); 511 531 } … … 525 545 } 526 546 527 // --------------------------------------------------------------------------528 //529 // Setup a inversed deep blue sea palette for the fCenter histogram.530 //531 void MH3::SetColors() const532 {533 // FIXME: This must be redone each time the canvas is repainted....534 gStyle->SetPalette(51, NULL);535 Int_t c[50];536 for (int i=0; i<50; i++)537 c[49-i] = gStyle->GetColorPalette(i);538 gStyle->SetPalette(50, c);539 }540 541 547 void MH3::Paint(Option_t *o) 542 548 { 543 549 TProfile *p=0; 550 551 if (fDimension==2) 552 MH::SetPalette("pretty"); 544 553 545 554 const TString pfx(Form("%sProfX", fHist->GetName()));
Note:
See TracChangeset
for help on using the changeset viewer.