CefBrowser

interface CefBrowser

Interface representing a browser.

Inheritors

Functions

Link copied to clipboard
abstract fun canGoBack(): Boolean
Tests if the browser can navigate backwards.
Link copied to clipboard
abstract fun canGoForward(): Boolean
Tests if the browser can navigate forwards.
Link copied to clipboard
abstract fun close(force: Boolean)
Request that the browser close.
Link copied to clipboard
abstract fun createImmediately()
Call to immediately create the underlying browser object.
Link copied to clipboard
abstract fun createScreenshot(nativeResolution: Boolean): CompletableFuture<BufferedImage>
Captures a screenshot-like image of the currently displayed content and returns it.
Link copied to clipboard
abstract fun doClose(): Boolean
Called from CefClient.doClose.
Link copied to clipboard
abstract fun executeJavaScript(code: String, url: String, line: Int)
Execute a string of JavaScript code in this frame.
Link copied to clipboard
abstract fun find(searchText: String, forward: Boolean, matchCase: Boolean, findNext: Boolean)
Search for some kind of text on the page.
Link copied to clipboard
abstract fun getClient(): CefClient
Get the client associated with this browser.
Link copied to clipboard
abstract fun getDevTools(): CefBrowser
abstract fun getDevTools(inspectAt: Point): CefBrowser
Get an instance of the DevTools to be displayed in its own window or to be embedded within your UI.
Link copied to clipboard
Get an instance of a client that can be used to leverage the DevTools protocol.
Link copied to clipboard
abstract fun getFocusedFrame(): CefFrame
Returns the focused frame for the browser window.
Link copied to clipboard
abstract fun getFrameByIdentifier(identifier: String): CefFrame
Returns the frame with the specified identifier, or NULL if not found.
Link copied to clipboard
abstract fun getFrameByName(name: String): CefFrame
Returns the frame with the specified name, or NULL if not found.
Link copied to clipboard
abstract fun getFrameCount(): Int
Returns the number of frames that currently exist.
Link copied to clipboard
Returns the identifiers of all existing frames.
Link copied to clipboard
abstract fun getFrameNames(): Vector<String>
Returns the names of all existing frames.
Link copied to clipboard
abstract fun getIdentifier(): Int
Returns the unique browser identifier.
Link copied to clipboard
abstract fun getMainFrame(): CefFrame
Returns the main (top-level) frame for the browser window.
Link copied to clipboard
Get an implementation of CefRenderHandler if any.
Link copied to clipboard
Returns the request context for this browser.
Link copied to clipboard
abstract fun getSource(visitor: CefStringVisitor)
Retrieve this frame's HTML source as a string sent to the specified visitor.
Link copied to clipboard
abstract fun getText(visitor: CefStringVisitor)
Retrieve this frame's display text as a string sent to the specified visitor.
Link copied to clipboard
abstract fun getUIComponent(): Component
Get the underlying UI component (e.g.
Link copied to clipboard
abstract fun getURL(): String
Emits the URL currently loaded in this frame.
Link copied to clipboard
Get an implementation of CefWindowHandler if any.
Link copied to clipboard
Returns the maximum rate in frames per second (fps) that CefRenderHandler::onPaint will be called for a windowless browser.
Link copied to clipboard
abstract fun getZoomLevel(): Double
Get the current zoom level.
Link copied to clipboard
abstract fun goBack()
Go back.
Link copied to clipboard
abstract fun goForward()
Go forward.
Link copied to clipboard
abstract fun hasDocument(): Boolean
Tests if a document has been loaded in the browser.
Link copied to clipboard
abstract fun ImeCancelComposing()
Cancels the existing composition and discards the composition node contents without applying them.
Link copied to clipboard
abstract fun ImeCommitText(text: String, replacementRange: CefRange, relativeCursorPos: Int)
Completes the existing composition by optionally inserting the specified |text| into the composition node.
Link copied to clipboard
abstract fun ImeFinishComposingText(keepSelection: Boolean)
Completes the existing composition by applying the current composition node contents.
Link copied to clipboard
abstract fun ImeSetComposition(text: String, underlines: List<CefCompositionUnderline>, replacementRange: CefRange, selectionRange: CefRange)
Begins a new composition or updates the existing composition.
Link copied to clipboard
abstract fun isClosed(): Boolean
Link copied to clipboard
abstract fun isClosing(): Boolean
Link copied to clipboard
abstract fun isLoading(): Boolean
Tests if the browser is currently loading.
Link copied to clipboard
abstract fun isPopup(): Boolean
Tests if the window is a popup window.
Link copied to clipboard
abstract fun loadRequest(request: CefRequest)
Load the request represented by the request object.
Link copied to clipboard
abstract fun loadURL(url: String)
Load the specified URL in the main frame.
Link copied to clipboard
Send a notification to the browser that the screen info has changed.
Link copied to clipboard
abstract fun onBeforeClose()
Called from CefClient.onBeforeClose.
Link copied to clipboard
abstract fun print()
Print the current browser contents.
Link copied to clipboard
abstract fun printToPDF(path: String, settings: CefPdfPrintSettings, callback: CefPdfPrintCallback)
Print the current browser contents to a PDF.
Link copied to clipboard
abstract fun reload()
Reload the current page.
Link copied to clipboard
abstract fun reloadIgnoreCache()
Reload the current page ignoring any cached data.
Link copied to clipboard
abstract fun replaceMisspelling(word: String)
If a misspelled word is currently selected in an editable node calling this method will replace it with the specified |word|.
Link copied to clipboard
abstract fun runFileDialog(mode: CefDialogHandler.FileDialogMode, title: String, defaultFilePath: String, acceptFilters: Vector<String>, callback: CefRunFileDialogCallback)
Call to run a file chooser dialog.
Link copied to clipboard
abstract fun sendKeyEvent(e: KeyEvent)
Link copied to clipboard
abstract fun sendMouseEvent(e: MouseEvent)
Link copied to clipboard
Link copied to clipboard
abstract fun sendTouchEvent(e: CefTouchEvent)
Link copied to clipboard
abstract fun setCloseAllowed()
Allow the browser to close.
Link copied to clipboard
abstract fun setFocus(enable: Boolean)
Set or remove keyboard focus to/from the browser window.
Link copied to clipboard
abstract fun setWindowlessFrameRate(frameRate: Int)
Set the maximum rate in frames per second (fps) that CefRenderHandler::onPaint will be called for a windowless browser.
Link copied to clipboard
abstract fun setWindowVisibility(visible: Boolean)
Set whether the window containing the browser is visible (minimized/unminimized, app hidden/unhidden, etc).
Link copied to clipboard
abstract fun setZoomLevel(zoomLevel: Double)
Change the zoom level to the specified value.
Link copied to clipboard
abstract fun startDownload(url: String)
Download the file at url using CefDownloadHandler.
Link copied to clipboard
abstract fun stopFinding(clearSelection: Boolean)
Cancel all searches that are currently going on.
Link copied to clipboard
abstract fun stopLoad()
Stop loading the page.
Link copied to clipboard
abstract fun viewSource()
Save this frame's HTML source to a temporary file and open it in the default text viewing application.
Link copied to clipboard
abstract fun wasResized(width: Int, height: Int)