22#include "RConfigure.h"
142 {
"folder", { 0, 0 } },
145 {
"slink", { 0, 0 } },
146 {
"histo", { 0, 0 } },
147 {
"object", { 0, 0 } }
156 {
"",
"",
kFALSE, -1, 0 },
161 {
"",
"",
kFALSE, -1, 0 },
165 {
"",
"",
kFALSE, -1, 0 },
167 {
"",
"",
kFALSE, -1, 0 },
212 if (cur->
fItem == item) {
273 fBuf->WriteObject(
object);
299 TGFileItem(p, bpic, 0, spic, 0,
name, 0, 0, 0, 0, 0, viewMode)
344 const char *
GetTitle()
const override{
return "ListView Container"; }
373 if (!
First())
return;
489 Bool_t xpm = xpm_magic ==
"/* ";
490 const char *iconname = xpm ? obj->
GetName() :
name;
502 *pic =
fClient->GetMimeTypeList()->GetIcon(iconname,
kFALSE);
504 if (!(*pic) && xpm) {
513 fClient->GetMimeTypeList()->AddType(
"[thumbnail]", iconname, iconname, iconname,
"->Browse()");
526 *spic =
fClient->GetMimeTypeList()->GetIcon(iconname,
kTRUE);
546 while ((li=(
TList *)next())) {
547 li->
Clear(
"nodelete");
571 isSystemFile =
kTRUE;
577 if (strcmp(
fListView->GetHeader(1),
"Attributes")) {
596 const char *thumbname =
gSystem->PrependPathName(
gSystem->WorkingDirectory(), temp_name);
618 data.fData = (
void *)str.Data();
619 data.fDataLength = str.Length()+1;
643 if (
f->GetUserData() == obj) {
659 if (strcmp(
fListView->GetHeader(1),
"Title")) {
791 if (
name.IsNull())
return 0;
821 li = (
TList*)
lv->GetUserData();
825 while ((obj=next())) {
827 idx = str.Index(
name,0,cmp);
1036 if (
gEnv->GetValue(
"Browser.ShowHidden", 0)) {
1150 fV1->Resize(
fTreeHdr->GetDefaultWidth()+100,
fV1->GetDefaultHeight());
1161 fHf->AddFrame(splitter, lo);
1170 fLt->Associate(
this);
1185 TString str =
gEnv->GetValue(
"Browser.AutoThumbnail",
"yes");
1187 fIconBox->fAutoThumbnail = (str ==
"yes") || atoi(str.Data());
1191 str =
gEnv->GetValue(
"Browser.GroupView",
"10000");
1192 Int_t igv = atoi(str.Data());
1206 int parts[] = { 26, 74 };
1240 printf(
"\n You are using the old ROOT browser! A new version is available. To use it:\n");
1241 printf(
" Select the \"New Browser\" entry from the \"File\" menu in the browser, or change\n");
1242 printf(
" \"Browser.Name:\" from \"TRootBrowserLite\" to \"TRootBrowser\" in system.rootrc\n\n");
1244 Connect(
fLt,
"Checked(TObject*, Bool_t)",
"TRootBrowserLite",
1245 this,
"Checked(TObject *,Bool_t)");
1256 gVirtualX->LookupString(event, input,
sizeof(input), keysym);
1267 switch ((
EKeySym)keysym & ~0x20) {
1303 if (
f->GetUserData() == obj) {
1304 f->SetCheckedEntry(check);
1311 if (
name[0] ==
'.' && ((
name[1] ==
'\0') || (
name[1] ==
'.' &&
name[2] ==
'\0')))
1328 fLt->CheckItem(item, check);
1335 if (
f->GetUserData() == obj) {
1336 f->SetCheckedEntry(check);
1351 fLt->CheckItem(item, check);
1358 if (
f->GetUserData() == obj) {
1359 f->SetCheckedEntry(check);
1382 if (
f->GetUserData() == obj) {
1415 objClass = obj->
IsA();
1432 if (
name[0] ==
'.' &&
name[1] ==
'.')
1433 Info(
"AddToTree",
"up one level %s",
name);
1436 if (item)
fLt->CheckItem(item, (
Bool_t)check);
1442 fLt->SetToolTipItem(item, tip.
Data());
1463 Long64_t bsize, fsize, objsize = 0;
1469 objsize = objinfo.
Atoll();
1472 bsize = fsize = objsize;
1506 if (!
fLt->FindItemByObj(
fLt->GetFirstItem(), obj)) {
1513 fLt->ClearViewPort();
1592 fmt =
"%d Object%s, %d selected.";
1594 fmt =
"%d Object%s.";
1605 char *p, path[1024];
1609 while (*p && *(p+1) ==
'/') ++p;
1619 while (*p && *(p+1) ==
'/') ++p;
1628 Bool_t disableUp = dirname ==
"/";
1632 disableUp = strlen(p) == 1;
1658 if (
fClient->GetMimeTypeList()->GetAction(obj->
GetName(), action)) {
1663 if (act[0] ==
'!') {
1679 gApplication->ProcessLine(
"((TApplicationServer *)gApplication)->BrowseFile(0);");
1687 fLt->ClearHighlighted();
1705 if (
fIconBox->fAutoThumbnail && nowp && (nowp != wasp)) {
1729 static const UInt_t sz = 72;
1737 h = (imgh*sz) / (imgw > 0 ? imgw : 1);
1739 w = (imgw*sz) / (imgh > 0 ? imgh : 1);
1742 w = (w < 54) ? 54 : w;
1743 h = (
h < 54) ? 54 :
h;
1746 img->
Merge(img,
"tint");
1747 img->
DrawBox(0, 0, w,
h,
"#ffff00", 1);
1797 new TBrowser(
"Browser",
"ROOT Object Browser");
1800 gEnv->SetValue(
"Browser.Name",
"TRootBrowser");
1802 gEnv->SetValue(
"Browser.Name",
"TRootBrowserLite");
1805 gROOT->MakeDefCanvas();
1886 TString gv =
gEnv->GetValue(
"Browser.GroupView",
"10000");
1900 printf(
"Currently the browser always shows all cycles\n");
1990 hd =
new TRootHelpDialog(
this,
"Help on Graphics Editor...", 600, 400);
2022 const char *dirname =
e->GetPath()->GetString();
2023 item =
fLt->FindItemByPathname(dirname);
2054 if ((item2 =
fLt->GetSelected()) != 0 ) {
2116 if (
fIconBox->NumSelected() == 1) {
2135 fLt->ClearHighlighted();
2136 fLt->HighlightItem(itm);
2146 if (
fIconBox->NumSelected() == 1) {
2166 Error(
"ProcessMessage",
"do not support non TObject (like %s) yet",
2191 if (
fIconBox->NumSelected() == 1) {
2200 delete cursorSwitcher;
2219 delete cursorSwitcher;
2245 if (strcmp(((
TKey*)obj)->GetClassName(),
"TDirectoryFile") == 0) {
2265 fLt->ClearHighlighted();
2321 fLt->ClearHighlighted();
2325 fLt->AdjustPosition();
2357 fLt->ClearHighlighted();
2361 fLt->AdjustPosition();
2381 fLt->DeleteItem(item);
2427 while ( probj && strcmp(probj->
GetClassName(),
"TFile")) {
2435 TString::Format(
"((TApplicationServer *)gApplication)->BrowseFile(\"%s\");",
2450 else if (!strcmp(item->
GetText(),
"ROOT Files")) {
2453 gApplication->ProcessLine(
"((TApplicationServer *)gApplication)->BrowseFile(0);");
2464 if (topobj && topobj->
InheritsFrom(
"TApplicationRemote")) {
2478 Getlinem(kInit,
"\nroot [0]");
2511 gROOT->GetListOfBrowsables()->Remove(old);
2513 gROOT->GetListOfBrowsables()->Add(obj);
2562 Emit(
"Checked(TObject*,Bool_t)", args);
2596 TKey *key =
dynamic_cast<TKey*
>(obj);
2605 if (t ==
".")
goto out;
2632 itm =
fLt->GetFirstItem();
2743 fLt->ClearHighlighted();
2766 if ( (refresh || force) && !
fIconBox->WasGrouped()
2771 UInt_t curr =
gROOT->GetListOfBrowsables()->GetSize();
2772 if (!prev) prev = curr;
2836 opt =
gEnv->GetValue(
"Browser.IconStyle",
"small");
2837 if (!strcasecmp(opt,
"big"))
2839 else if (!strcasecmp(opt,
"small"))
2841 else if (!strcasecmp(opt,
"list"))
2843 else if (!strcasecmp(opt,
"details"))
2852 opt =
gEnv->GetValue(
"Browser.SortBy",
"name");
2853 if (!strcasecmp(opt,
"name"))
2855 else if (!strcasecmp(opt,
"type"))
2857 else if (!strcasecmp(opt,
"size"))
2859 else if (!strcasecmp(opt,
"date"))
2905 for (i = 2; i <= 5; ++i)
2911 if (!strcmp(
fListView->GetHeader(1),
"Attributes")) {
2912 buttons[0]->
Connect(
"Clicked()",
"TRootBrowserLite",
this,
2914 buttons[1]->
Connect(
"Clicked()",
"TRootBrowserLite",
this,
2916 buttons[2]->
Connect(
"Clicked()",
"TRootBrowserLite",
this,
2918 buttons[5]->
Connect(
"Clicked()",
"TRootBrowserLite",
this,
2974 for (
int i = 0; i < len; i++) {
2976 if (((
c < 32) || (
c > 126)) && (
c !=
'\t') && (
c !=
'\r') && (
c !=
'\n')) {
3000 fV2->MapSubwindows();
3018 const int bufferSize = 1024;
3019 char buffer[bufferSize];
3021 FILE *fd = fopen(file,
"rb");
3028 int sz = fread(buffer, 1, bufferSize, fd);
3031 if ((sz > 0) &&
isBinary(buffer, sz)) {
3046 fTextEdit,
"Search(char *,Bool_t,Bool_t)");
3050 savbtn->
Connect(
"Released()",
"TGTextEdit",
fTextEdit,
"SaveFile(=0,kTRUE)");
3064 fV2->MapSubwindows();
3090 const char *tmpfile =
gSystem->PrependPathName(
gSystem->TempDirectory(), temp);
3094 gROOT->Macro(tmpfile);
3128 bt1->
Connect(
"Pressed()",
"TRootBrowserLite",
this,
"ExecMacro()");
3129 bt2->
Connect(
"Pressed()",
"TRootBrowserLite",
this,
"InterruptMacro()");
const Mask_t kKeyMod1Mask
typically the Alt key
EMouseButton
Button names.
R__EXTERN const char gHelpObjects[]
R__EXTERN const char gHelpPullDownMenus[]
R__EXTERN const char gHelpRemote[]
R__EXTERN const char gHelpAbout[]
R__EXTERN const char gHelpGraphicsEditor[]
R__EXTERN const char gHelpCanvas[]
R__EXTERN const char gHelpBrowserLite[]
R__EXTERN const char gHelpPostscript[]
int Int_t
Signed integer 4 bytes (int).
long Longptr_t
Integer large enough to hold a pointer (platform-dependent).
unsigned int UInt_t
Unsigned integer 4 bytes (unsigned int).
unsigned long ULong_t
Unsigned long integer 4 bytes (unsigned long). Size depends on architecture.
bool Bool_t
Boolean (0=false, 1=true) (bool).
constexpr Ssiz_t kNPOS
The equivalent of std::string::npos for the ROOT class TString.
long long Long64_t
Portable signed long integer 8 bytes.
const char Option_t
Option string (const char).
externTApplication * gApplication
Error("WriteTObject","The current directory (%s) is not associated with a file. The object (%s) has not been written.", GetName(), objname)
void Info(const char *location, const char *msgfmt,...)
Use this function for informational messages.
externTGDNDManager * gDNDManager
static unsigned int total
static Bool_t isBinary(const char *str, int len)
test
static ToolBarData_t gToolBarData[]
static const char * gOpenTypes[]
char * Form(const char *fmt,...)
Formats a string in a circular formatting buffer.
TBrowserImp(const TBrowserImp &)=delete
TBrowser * fBrowser
TBrowser associated with this implementation.
Using a TBrowser one can browse all ROOT objects.
The concrete implementation of TBuffer for writing/reading to/from a ROOT file or socket.
TClass instances represent classes, structs and namespaces in the ROOT type system.
TMethod * GetMethodWithPrototype(const char *method, const char *proto, Bool_t objectIsConst=kFALSE, ROOT::EFunctionMatchMode mode=ROOT::kConversionMatch)
Find the method with a given prototype.
Bool_t IsTObject() const
Return kTRUE is the class inherits from TObject.
Bool_t InheritsFrom(const char *cl) const override
Return kTRUE if this class inherits from a class with name "classname".
Bool_t HasDefaultConstructor(Bool_t testio=kFALSE) const
Return true if we have access to a constructor usable for I/O.
static TClass * GetClass(const char *name, Bool_t load=kTRUE, Bool_t silent=kFALSE)
Static method returning pointer to TClass of the specified class name.
Drag and drop data container.
Describe directory structure in memory.
A file, usually with extension .root, that stores data and code in the form of serialized objects in ...
A frame containing two scrollbars (a horizontal and a vertical) and a viewport.
A combobox (also known as a drop down listbox) allows the selection of one item out of a list of item...
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=nullptr)
Add frame to the composite frame using the specified layout hints.
virtual TList * GetList() const
void MapSubwindows() override
Map all sub windows that are part of the composite frame.
TGCompositeFrame(const TGCompositeFrame &)=delete
virtual void ShowFrame(TGFrame *f)
Show sub frame.
TList * fList
container of frame elements
void SetEditDisabled(UInt_t on=1) override
Set edit disable flag for this frame and subframes.
virtual void HideFrame(TGFrame *f)
Hide sub frame.
const TGWindow * fMsgWindow
window handling container messages
virtual TGFrameElement * FindFrame(Int_t x, Int_t y, Bool_t exclude=kTRUE)
Find frame located int container at position x,y.
Bool_t fLastDir
direction of last search
Int_t fSelected
number of selected items
TString fLastName
the name of object of last search
virtual void * FindItem(const TString &name, Bool_t direction=kTRUE, Bool_t caseSensitive=kTRUE, Bool_t subString=kFALSE)
Bool_t fLastCase
case sensitivity of last search
void RemoveAll() override
Remove all items from the container.
TGFrameElement * fLastActiveEl
last active item
This is a combo box that is used in the File Selection dialog box.
const TGPicture * fFolder_s
big folder icon
TViewUpdateTimer * fRefresh
refresh timer
void StopRefreshTimer()
stop refresh timer
const TGPicture * fDoc_t
small document icon
virtual void Sort(EFSSortMode sortType)
Sort file system list view container according to sortType.
const TGPicture * fDoc_s
big document icon
virtual TGFileItem * AddFile(const char *name, const TGPicture *pic=nullptr, const TGPicture *lpic=nullptr)
Add file in container.
virtual TGFileItem * AddRemoteFile(TObject *obj, const TGPicture *ipic=nullptr, const TGPicture *ilpic=nullptr)
Add remote file in container.
const TGPicture * fFolder_t
small folder icon
TGFileContainer(const TGWindow *p=nullptr, UInt_t w=1, UInt_t h=1, UInt_t options=kSunkenFrame, Pixel_t back=GetDefaultFrameBackground())
Create a list view container which will hold the contents of the current directory.
EFSSortMode fSortType
sorting mode of contents
This class creates a file selection dialog.
TList * fFileNamesList
list of selected file names
char * fFilename
selected file name
const char ** fFileTypes
file types used to filter selectable files
char * fIniDir
on input: initial directory, on output: new directory
Bool_t fMultipleSelection
if true, allow multiple file selection
void SetIniDir(const char *inidir)
Set directory name.
TBufferFile * fBuf
buffer used for Drag and Drop
void SetDNDData(TDNDData *data)
Set drag and drop data.
TGFileItem(const TGWindow *p=nullptr, const TGPicture *bpic=nullptr, const TGPicture *blpic=nullptr, const TGPicture *spic=nullptr, const TGPicture *slpic=nullptr, TGString *name=nullptr, Int_t type=0, Long64_t size=1, Int_t uid=0, Int_t gid=0, Long_t modtime=0, EListViewMode viewMode=kLVList, UInt_t options=kVerticalFrame, Pixel_t back=GetWhitePixel())
Create a list view item.
void MoveResize(Int_t x, Int_t y, UInt_t w=0, UInt_t h=0) override
Move and/or resize the frame.
void Resize(UInt_t w=0, UInt_t h=0) override
Resize the frame.
TGFrame(const TGFrame &)=delete
void MapWindow() override
map window
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
virtual void DeleteWindow()
Delete window.
void SetDNDSource(Bool_t onoff)
void UnmapWindow() override
unmap window
virtual void SendMessage(const TGWindow *w, Longptr_t msg, Longptr_t parm1, Longptr_t parm2)
Send message (i.e.
static Pixel_t fgWhitePixel
A horizontal 3D line is a line that typically separates a toolbar from the menubar.
A composite frame that layout their children in horizontal way.
A Composite frame that contains a list of TGLBEnties.
TGListView * fListView
listview which contains this container
virtual void AddItem(TGLVEntry *item)
TGString ** fSubnames
sub names of item (details)
FontStruct_t fFontStruct
text font
void * GetUserData() const
Int_t * fCtw
width of sub names
void SetUserData(void *userData)
This class handles GUI labels.
This class describes layout hints used by the layout classes.
A listbox is a box, possibly with scrollbar, containing entries.
void Resize(UInt_t w, UInt_t h) override
Resize the listbox widget.
virtual TGFrame * GetContainer() const
virtual const char * GetText() const =0
TGListTreeItem * GetNextSibling() const
TGListTreeItem * GetParent() const
virtual void SetTipText(const char *)
virtual void * GetUserData() const =0
virtual void SetUserData(void *, Bool_t=kFALSE)
A list tree is a widget that can contain a number of items arranged in a tree structure.
A list view is a widget that can contain a number of items arranged in a grid or list.
TGMainFrame(const TGMainFrame &)=delete
Atom_t * fDNDTypeList
handles DND types
virtual void SendCloseMessage()
Send close message to self.
void SetClassHints(const char *className, const char *resourceName)
Set the windows class and resource name.
void SetIconName(const char *name)
Set window icon name. This is typically done via the window manager.
void SetWMPosition(Int_t x, Int_t y)
Give the window manager a window position hint.
void SetWindowName(const char *name=nullptr) override
Set window name. This is typically done via the window manager.
Bool_t HandleKey(Event_t *event) override
Handle keyboard events.
void SetWMSizeHints(UInt_t wmin, UInt_t hmin, UInt_t wmax, UInt_t hmax, UInt_t winc, UInt_t hinc)
Give the window manager minimum and maximum size hints.
const TGPicture * SetIconPixmap(const char *iconName)
Set window icon pixmap by name.
TGClient * fClient
Connection to display server.
Handle_t fId
X11/Win32 Window identifier.
The TGPicture class implements pictures and icons used in the different GUI elements and widgets.
static TGSearchDialog *& SearchDialog()
Return global search dialog.
Provides a StatusBar widget.
virtual void SetText(TGString *text, Int_t partidx=0)
Set text in partition partidx in status bar.
TGString wraps a TString and adds some graphics routines like drawing, size of string on screen depen...
const char * GetString() const
Yield an action as soon as it is clicked.
A TGTextEdit is a specialization of TGTextView.
A TGTextEntry is a one line text input widget.
virtual void SetToolTipText(const char *text, Long_t delayms=500)
Set tool tip text associated with this text entry.
Text string listbox entries.
const TGString * GetText() const
void SetFrame(TGFrame *frame, Bool_t left) override
Set frame to be resized.
A composite frame that layout their children in vertical way.
ROOT GUI Window base class.
@ kEditDisable
disable edit of this window
virtual void DestroyWindow()
destroy window
const TGWindow * GetParent() const
static TGuiBuilder * Instance()
return an instance of TGuiBuilder object
THashTable implements a hash table to store TObject's.
TIconBoxThumb(const char *name, const TGPicture *spic, const TGPicture *pic)
const char * GetName() const override
Returns name of object.
ULong_t Hash() const override
Return hash value for this object.
An abstract interface to image processing library.
virtual void FromPad(TVirtualPad *, Int_t=0, Int_t=0, UInt_t=0, UInt_t=0)
virtual UInt_t GetWidth() const
virtual void DrawBox(Int_t, Int_t, Int_t, Int_t, const char *="#000000", UInt_t=1, Int_t=0)
static TImage * Create()
Create an image.
virtual Bool_t SetImageBuffer(char **, EImageFileTypes=TImage::kPng)
virtual Bool_t IsValid() const
virtual void Scale(UInt_t, UInt_t)
virtual void Merge(const TImage *, const char *="alphablend", Int_t=0, Int_t=0)
virtual Pixmap_t GetPixmap()
virtual Pixmap_t GetMask()
virtual UInt_t GetHeight() const
Utility class for browsing TMapFile objects.
Book space in a file, create I/O buffers, to fill them, (un)compress them.
virtual const char * GetClassName() const
TClass * IsA() const override
Short_t GetCycle() const
Return cycle number associated to this key.
void Clear(Option_t *option="") override
Remove all objects from the list.
TList(const TList &)=delete
TObject * Remove(TObject *obj) override
Remove object from the list.
TObject * Last() const override
Return the last object in the list. Returns 0 when list is empty.
TObject * First() const override
Return the first object in the list. Returns 0 when list is empty.
virtual TObjLink * FirstLink() const
const char * GetName() const override
Returns name of object.
Wrapper around a TObject so it can be stored in a TList.
TObject * GetObject() const
Collectable string class.
const TString & GetString() const
Mother of all ROOT objects.
virtual Bool_t IsFolder() const
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects).
virtual const char * GetName() const
Returns name of object.
virtual void Browse(TBrowser *b)
Browse object. May be overridden for another default action.
virtual const char * GetIconName() const
Returns mime type name of object.
virtual const char * ClassName() const
Returns name of class to which the object belongs.
virtual char * GetObjectInfo(Int_t px, Int_t py) const
Returns string containing info about the object at position (px,py).
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
virtual const char * GetTitle() const
Returns title of object.
virtual TClass * IsA() const
TObject()
TObject constructor.
void Emit(const char *signal, const T &arg)
Activate signal with single parameter.
Bool_t Connect(const char *signal, const char *receiver_class, void *receiver, const char *slot)
Non-static method is used to connect from the signal of this object to the receiver slot.
Bool_t Disconnect(const char *signal=nullptr, void *receiver=nullptr, const char *slot=nullptr)
Disconnects signal of this object from slot of receiver.
The TRemoteObject class provides protocol for browsing ROOT objects from a remote ROOT session.
const char * GetClassName() const
const char * GetKeyClassName() const
TRootBrowserCursorSwitcher(TGWindow *w1, TGWindow *w2)
~TRootBrowserCursorSwitcher()
void Print(Option_t *) const override
This method must be overridden when a class wants to print itself.
TRootBrowserHistoryCursor(TGListTreeItem *item)
void DeleteItem(TGListTreeItem *item)
void RecursiveRemove(TObject *obj) override
Remove object from this collection and recursively remove the object from all other objects (and coll...
TGCompositeFrame * fTreeHdr
TGPopupMenu * fOptionMenu
friend class TRootIconBox
Bool_t HistoryBackward()
go to the past
void SetStatusText(const char *txt, Int_t col) override
Set text in column col in status bar.
Bool_t ProcessMessage(Longptr_t msg, Longptr_t parm1, Longptr_t parm2) override
Handle menu and other command generated by the user.
void SetViewMode(Int_t new_mode, Bool_t force=kFALSE)
Set iconbox's view mode and update menu and toolbar buttons accordingly.
void Refresh(Bool_t force=kFALSE) override
Refresh the browser contents.
TGLayoutHints * fMenuBarHelpLayout
void ListTreeHighlight(TGListTreeItem *item)
Open tree item and list in iconbox its contents.
TGFileContainer * GetIconBox() const
returns pointer to fIconBox object
void SetSortMode(Int_t new_mode)
Set iconbox's sort mode and update menu radio buttons accordingly.
void ClearHistory()
clear navigation history
~TRootBrowserLite() override
Browser destructor.
TGListTreeItem * fListLevel
current TGListTree level
TGLayoutHints * fExpandLayout
void RecursiveRemove(TObject *obj) override
Recursively remove object from browser.
void BrowseTextFile(const char *file)
browse text file
Option_t * GetDrawOption() const override
returns drawing option
void ReallyDelete() override
Really delete the browser and the this GUI.
virtual void DoubleClicked(TObject *obj)
Emits signal when double clicking on icon.
TGLayoutHints * fComboLayout
void Chdir(TGListTreeItem *item)
Make object associated with item the current directory.
void ExecMacro()
executed browsed text macro
TGComboBox * fDrawOption
drawing option entry
virtual void ShowToolBar(Bool_t show=kTRUE)
Show or hide toolbar.
void HighlightListLevel()
helper method to track history
Bool_t HistoryForward()
go to the future
static TBrowserImp * NewBrowser(TBrowser *b=nullptr, const char *title="ROOT Browser", UInt_t width=800, UInt_t height=500, Option_t *opt="")
Interface method to the old browser.
TGLayoutHints * fMenuBarLayout
virtual void AddToTree(TObject *obj, const char *name, Int_t check=-1)
Add items to the current TGListTree of the browser.
const TGPicture * fIconPic
icon picture
void AddToHistory(TGListTreeItem *item)
helper method to track history
TGLayoutHints * fBarLayout
void BrowseObj(TObject *obj) override
Browse object.
Bool_t fTreeLock
true when we want to lock TGListTree
virtual void Checked(TObject *obj, Bool_t check)
Emits signal when double clicking on icon.
void DisplayTotal(Int_t total, Int_t selected)
Display in statusbar total number of objects and number of selected objects in IconBox.
void CloseWindow() override
In case window is closed via WM we get here.
Int_t fSortMode
current IconBox sort mode
void IconBoxAction(TObject *obj)
Default action when double clicking on icon.
TGLayoutHints * fMenuBarItemLayout
void HideTextEdit()
hide text edit
TGStatusBar * GetStatusBar() const
void DisplayDirectory()
Display current directory in second label, fLbl2.
void ShowMacroButtons(Bool_t show=kTRUE)
show/hide macro buttons
virtual void AddToBox(TObject *obj, const char *name)
Add items to the iconbox of the browser.
virtual void ShowStatusBar(Bool_t show=kTRUE)
Show or hide statusbar.
TRootBrowserLite(const TRootBrowserLite &)=delete
void Search()
starts serach dialog
TList * fHistory
history of browsing
void CheckObjectItem(TObject *obj, Bool_t check=kFALSE) override
Check / uncheck the TGListTreeItem corresponding to this object and add a checkmark on TGLVEntry if c...
Bool_t HandleKey(Event_t *event) override
handle keys
TObject * fHistoryCursor
current history position
Int_t fViewMode
current IconBox view mode
virtual void SetDefaults(const char *iconStyle=nullptr, const char *sortBy=nullptr)
Set defaults depending on settings in the user's .rootrc.
TGFSComboBox * fFSComboBox
void InterruptMacro()
interrupt browsed macro execution
void SetDrawOption(Option_t *option="") override
sets drawing option
TGCompositeFrame * fListHdr
void UpdateDrawOption()
add new draw option to the "history"
TGTextEdit * fTextEdit
contents of browsed text file
void CreateBrowser(const char *name)
Create the actual browser.
void ToSystemDirectory(const char *dirname)
display directory
void ExecuteDefaultAction(TObject *obj) override
Execute default action for selected object (action is specified in the $HOME/.root....
void AddCheckBox(TObject *obj, Bool_t check=kFALSE) override
Add a checkbox in the TGListTreeItem corresponding to obj and a checkmark on TGLVEntry if check = kTR...
void Add(TObject *obj, const char *name=nullptr, Int_t check=-1) override
Add items to the browser.
void DeleteListTreeItem(TGListTreeItem *item)
delete list tree item, remove it from history
TGHorizontal3DLine * fToolBarSep
void RemoveCheckBox(TObject *obj) override
Remove checkbox from TGListTree and checkmark from TGListView.
A TRootHelpDialog is used to display help text (or any text in a dialog window).
void SetText(const char *helpText)
Set help text from helpText buffer in TGTextView.
void Popup()
Show help dialog.
friend class TRootBrowserLite
friend class TRootIconList
~TRootIconBox() override
destructor
TGFrameElement * FindFrame(Int_t x, Int_t y, Bool_t exclude=kTRUE) override
Find frame located int container at position x,y.
const TGPicture * fSmallCachedPic
void RemoveGarbage()
delete all TRootIconLists from garbage
void SetGroupSize(Int_t siz)
Bool_t WasGrouped() const
const TGPicture * fLargeCachedPic
void AddObjItem(const char *name, TObject *obj, TClass *cl)
Add object to iconbox.
TRootIconBox(TRootBrowserLite *browser, TGListView *lv, UInt_t options=kSunkenFrame, ULong_t back=GetDefaultFrameBackground())
Create iconbox containing ROOT objects in browser.
Int_t GetGroupSize() const
TRootObjItem * fCurrentItem
void Refresh()
Sort icons, and send message to browser with number of objects in box.
void GetObjPictures(const TGPicture **pic, const TGPicture **spic, TObject *obj, const char *name)
Retrieve icons associated with class "name".
void * FindItem(const TString &name, Bool_t direction=kTRUE, Bool_t caseSensitive=kTRUE, Bool_t beginWith=kFALSE) override
Find a frame which assosiated object has a name containing a "name" string.
TRootIconList * fCurrentList
TRootBrowserLite * fBrowser
void SetObjHeaders()
Set list box headers used to display detailed object iformation.
void RemoveAll() override
Remove all items from icon box.
void UpdateName()
composite name
void Browse(TBrowser *b) override
browse icon list
TRootIconList(TRootIconBox *box=nullptr)
constructor
const char * GetTitle() const override
Returns title of object.
Bool_t IsFolder() const override
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects).
const TGPicture * GetPicture() const
~TRootIconList() override
destructor
TRootObjItem(const TGWindow *p, const TGPicture *bpic, const TGPicture *spic, TGString *name, TObject *obj, TClass *cl, EListViewMode viewMode=kLVSmallIcons)
Create an icon box item.
TDNDData * GetDNDData(Atom_t) override
Bool_t HandleDNDFinished() override
Bool_t EndsWith(const char *pat, ECaseCompare cmp=kExact) const
Return true if string ends with the specified string.
const char * Data() const
TString & ReplaceAll(const TString &s1, const TString &s2)
Bool_t BeginsWith(const char *s, ECaseCompare cmp=kExact) const
TString & Prepend(const char *cs)
TString & Remove(Ssiz_t pos)
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
Long64_t Atoll() const
Return long long value of string.
Describes an Operating System directory for the browser.
A TSystemFile describes an operating system file.
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual void Modified(Bool_t flag=1)=0
void box(Int_t pat, Double_t x1, Double_t y1, Double_t x2, Double_t y2)
const char * fPicnamePrefix
const TGPicture * fIcon[2]
EGEventType fType
of event (see EGEventType)
UInt_t fState
key or button mask