63 "HTML files",
"*.htm*",
69"<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\" \"http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd\"> ",
70"<HTML><HEAD><TITLE>RHTML cannot display the webpage</TITLE> ",
71"<META http-equiv=Content-Type content=\"text/html; charset=UTF-8\"></HEAD> ",
73"<TABLE cellSpacing=0 cellPadding=0 width=730 border=0> ",
76" <TD id=infoIconAlign vAlign=top align=left width=60 rowSpan=2> ",
77" <IMG src=\"info.gif\"> ",
79" <TD id=mainTitleAlign vAlign=center align=left width=*> ",
80" <H1 id=mainTitle>RHTML cannot display the webpage</H1></TD></TR> ",
82" <TD class=errorCodeAndDivider id=errorCodeAlign align=right> ",
83" <DIV class=divider></DIV></TD></TR> ",
88" <TD id=MostLikelyAlign vAlign=top align=left> ",
89" <H3 id=likelyCauses>Most likely causes:</H3> ",
91" <LI id=causeNotConnected>You are not connected to the Internet. ",
92" <LI id=causeSiteProblem>The website is encountering problems. ",
93" <LI id=causeErrorInAddress>There might be a typing error in the address. ",
94" <LI id=causeOtherError> ",
95" </LI></UL></TD></TR> ",
97" <TD id=infoBlockAlign vAlign=top align=right> </TD> ",
98" <TD id=moreInformationAlign vAlign=center align=left> ",
103" <TD vAlign=top><SPAN id=moreInfoContainer></SPAN><ID ",
104" id=moreInformation>More information</ID> ",
105" </TD></TR></TBODY></TABLE></H4> ",
106" <DIV class=infoBlock id=infoBlockID> ",
107" <P><ID id=errorExpl1>This problem can be caused by a variety of issues, ",
110" <LI id=errorExpl2>Internet connectivity has been lost. ",
111" <LI id=errorExpl3>The website is temporarily unavailable. ",
112" <LI id=errorExpl4>The Domain Name Server (DNS) is not reachable. ",
113" <LI id=errorExpl5>The Domain Name Server (DNS) does not have a listing ",
114" for the website's domain. ",
116" <P></P></DIV></TD></TR></TBODY></TABLE></BODY></HTML> ",
132 gClient->GetPicture(
"ed_open.png"));
134 gClient->GetPicture(
"ed_save.png"));
138 gClient->GetPicture(
"bld_exit.png"));
143 gClient->GetPicture(
"bld_plus.png"));
146 gClient->GetPicture(
"htmlfile.gif"));
151 gClient->GetPicture(
"ed_delete.png"));
174 fBack->
Connect(
"Clicked()",
"TGHtmlBrowser",
this,
"Back()");
192 fStop->
Connect(
"Clicked()",
"TGHtmlBrowser",
this,
"Stop()");
198 fHome->
Connect(
"Clicked()",
"TGHtmlBrowser",
this,
"Selected(=\"http://root.cern.ch\")");
206 fURL->
Connect(
"ReturnPressed()",
"TGHtmlBrowser",
this,
"URLChanged()");
213 fComboBox->
Connect(
"Selected(char *)",
"TGHtmlBrowser",
this,
"Selected(char *)");
227 Int_t partsusBar[] = {75,25};
231 fHtml->
Connect(
"MouseOver(const char *)",
"TGHtmlBrowser",
this,
"MouseOver(const char *)");
232 fHtml->
Connect(
"MouseDown(const char *)",
"TGHtmlBrowser",
this,
"MouseDown(const char *)");
262 msg +=
"User-Agent: ROOT-TWebFile/1.1";
273 ::Error(
"ReadSize",
"library compiled without SSL, https not supported");
288 if (
s->RecvRaw(buf, 4096) == -1) {
309 static char *buf = 0;
313 if (size <= 0) size = 1024*1024;
333 ::Error(
"ReadRemote",
"library compiled without SSL, https not supported");
348 buf = (
char *)
calloc(size+1,
sizeof(
char));
349 if (
s->RecvRaw(buf, size) == -1) {
380 gROOT->ProcessLine(
Form(
"TFile::Open(\"%s\");", surl.
Data()));
382 gROOT->RefreshBrowsers();
402 snprintf(imgHtml, 1000,
"<IMG src=\"%s\"> ", surl.
Data());
445 buf = (
char *)
calloc(4096,
sizeof(
char));
447 while (fgets(buf, 4096,
f)) {
526 short1 = surl(0, idx);
528 short2 = actual(0, idy);
530 if (short1 == short2) {
560 if (index < fComboBox->GetNumberOfEntries()) {
658 gClient->GetPicture(
"htmlfile.gif"));
691 if (parm1 < 1000)
break;
694 const char *shortcut = entry->
GetName();
R__EXTERN const char gHelpAbout[]
void Error(const char *location, const char *msgfmt,...)
Ssiz_t ReadSize(const char *url)
Read (open) remote files.
static const char * gHtmlFTypes[]
static char * ReadRemote(const char *url)
Read (open) remote files.
char * Form(const char *fmt,...)
R__EXTERN TSystem * gSystem
Using a TBrowser one can browse all ROOT objects.
const TGWindow * GetRoot() const
Returns current root (i.e.
virtual TGLBEntry * GetSelectedEntry() const
virtual TGTextEntry * GetTextEntry() const
virtual void AddEntry(TGString *s, Int_t id)
virtual void RemoveEntries(Int_t from_ID, Int_t to_ID)
virtual void Select(Int_t id, Bool_t emit=kTRUE)
Make the selected item visible in the combo box window and emit signals according to the second param...
virtual TGLBEntry * FindEntry(const char *s) const
Find entry by name.
virtual Int_t GetNumberOfEntries() const
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=0)
Add frame to the composite frame using the specified layout hints.
virtual void SetCleanup(Int_t mode=kLocalCleanup)
Turn on automatic cleanup of child frames in dtor.
virtual TGDimension GetDefaultSize() const
std::cout << fWidth << "x" << fHeight << std::endl;
virtual void MapSubwindows()
Map all sub windows that are part of the composite frame.
void SetIniDir(const char *inidir)
Set directory name.
virtual UInt_t GetDefaultHeight() const
virtual void Resize(UInt_t w=0, UInt_t h=0)
Resize the frame.
virtual void MapWindow()
map window
void Reload()
Handle "Reload" navigation button.
Bool_t CheckAnchors(const char *)
Check if we just change position in the page (using anchor) and return kTRUE if any anchor has been f...
void MouseOver(const char *)
Handle "MouseOver" TGHtml signal.
void Back()
Handle "Back" navigation button.
TGVerticalFrame * fVerticalFrame
void Selected(const char *txt)
Open (browse) selected URL.
void MouseDown(const char *)
Handle "MouseDown" TGHtml signal.
TGHorizontalFrame * fHorizontalFrame
TGPopupMenu * fMenuFavorites
TGPictureButton * fForward
void Forward()
Handle "Forward" navigation button.
void Stop()
Handle "Reload" navigation button.
TGHtmlBrowser(const char *filename=0, const TGWindow *p=0, UInt_t w=900, UInt_t h=600)
TGHtmlBrowser constructor.
virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t)
Process Events.
TGPictureButton * fReload
void URLChanged()
URL combobox has changed.
int GotoAnchor(const char *name)
Go to anchor position.
virtual void Clear(Option_t *="")
Erase all HTML from this widget and clear the screen.
int ParseText(char *text, const char *index=0)
Appends (or insert at the specified position) the given HTML text to the end of any HTML text that ma...
void SetBaseUri(const char *uri)
Sets base URI.
const char * GetBaseUri() const
const char * GetText() const
virtual void CloseWindow()
Close and delete main frame.
void SetWindowName(const char *name=0)
Set window name. This is typically done via the window manager.
virtual void SetText(TGString *text, Int_t partidx=0)
Set text in partition partidx in status bar.
virtual void SetParts(Int_t npart)
Divide the status bar in npart equal sized parts.
TGTextBuffer * GetBuffer() const
const char * GetText() const
virtual void SetText(const char *text, Bool_t emit=kTRUE)
Sets text entry to text, clears the selection and moves the cursor to the end of the line.
virtual const char * GetTitle() const
Returns title of object.
Bool_t Save(const char *fn)
Save text buffer to file fn.
virtual void Layout()
layout view
virtual void ScrollToPosition(TGLongPosition newPos)
Scroll the canvas to pos.
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.
static const TString & GetBinDir()
Get the binary directory in the installation. Static utility function.
void SetText(const char *helpText)
Set help text from helpText buffer in TGTextView.
void Popup()
Show help dialog.
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)
Ssiz_t Last(char c) const
Find last occurrence of a character c.
Bool_t BeginsWith(const char *s, ECaseCompare cmp=kExact) const
TString & Prepend(const char *cs)
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
Ssiz_t Index(const char *pat, Ssiz_t i=0, ECaseCompare cmp=kExact) const
virtual Int_t Exec(const char *shellcmd)
Execute a command.
virtual const char * UnixPathName(const char *unixpathname)
Convert from a local pathname to a Unix pathname.
virtual const char * BaseName(const char *pathname)
Base name of a file name. Base name of /user/root is root.
This class represents a WWW compatible URL.
const char * GetUrl(Bool_t withDeflt=kFALSE) const
Return full URL.
const char * GetFile() const
const char * GetHost() const
const char * GetProtocol() const
static constexpr double s