DotNetBrowser  1.14
Public Member Functions | Protected Member Functions | Properties | Events | List of all members
DotNetBrowser.WPF.WPFBrowserView Class Reference

WPF implementation of the BrowserView interface. More...

Inherits Grid, DotNetBrowser.BrowserView, DotNetBrowser.UIComponent, IBrowserWatcher, and IBrowserProperties.

Public Member Functions

 WPFBrowserView ()
 Constructs a new WPFBrowserView component based on a new browser instance. More...
 
 WPFBrowserView (Browser browser)
 Constructs a new WPFBrowserView component based on passed browser instance. More...
 
UIComponent GetComponent ()
 Returns UIComponent instance that can be embedded into application GUI. More...
 
Image GetImage ()
 Returns image representation of the currently loaded and displayed web page. More...
 
void UpdateSize (int width, int height)
 Updates size of the this view. More...
 
void SetKeyFilter (KeyFilter keyFilter)
 Configures KeyFilter for this view. More...
 
double GetDeviceScaleFactor ()
 Returns device scale factor that is used to render this view. More...
 
void Dispose ()
 Disposes current view. More...
 
BrowserView GetInnerView ()
 Gets view instance that can be embedded into application GUI. More...
 

Protected Member Functions

virtual void Dispose (bool disposing)
 Disposes current view. More...
 

Properties

bool IsDisposed [get]
 Gets true when the current view instance is disposed. More...
 
Browser Browser [get]
 Browser instance associated with the current view. More...
 
IInputSimulator InputSimulator [get]
 Returns input simulation controller instance. More...
 
IBackForwardNavigator BackForwardNavigator [get]
 Returns back-forward navigation controller instance. More...
 
bool Focused [set]
 Sets focus or unfocus to the view. Unfocus available only for BrowserType.HEAVYWEIGHT view. More...
 
new MouseWheelEventHandler PreviewMouseWheel
 Occurs when a mouse wheel is rotated while the control has focus. More...
 
BrowserType BrowserType [get, set]
 Gets or sets rendering type for browser that will use for constructs a new WPFBrowserView component based on a new browser instance. Uses for create a new browser instance only. More...
 
string URL [get, set]
 Gets or sets the current Url. More...
 
double ZoomLevel [get, set]
 Gets or sets zoom level for the currently loaded web page. Zoom level is configured for each domain separately. For example, if you load the www.a.com web page and set zoom level to 2.5, then load the www.b.org web page, the zoom level for www.b.org web page will be reset to default value. When you load the www.a.com web page again, its zoom level will be restored to 2.5 automatically. More...
 
bool AudioMuted [get, set]
 Gets or sets mutes all audio output for this Browser instance. True when audio output must be muted, false otherwise. More...
 
string AcceptLanguage [get, set]
 Gets or sets a string that represents accept language for this Browser instance and all Browser instances with the same BrowserContext. More...
 
BrowserPreferences Preferences [get, set]
 Gets or sets browser's preferences. More...
 
- Properties inherited from DotNetBrowser.BrowserView
Browser Browser [get]
 Returns Browser instance associated with the current container. More...
 
bool IsDisposed [get]
 Gets a value indicating whether the current view has been disposed of. More...
 
IInputSimulator InputSimulator [get]
 Returns input simulation controller instance. More...
 
IBackForwardNavigator BackForwardNavigator [get]
 Returns back-forward navigation controller instance. More...
 
bool Focused [set]
 Sets focus or unfocus to the current view. Unfocus available only for BrowserType.HEAVYWEIGHT view. More...
 

Events

FinishLoadingFrameHandler FinishLoadingFrameEvent
 An event that indicates that frame loading process has been finished. More...
 
StartLoadingFrameHandler StartLoadingFrameEvent
 An event that indicates that frame loading process has been started. More...
 
FailLoadingFrameHandler FailLoadingFrameEvent
 An event that indicates that frame loading process has been failed. More...
 
ProvisionalLoadingFrameHandler ProvisionalLoadingFrameEvent
 An event that indicates that provisional load for a specified frame was successfully committed. More...
 
DocumentLoadedInFrameHandler DocumentLoadedInFrameEvent
 An event that indicates that frame with a document is loaded. More...
 
DocumentLoadedInMainFrameHandler DocumentLoadedInMainFrameEvent
 An event that indicates that main frame with a document is loaded. More...
 
RenderCreatedHandler RenderCreatedEvent
 An event that indicates that the render process is gone or created. More...
 
RenderCreatedHandler RenderGoneEvent
 An event that indicates that the render process is gone. More...
 
RenderCreatedHandler RenderResponsiveEvent
 An event that indicates that the render process is no longer hung. More...
 
RenderCreatedHandler RenderUnresponsiveEvent
 An event that indicates that the render process is hung. More...
 
StatusEventHandler StatusChangedEvent
 An event that indicates that the status has been changed. More...
 
TitleChangedHandler TitleChangedEvent
 An event that indicates that the title of a document in main frame has been changed. More...
 
ConsoleMessageHandler ConsoleMessageEvent
 An event that indicates that the message was added to the console. More...
 
new DragDropHandler DragEnterEvent
 An event that indicates that the object is dragged into the browser's bounds. More...
 
DragDropHandler DragExitEvent
 An event that indicates that the object is dragged out of the browser's bounds. More...
 
DragDropHandler DropEvent
 An event that indicates when a drag-and-drop operation is completed. More...
 
GestureEventHandler GestureEvent
 An event that indicates when the gesture status has been changed. More...
 
DisposeEventHandler DisposeEvent
 An event that indicates that browser instance disposed. More...
 
ScriptContextCreatedHandler ScriptContextCreated
 An event that indicates that JavaScript context has been created. The event is invoked synchronously blocking JavaScript execution. Don't block current method execution for too long to avoid web page loading and displaying performance. More...
 
ScriptContextDestroyedHandler ScriptContextDestroyed
 An event that indicates that JavaScript context has been destroyed. The event is invoked synchronously blocking JavaScript execution. Don't block current method execution for too long to avoid web page loading and displaying performance. More...
 

Detailed Description

WPF implementation of the BrowserView interface.

Constructor & Destructor Documentation

DotNetBrowser.WPF.WPFBrowserView.WPFBrowserView ( )

Constructs a new WPFBrowserView component based on a new browser instance.

DotNetBrowser.WPF.WPFBrowserView.WPFBrowserView ( Browser  browser)

Constructs a new WPFBrowserView component based on passed browser instance.

Parameters
browserThe Browser instance associated with the current view.
Exceptions
ArgumentNullExceptionwhen browser is null.

Member Function Documentation

void DotNetBrowser.WPF.WPFBrowserView.Dispose ( )

Disposes current view.

virtual void DotNetBrowser.WPF.WPFBrowserView.Dispose ( bool  disposing)
protectedvirtual

Disposes current view.

Parameters
disposingTrue if managed resources should be disposed
UIComponent DotNetBrowser.WPF.WPFBrowserView.GetComponent ( )

Returns UIComponent instance that can be embedded into application GUI.

Returns
UIComponent instance.

Implements DotNetBrowser.BrowserView.

double DotNetBrowser.WPF.WPFBrowserView.GetDeviceScaleFactor ( )

Returns device scale factor that is used to render this view.

Returns
The device scale factor.

Implements DotNetBrowser.BrowserView.

Image DotNetBrowser.WPF.WPFBrowserView.GetImage ( )

Returns image representation of the currently loaded and displayed web page.

Returns
The System.Drawing.Image instance or null if web page is not loaded or not displayed.

Implements DotNetBrowser.BrowserView.

BrowserView DotNetBrowser.WPF.WPFBrowserView.GetInnerView ( )

Gets view instance that can be embedded into application GUI.

void DotNetBrowser.WPF.WPFBrowserView.SetKeyFilter ( KeyFilter  keyFilter)

Configures KeyFilter for this view.

Parameters
keyFilterThe KeyFilter instance.

Implements DotNetBrowser.BrowserView.

void DotNetBrowser.WPF.WPFBrowserView.UpdateSize ( int  width,
int  height 
)

Updates size of the this view.

Parameters
widthNew width in pixels.
heightNew height in pixels.

Implements DotNetBrowser.BrowserView.

Property Documentation

string DotNetBrowser.WPF.WPFBrowserView.AcceptLanguage
getset

Gets or sets a string that represents accept language for this Browser instance and all Browser instances with the same BrowserContext.

Exceptions
ArgumentNullExceptionwhen value set null.
ArgumentExceptionwhen value set empty.
bool DotNetBrowser.WPF.WPFBrowserView.AudioMuted
getset

Gets or sets mutes all audio output for this Browser instance. True when audio output must be muted, false otherwise.

IBackForwardNavigator DotNetBrowser.WPF.WPFBrowserView.BackForwardNavigator
get

Returns back-forward navigation controller instance.

Browser DotNetBrowser.WPF.WPFBrowserView.Browser
get

Browser instance associated with the current view.

BrowserType DotNetBrowser.WPF.WPFBrowserView.BrowserType
getset

Gets or sets rendering type for browser that will use for constructs a new WPFBrowserView component based on a new browser instance. Uses for create a new browser instance only.

Exceptions
InvalidOperationExceptionif the value is set when a browser instance has already been created
bool DotNetBrowser.WPF.WPFBrowserView.Focused
set

Sets focus or unfocus to the view. Unfocus available only for BrowserType.HEAVYWEIGHT view.

IInputSimulator DotNetBrowser.WPF.WPFBrowserView.InputSimulator
get

Returns input simulation controller instance.

bool DotNetBrowser.WPF.WPFBrowserView.IsDisposed
get

Gets true when the current view instance is disposed.

BrowserPreferences DotNetBrowser.WPF.WPFBrowserView.Preferences
getset

Gets or sets browser's preferences.

new MouseWheelEventHandler DotNetBrowser.WPF.WPFBrowserView.PreviewMouseWheel
addremove

Occurs when a mouse wheel is rotated while the control has focus.

string DotNetBrowser.WPF.WPFBrowserView.URL
getset

Gets or sets the current Url.

double DotNetBrowser.WPF.WPFBrowserView.ZoomLevel
getset

Gets or sets zoom level for the currently loaded web page. Zoom level is configured for each domain separately. For example, if you load the www.a.com web page and set zoom level to 2.5, then load the www.b.org web page, the zoom level for www.b.org web page will be reset to default value. When you load the www.a.com web page again, its zoom level will be restored to 2.5 automatically.

This property asynchronously.

  • To zoom in use the positive zoom level. For example, 2.0, 1.5.
  • To zoom out use the negative zoom level. For example, -1.0, -2.5.

Event Documentation

ConsoleMessageHandler DotNetBrowser.WPF.WPFBrowserView.ConsoleMessageEvent

An event that indicates that the message was added to the console.

DisposeEventHandler DotNetBrowser.WPF.WPFBrowserView.DisposeEvent

An event that indicates that browser instance disposed.

DocumentLoadedInFrameHandler DotNetBrowser.WPF.WPFBrowserView.DocumentLoadedInFrameEvent

An event that indicates that frame with a document is loaded.

DocumentLoadedInMainFrameHandler DotNetBrowser.WPF.WPFBrowserView.DocumentLoadedInMainFrameEvent

An event that indicates that main frame with a document is loaded.

new DragDropHandler DotNetBrowser.WPF.WPFBrowserView.DragEnterEvent

An event that indicates that the object is dragged into the browser's bounds.

DragDropHandler DotNetBrowser.WPF.WPFBrowserView.DragExitEvent

An event that indicates that the object is dragged out of the browser's bounds.

DragDropHandler DotNetBrowser.WPF.WPFBrowserView.DropEvent

An event that indicates when a drag-and-drop operation is completed.

FailLoadingFrameHandler DotNetBrowser.WPF.WPFBrowserView.FailLoadingFrameEvent

An event that indicates that frame loading process has been failed.

FinishLoadingFrameHandler DotNetBrowser.WPF.WPFBrowserView.FinishLoadingFrameEvent

An event that indicates that frame loading process has been finished.

GestureEventHandler DotNetBrowser.WPF.WPFBrowserView.GestureEvent

An event that indicates when the gesture status has been changed.

ProvisionalLoadingFrameHandler DotNetBrowser.WPF.WPFBrowserView.ProvisionalLoadingFrameEvent

An event that indicates that provisional load for a specified frame was successfully committed.

RenderCreatedHandler DotNetBrowser.WPF.WPFBrowserView.RenderCreatedEvent

An event that indicates that the render process is gone or created.

RenderCreatedHandler DotNetBrowser.WPF.WPFBrowserView.RenderGoneEvent

An event that indicates that the render process is gone.

RenderCreatedHandler DotNetBrowser.WPF.WPFBrowserView.RenderResponsiveEvent

An event that indicates that the render process is no longer hung.

RenderCreatedHandler DotNetBrowser.WPF.WPFBrowserView.RenderUnresponsiveEvent

An event that indicates that the render process is hung.

ScriptContextCreatedHandler DotNetBrowser.WPF.WPFBrowserView.ScriptContextCreated

An event that indicates that JavaScript context has been created. The event is invoked synchronously blocking JavaScript execution. Don't block current method execution for too long to avoid web page loading and displaying performance.

ScriptContextDestroyedHandler DotNetBrowser.WPF.WPFBrowserView.ScriptContextDestroyed

An event that indicates that JavaScript context has been destroyed. The event is invoked synchronously blocking JavaScript execution. Don't block current method execution for too long to avoid web page loading and displaying performance.

StartLoadingFrameHandler DotNetBrowser.WPF.WPFBrowserView.StartLoadingFrameEvent

An event that indicates that frame loading process has been started.

StatusEventHandler DotNetBrowser.WPF.WPFBrowserView.StatusChangedEvent

An event that indicates that the status has been changed.

TitleChangedHandler DotNetBrowser.WPF.WPFBrowserView.TitleChangedEvent

An event that indicates that the title of a document in main frame has been changed.