PhotoWindow Class Reference

#include <HistoDisplayPhoto.h>

List of all members.

Public Member Functions

 PhotoWindow (const TGWindow *p, const TGWindow *main, UInt_t w, UInt_t h, UInt_t options=kMainFrame|kVerticalFrame)
virtual ~PhotoWindow ()
virtual void ClosePhotoWindow ()
virtual Bool_t ProcessMessage (Long_t msg, Long_t parm1, Long_t parm2)

Private Attributes

ULong_t LightYellow
ULong_t LightBlue
ULong_t Cyan
TGTextButton * fButton
TGPictureButton * fPicBut0
TGPictureButton * fPicBut1
TGLabel * fTitleLabel
TGLabel * fTextLabel0
TGLabel * fTextLabel1
TGLabel * fTextLabel2
TGLabel * fTextLabel3
TGLabel * fTextLabel4
TGLabel * fTextLabel5
TGLabel * fTextLabel41
TGCompositeFrame * fTitleFrame
TGCompositeFrame * fTextFrame0
TGCompositeFrame * fTextFrame1
TGCompositeFrame * fTextFrame2
GContext_t fTextGC0
GContext_t fTextGC1
GContext_t fTextGC2

Detailed Description

Definition at line 5 of file HistoDisplayPhoto.h.


Constructor & Destructor Documentation

PhotoWindow::PhotoWindow ( const TGWindow *  p,
const TGWindow *  main,
UInt_t  w,
UInt_t  h,
UInt_t  options = kMainFrame | kVerticalFrame 
)

Definition at line 5465 of file HistoDisplay.cxx.

References Cyan, fButton, fPicBut0, fPicBut1, fTextFrame0, fTextFrame1, fTextFrame2, fTextGC0, fTextGC1, fTextGC2, fTextLabel0, fTextLabel1, fTextLabel2, fTextLabel3, fTextLabel4, fTextLabel41, fTextLabel5, fTitleFrame, fTitleLabel, and LightYellow.

05467   :TGTransientFrame(p, main, w, h, options)
05468 {
05469     gClient->GetColorByName("Cyan",Cyan);
05470     ChangeBackground(Cyan);
05471 
05472  fTitleFrame = new TGCompositeFrame(this,800,100);
05473  FontStruct_t labelfont0, labelfont1;
05474  labelfont0 = gClient->GetFontByName("-adobe-helvetica-medium-r-*-*-18-*-*-*-*-*-iso8859-1");
05475    GCValues_t   gval0, gval1, gval2;
05476    gval0.fMask = kGCForeground | kGCFont;
05477    gval0.fFont = gVirtualX->GetFontHandle(labelfont0);
05478    gClient->GetColorByName("red", gval0.fForeground);
05479    fTextGC0 = gVirtualX->CreateGC(gClient->GetRoot()->GetId(), &gval0);
05480    fTitleLabel = new TGLabel(fTitleFrame, "MINOS Online Monitoring System", fTextGC0, labelfont0);
05481    fTitleLabel->ChangeBackground(Cyan);
05482    fTitleFrame->AddFrame(fTitleLabel, new TGLayoutHints(kLHintsTop | kLHintsCenterX));
05483 
05484    // fPicBut0 = new TGPictureButton(this, gClient->GetPicture("${CONSUMER_ICONS}/photo.xpm"), 1);
05485 
05486 fPicBut0 = new TGPictureButton(this, gClient->GetPicture("${CONSUMER_ICONS}/photo_old.xpm"), 1);
05487 
05488  fPicBut1 = new TGPictureButton(this, gClient->GetPicture("${CONSUMER_ICONS}/ta.xpm"), 2);
05489 
05490  fButton = new TGTextButton(this, "OK", 3);
05491  fButton->Associate(this);
05492  // fButton->SetCommand(".q" );
05493  gClient->GetColorByName("LightYellow",LightYellow);
05494  fButton->ChangeBackground(LightYellow);
05495 
05496 
05497    labelfont1 = gClient->GetFontByName("-adobe-helvetica-medium-r-*-*-12-*-*-*-*-*-iso8859-1");
05498    gval1.fMask = kGCForeground | kGCFont;
05499    gval1.fFont = gVirtualX->GetFontHandle(labelfont1);
05500    gClient->GetColorByName("blue", gval1.fForeground);
05501    fTextGC1 = gVirtualX->CreateGC(gClient->GetRoot()->GetId(), &gval1);
05502 
05503    gval2.fMask = kGCForeground | kGCFont;
05504    gval2.fFont = gVirtualX->GetFontHandle(labelfont1);
05505    gClient->GetColorByName("magenta", gval2.fForeground);
05506    fTextGC2 = gVirtualX->CreateGC(gClient->GetRoot()->GetId(), &gval2);
05507 
05508  fTextFrame0 = new TGCompositeFrame(this,100,50);
05509  fTextFrame1 = new TGCompositeFrame(this,100,50);
05510  fTextFrame2 = new TGCompositeFrame(this,100,50);
05511 
05512  fTextLabel0 = new TGLabel(fTextFrame0, "H. Wenzel", fTextGC1, labelfont1);
05513  fTextLabel1 = new TGLabel(fTextFrame0, "IEKP Karlsruhe", fTextGC2, labelfont1);
05514  fTextLabel2 = new TGLabel(fTextFrame1, "K. Maeshima                   K. Ikado        ", fTextGC1, labelfont1);
05515  fTextLabel3 = new TGLabel(fTextFrame1, "     Fermilab                 Waseda Univ.     ", fTextGC2, labelfont1);
05516  //fTextLabel4 = new TGLabel(fTextFrame2, "F. Hartmann                T. Arisawa                 G. Veramendi", fTextGC1, labelfont1);
05517  fTextLabel4 = new TGLabel(fTextFrame2, "H.Stadie,W.Wagner         T. Arisawa                 G. Veramendi", fTextGC1, labelfont1);
05518  fTextLabel41 = new TGLabel(fTextFrame2, " F.Hartmann", fTextGC1, labelfont1);
05519  fTextLabel5 = new TGLabel(fTextFrame2, "IEKP Karlsruhe              Waseda Univ.                   LBNL        ", fTextGC2, labelfont1);
05520 
05521  fTextLabel0->ChangeBackground(Cyan);
05522  fTextLabel1->ChangeBackground(Cyan);
05523  fTextLabel2->ChangeBackground(Cyan);
05524  fTextLabel3->ChangeBackground(Cyan);
05525  fTextLabel4->ChangeBackground(Cyan);
05526  fTextLabel41->ChangeBackground(Cyan);
05527  fTextLabel5->ChangeBackground(Cyan);
05528 
05529  fTextFrame0->AddFrame(fTextLabel0,new TGLayoutHints(kLHintsCenterX) );
05530  fTextFrame0->AddFrame(fTextLabel1,new TGLayoutHints(kLHintsCenterX) );
05531  fTextFrame1->AddFrame(fTextLabel2,new TGLayoutHints(kLHintsCenterX));
05532  fTextFrame1->AddFrame(fTextLabel3,new TGLayoutHints(kLHintsCenterX));
05533  fTextFrame2->AddFrame(fTextLabel4,new TGLayoutHints(kLHintsCenterX));
05534  fTextFrame2->AddFrame(fTextLabel41,new TGLayoutHints(kLHintsLeft));
05535  fTextFrame2->AddFrame(fTextLabel5,new TGLayoutHints(kLHintsCenterX));
05536 
05537  fTitleFrame->ChangeBackground(Cyan);
05538  fTextFrame0->ChangeBackground(Cyan);
05539  fTextFrame1->ChangeBackground(Cyan);
05540  fTextFrame2->ChangeBackground(Cyan);
05541 
05542     AddFrame(fTitleFrame, new TGLayoutHints(kLHintsTop | kLHintsExpandX,10,10,10,10));
05543     AddFrame(fPicBut0, new TGLayoutHints(kLHintsTop | kLHintsCenterX,10,10,0));
05544     AddFrame(fTextFrame0, new TGLayoutHints(kLHintsTop | kLHintsCenterX));
05545     AddFrame(fTextFrame1, new TGLayoutHints(kLHintsTop | kLHintsCenterX));
05546     AddFrame(fPicBut1, new TGLayoutHints(kLHintsTop | kLHintsCenterX,0,0,10));
05547     AddFrame(fTextFrame2, new TGLayoutHints(kLHintsTop | kLHintsCenterX));
05548     AddFrame(fButton, new TGLayoutHints(kLHintsBottom | kLHintsCenterX));
05549 
05550     MapSubwindows();
05551     Layout();
05552     SetWindowName("MINOS Online Monitoring System");
05553     MapWindow();
05554 
05555 }

PhotoWindow::~PhotoWindow (  )  [virtual]

Definition at line 5557 of file HistoDisplay.cxx.

References fButton, fPicBut0, fPicBut1, fTextFrame0, fTextFrame1, fTextFrame2, fTextLabel0, fTextLabel1, fTextLabel2, fTextLabel4, fTextLabel41, fTextLabel5, fTitleFrame, and fTitleLabel.

05558 {
05559   delete fButton;  delete fPicBut0; delete fPicBut1;
05560   delete fTitleLabel;  delete fTextLabel0;  delete fTextLabel1;
05561   delete fTextLabel2;  delete fTextLabel4;  delete fTextLabel5;
05562   delete fTextLabel41;
05563   delete fTitleFrame;  delete fTextFrame0;  delete fTextFrame1;
05564   delete fTextFrame2;
05565 }


Member Function Documentation

void PhotoWindow::ClosePhotoWindow (  )  [virtual]

Definition at line 5567 of file HistoDisplay.cxx.

Referenced by ProcessMessage().

05568 {
05569   delete this;
05570 }

Bool_t PhotoWindow::ProcessMessage ( Long_t  msg,
Long_t  parm1,
Long_t  parm2 
) [virtual]

Definition at line 5572 of file HistoDisplay.cxx.

References ClosePhotoWindow().

05573 {
05574   switch ( GET_MSG(msg) ) {
05575   case kC_COMMAND:
05576     switch ( GET_SUBMSG(msg) ) {
05577     case kCM_BUTTON:
05578       switch ( parm1 ) {
05579       case 3:
05580         {
05581           ClosePhotoWindow();
05582         }
05583         break; //case 3:
05584       default:
05585         break;
05586       } //switch ( parm1 ) 
05587       break; //case kCM_BUTTON:
05588     default:
05589       break;
05590     } // switch ( GET_SUBMSG(msg) ) 
05591     break; //case kC_COMMAND:
05592   default:
05593     break;
05594   } //switch ( GET_MSG(msg) )
05595   return kTRUE;
05596 }


Member Data Documentation

ULong_t PhotoWindow::Cyan [private]

Definition at line 8 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow().

TGTextButton* PhotoWindow::fButton [private]

Definition at line 9 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGPictureButton* PhotoWindow::fPicBut0 [private]

Definition at line 10 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGPictureButton * PhotoWindow::fPicBut1 [private]

Definition at line 10 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGCompositeFrame * PhotoWindow::fTextFrame0 [private]

Definition at line 14 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGCompositeFrame * PhotoWindow::fTextFrame1 [private]

Definition at line 14 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGCompositeFrame * PhotoWindow::fTextFrame2 [private]

Definition at line 14 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

GContext_t PhotoWindow::fTextGC0 [private]

Definition at line 15 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow().

GContext_t PhotoWindow::fTextGC1 [private]

Definition at line 15 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow().

GContext_t PhotoWindow::fTextGC2 [private]

Definition at line 15 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow().

TGLabel * PhotoWindow::fTextLabel0 [private]

Definition at line 11 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGLabel * PhotoWindow::fTextLabel1 [private]

Definition at line 11 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGLabel * PhotoWindow::fTextLabel2 [private]

Definition at line 11 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGLabel* PhotoWindow::fTextLabel3 [private]

Definition at line 12 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow().

TGLabel * PhotoWindow::fTextLabel4 [private]

Definition at line 12 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGLabel* PhotoWindow::fTextLabel41 [private]

Definition at line 13 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGLabel * PhotoWindow::fTextLabel5 [private]

Definition at line 12 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGCompositeFrame* PhotoWindow::fTitleFrame [private]

Definition at line 14 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

TGLabel* PhotoWindow::fTitleLabel [private]

Definition at line 11 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow(), and ~PhotoWindow().

ULong_t PhotoWindow::LightBlue [private]

Definition at line 8 of file HistoDisplayPhoto.h.

ULong_t PhotoWindow::LightYellow [private]

Definition at line 8 of file HistoDisplayPhoto.h.

Referenced by PhotoWindow().


The documentation for this class was generated from the following files:

Generated on 11 Jan 2018 for loon by  doxygen 1.6.1