{ "cells": [ { "cell_type": "markdown", "id": "a1887bb9", "metadata": {}, "source": [ "# event\n", "Illustrate some basic primitives.\n", "\n", "\n", "\n", "\n", "**Author:** Rene Brun \n", "This notebook tutorial was automatically generated with ROOTBOOK-izer from the macro found in the ROOT repository on Tuesday, March 19, 2024 at 07:09 PM." ] }, { "cell_type": "code", "execution_count": 1, "id": "a8aa7d32", "metadata": { "collapsed": false, "execution": { "iopub.execute_input": "2024-03-19T19:09:45.281999Z", "iopub.status.busy": "2024-03-19T19:09:45.281566Z", "iopub.status.idle": "2024-03-19T19:09:46.388875Z", "shell.execute_reply": "2024-03-19T19:09:46.387602Z" } }, "outputs": [], "source": [ "TCanvas *c1 = new TCanvas(\"c1\",\"ROOT Event description\",700,500);\n", "c1->Range(0,0,14,15.5);\n", "TPaveText *event = new TPaveText(1,13,3,15);\n", "event->SetFillColor(11);\n", "event->Draw();\n", "event->AddText(\"Event\");\n", "TLine *line = new TLine(1.1,13,1.1,1.5);\n", "line->SetLineWidth(2);\n", "line->Draw();\n", "line->DrawLine(1.3,13,1.3,3.5);\n", "line->DrawLine(1.5,13,1.5,5.5);\n", "line->DrawLine(1.7,13,1.7,7.5);\n", "line->DrawLine(1.9,13,1.9,9.5);\n", "line->DrawLine(2.1,13,2.1,11.5);\n", "TArrow *arrow = new TArrow(1.1,1.5,3.9,1.5,0.02,\"|>\");\n", "arrow->SetFillStyle(1001);\n", "arrow->SetFillColor(1);\n", "arrow->Draw();\n", "arrow->DrawArrow(1.3,3.5,3.9,3.5,0.02,\"|>\");\n", "arrow->DrawArrow(1.5,5.5,3.9,5.5,0.02,\"|>\");\n", "arrow->DrawArrow(1.7,7.5,3.9,7.5,0.02,\"|>\");\n", "arrow->DrawArrow(1.9,9.5,3.9,9.5,0.02,\"|>\");\n", "arrow->DrawArrow(2.1,11.5,3.9,11.5,0.02,\"|>\");\n", "TPaveText *p1 = new TPaveText(4,1,11,2);\n", "p1->SetTextAlign(12);\n", "p1->SetFillColor(42);\n", "p1->AddText(\"1 Mbyte\");\n", "p1->Draw();\n", "TPaveText *p2 = new TPaveText(4,3,10,4);\n", "p2->SetTextAlign(12);\n", "p2->SetFillColor(42);\n", "p2->AddText(\"100 Kbytes\");\n", "p2->Draw();\n", "TPaveText *p3 = new TPaveText(4,5,9,6);\n", "p3->SetTextAlign(12);\n", "p3->SetFillColor(42);\n", "p3->AddText(\"10 Kbytes\");\n", "p3->Draw();\n", "TPaveText *p4 = new TPaveText(4,7,8,8);\n", "p4->SetTextAlign(12);\n", "p4->SetFillColor(42);\n", "p4->AddText(\"1 Kbytes\");\n", "p4->Draw();\n", "TPaveText *p5 = new TPaveText(4,9,7,10);\n", "p5->SetTextAlign(12);\n", "p5->SetFillColor(42);\n", "p5->AddText(\"100 bytes\");\n", "p5->Draw();\n", "TPaveText *p6 = new TPaveText(4,11,6,12);\n", "p6->SetTextAlign(12);\n", "p6->SetFillColor(42);\n", "p6->AddText(\"10 bytes\");\n", "p6->Draw();\n", "TText text;\n", "text.SetTextAlign(12);\n", "text.SetTextSize(0.04);\n", "text.SetTextFont(72);\n", "text.DrawText(6.2,11.5,\"Header:Event_flag\");\n", "text.DrawText(7.2,9.5,\"Trigger_Info\");\n", "text.DrawText(8.2,7.5,\"Muon_Detector: TOF\");\n", "text.DrawText(9.2,5.5,\"Calorimeters\");\n", "text.DrawText(10.2,3.5,\"Forward_Detectors\");\n", "text.DrawText(11.2,1.5,\"TPCs\");" ] }, { "cell_type": "markdown", "id": "32cee47d", "metadata": {}, "source": [ "Draw all canvases " ] }, { "cell_type": "code", "execution_count": 2, "id": "ffda69c4", "metadata": { "collapsed": false, "execution": { "iopub.execute_input": "2024-03-19T19:09:46.395495Z", "iopub.status.busy": "2024-03-19T19:09:46.395134Z", "iopub.status.idle": "2024-03-19T19:09:46.798406Z", "shell.execute_reply": "2024-03-19T19:09:46.796672Z" } }, "outputs": [ { "data": { "text/html": [ "\n", "\n", "