17#ifndef ROOT_cef_simple_app
18#define ROOT_cef_simple_app
20#include "include/cef_app.h"
33 public CefPrintHandler,
50 THttpServer *serv =
nullptr,
const std::string &url =
"",
const std::string &cont =
"",
51 int width = 0,
int height = 0,
bool headless =
false);
73 CefSize GetPdfPaperSize(CefRefPtr<CefBrowser>,
int device_units_per_inch)
override {
return CefSize(device_units_per_inch*8.25, device_units_per_inch*11.75); }
74 bool OnPrintDialog( CefRefPtr< CefBrowser > browser,
bool has_selection, CefRefPtr< CefPrintDialogCallback > callback )
override {
return false; }
75 bool OnPrintJob( CefRefPtr< CefBrowser > browser,
const CefString& document_name,
const CefString& pdf_file_path, CefRefPtr< CefPrintJobCallback > callback )
override {
return false; }
76 void OnPrintReset( CefRefPtr< CefBrowser > browser )
override {}
77 void OnPrintSettings( CefRefPtr< CefBrowser > browser, CefRefPtr< CefPrintSettings > settings,
bool get_defaults )
override {}
78 void OnPrintStart( CefRefPtr< CefBrowser > browser )
override {}
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t rect
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t height
RCefWebDisplayHandle * fNextHandle
next handle where browser will be created
CefRefPtr< CefBrowserProcessHandler > GetBrowserProcessHandler() override
std::string fFirstUrl
! first URL to open
bool fUseViewes
! is views framework used
void OnContextInitialized() override
THttpServer * fFirstServer
! first server
void StartWindow(THttpServer *serv, const std::string &url, const std::string &cont, CefRect &rect)
bool fFirstHeadless
! is first window is headless
void OnBeforeChildProcessLaunch(CefRefPtr< CefCommandLine > command_line) override
CefRect fFirstRect
! original width
void SetNextHandle(RCefWebDisplayHandle *handle)
void OnRegisterCustomSchemes(CefRawPtr< CefSchemeRegistrar > registrar) override
CefRefPtr< GuiHandler > fGuiHandler
! normal handler
std::string fFirstContent
! first page content open
DISALLOW_COPY_AND_ASSIGN(SimpleApp)
IMPLEMENT_REFCOUNTING(SimpleApp)
void OnBeforeCommandLineProcessing(const CefString &process_type, CefRefPtr< CefCommandLine > command_line) override
Online http server for arbitrary ROOT application.