#include "display/DelphesHtmlSummary.h" #include "TGHtml.h" #include "TEveElement.h" #include "TEveManager.h" #include "TEveEventManager.h" #include "TEvePointSet.h" #include "TEveTrack.h" //============================================================================== DelphesHtmlSummary *fgDelphesHtmlSummary = 0; TGHtml *fgHtml = 0; //============================================================================== //______________________________________________________________________________ DelphesHtmlObjTable::DelphesHtmlObjTable(const char *name, Int_t nfields, Int_t nvals, Bool_t exp) : fName(name), fNValues(nvals), fNFields(nfields), fExpand(exp) { // Constructor. fValues = new TArrayF[fNFields]; for (int i=0;i 0) && (fNValues > 0)) { BuildLabels(); BuildTable(); } fHtml += ""; } //______________________________________________________________________________ void DelphesHtmlObjTable::BuildTitle() { // Build table title. fHtml += "", fNFields+1); fHtml += ""; fHtml += ""; fHtml += ""; fHtml += "
"; fHtml += ""; fHtml += fName; fHtml += ""; fHtml += " "; fHtml += ""; fHtml += Form("Size = %d", fNValues); fHtml += "
"; fHtml += ""; } //______________________________________________________________________________ void DelphesHtmlObjTable::BuildLabels() { // Build table labels. Int_t i; fHtml += ""; fHtml += " "; // for the check boxes for (i=0;i"; fHtml += "",i); fHtml += ""; for (int j = 0; j < fNFields; j++) { fHtml += "AddFirst(table); else fObjTables->Add(table); return table; } //______________________________________________________________________________ void DelphesHtmlSummary::Clear(Option_t *option) { // Clear the table list. if (option && option[0] == 'D') fObjTables->Delete(option); else fObjTables->Clear(option); fNTables = 0; } //______________________________________________________________________________ void DelphesHtmlSummary::Reset(Option_t *) { // Reset (delete) the table list; delete fObjTables; fObjTables = 0; fNTables = 0; } //______________________________________________________________________________ void DelphesHtmlSummary::Build() { // Build the summary. MakeHeader(); for (int i=0;iBuild(); fHtml += GetTable(i)->Html(); } MakeFooter(); } //______________________________________________________________________________ void DelphesHtmlSummary::MakeHeader() { // Make HTML header. fHeader = ""; fHeader += fTitle; fHeader += ""; fHeader += "

"; fHeader += fTitle; fHeader += "

"; fHtml = fHeader; } //______________________________________________________________________________ void DelphesHtmlSummary::MakeFooter() { // Make HTML footer. fFooter = "


"; fFooter += "Example of using Html widget to display tabular data"; fFooter += "
"; fFooter += "(c) 2007-2010 Bertrand Bellenot"; fFooter += "
"; fHtml += fFooter; }