mozilla

Revision 96758 of Gecko Embedding API Reference

  • Revision slug: Gecko_Embedding_API_Reference
  • Revision title: Gecko Embedding API Reference
  • Revision id: 96758
  • Created:
  • Creator: DigDug
  • Is current revision? No
  • Comment /* Public Components */

Revision Content

Introduction

The Mozilla Public API consists of a collection of services and components which are accessed via XPCOM interfaces. Mozilla's XPCOM layer consists of a component model (called XPCOM) and the infrastructure necessary to support dynamic registration, instantiation and manipulation of XPCOM components.

At the heart of XPCOM's implementation is the Service Manager and the Component Manager. Together, these two services provide a centralized point for gaining access to all of the public Mozilla interfaces.

The Service Manager exposes all of the available XPCOM services - each service represents a global object which provides some piece of functionality. The Component Manager allows new instances of registered XPCOM components to be instantiated.

Image:public-apis-image2.gif

The embedding layer consists of several components built on top of XPCOM and its services. Much of the Gecko functionality is exposed through a component called the nsWebBrowser. Embedding applications can leverage this component to easily access many of Gecko's features. Each WebBrowser instance represents the "client-area" of a typical browser window. The WebBrowser exposes a set of interfaces which allow the embedding application to control activity and respond to changes within this client area. Using these interfaces an embedding application can build up its own user interface around a WebBrowser instance.
Image:public-apis-image1.gif

Public Classes

The following utility classes are available from the XPCOM DLL. They provide some basic functionality which should be leveraged when building new XPCOM components.

These are templatized smart pointers which transparently deal with XPCOM reference counting issues. See using nsCOMPtr for more information.

  • nsString

There are a collection of string classes which support both unicode and ASCII strings. These classes provide a variety of string operations as well as dealing with the memory management issues of storing the underlying data. See the XPCOM string guide for more details.

This is an nsCOMPtr which encapsulates XPCOM weak reference support. See the Weak reference document for more information.

Public Return Codes

  • NS_SUCCEEDED
  • NS_ERROR_FAILURE
  • NS_ERROR_NOT_IMPLEMENTED

Public Functions

The following functions are available from the XPCOM DLL.

This function initializes the Gecko embedding support. This must be the first function call made into Gecko.

This function shuts down Gecko and cleans up any remaining resources... Currently, once Gecko has been shutdown, it cannot be restarted in the same process space... This should change in the future.

This helper class provides static accessors to the global nsMemory Service.

This is a helper class which converts an ASCII string into a UCS2 string. Typically, instances of this class are stack allocated, and wrap ASCII arguments which must be converted into UCS2.

  • do_QueryInterface
    This is a helper class which works in conjunction with nsCOMPtr to perform a simplified call to nsISupports::QueryInterface(...) with a typesafe assignment.
  • do_GetInterface

This function simplfies retrieving interfaces via the nsIInterfaceRequestor::GetInterface(...) method. Using this function, one can use nsISupports instances and still easily access other interfaces via nsIInterfaceRequestor. Internally, this function tries to convert the nsISupports argument into an nsIInterfaceRequestor and then calls GetInterface(...) to retrieve the requested interface.

This function is the equivilent of do_QueryInterface except that it performs the QI through a weak reference.

This function simplifies accessing services from the Service Manager.

This template helper class allows easy access to an interface's nsIID. Typically the NS_GET_IID(source) macro is used instead of using the nsCOMTypeInfo template directly.

This function creates a weak reference to a component which implements the nsIWeakReference interface.

Global Services

nsServiceManager

The Service Manager is the central repository for accessing instances of the various XPCOM services. Each service is represented by a singleton object which is instantiated the first time it is requested and remains alive until the Service Manager is shut down, or the service is explicitly unloaded.

Through the Service Manager, individual services can be loaded, unloaded and accessed.

Implemented Interfaces:
Related Interfaces:

nsMemory

The nsMemory service provides the global memory manager implementation for XPCOM. In addition to memory allocation and release, this service provides low memory notifications, called a {{mediawiki.external('nsIMemory#Remarks|memory pressure observers')}}, which are notified when memory is low - thus allowing cached resources to be freed.

All heap access should be done via the nsMemory service. To facilitate this, a set of global functions are available to access the nsMemory methods without requiring an instance of the nsMemory service (see nsMemory.h).

Contract-id:

NS_MEMORY_CONTRACTID

Implemented Interfaces:
Related Interfaces:

nsComponentManager

The nsComponentManager service is responsible for creating new instances of XPCOM components. The Component Manager is also responsible for registering and managing the class factories used for component creation...

Contract-id:
NS_COMPONENTMANAGER_CONTRACTID

Implemented Interfaces:

Requestor Interfaces:

Related Interfaces:

nsURILoader

The nsURILoader service is responsible for targeting a URI at an appropriate content handler. A content handler may be an existing or new window, a helper application or the Unknown Content Handler - if no other handler can be found for the content-type.

Contract-id: "@mozilla.org/uriloader;1" NS_URI_LOADER_CONTRACTID

Implemented Interfaces:

Related Interfaces:

nsUnknownContentTypeHandler

The UnknownContentTypeHandler service is the last resort of the URILoader when no other content handler can be located. If no registered content handlers are available, the UnknownContentTypeHandler is notified.

The default implementation of this service displays a dialog box asking the user if the content should be saved to disk...

Contract-id:
NS_IUNKNOWNCONTENTTYPEHANDLER_CONTRACTID

Implemented Interfaces:

HelperApp Launch Dialog

Contract-id:
NS_EXTERNALHELPERAPPSERVICE_CONTRACTID

Implemented Interfaces:

Preferences Service

The Preferences service provides access to persistent data stored within a user's profile directory.

Contract-id:
NS_PREF_CONTRACTID

Implemented Interfaces:

Related Interfaces:

Profile Manager Service

Contract-id:

Implemented Interfaces:

Document Loader Service (WebProgress)

Eventually, this service will be replaced by theWebProgress service...

Contract-id:

NS_DOCUMENT_LOADER_SERVICE_CONTRACTID

Implemented Interfaces:

Related Interfaces:

Public Components

nsWebBrowser

The nsWebBrowser is the main embedding component which Gecko exposes. Conceptually, each nsWebBrowser instance represents a HTML content area.

Conceptually, for each document being rendered, Gecko creates a container called a DOMWindow. Each WebBrowser exposes a tree of DOMWindows - representing the frame hierarchy for the current document. As such, access to individual document frames is done via the DOMWindow interfaces. Manipulation of the entire document structure is done via the various WebBrowser interfaces.

Contract-id: NS_WEBBROWSER_CONTRACTID

Implemented Interfaces:

Requestor Interfaces:

Related Interfaces:

Overview:

Most of Gecko's functionality is exposed through the nsWebBrowser component. The WebBrowser provides a simple mechanism for other applications to leverage Gecko functionality. Each instance of a WebBrowser encapsulates a full featured HTML content area.

The embedding application receives notifications from Gecko through a set of callback interfaces it may choose to implement.

Image:public-apis-image3.gif

Below is a code snippet which an embedding application can use to create and initialize a WebBrowser:


            nsresult rv;
            nsCOMPtr<nsIBaseWindow> baseWindow;
            nsCOMPtr<nsIWebBrowser> webBrowser;

            // Create a nsWebBrowser instance...

            webBrowser = do_CreateInstance(NS_WEBBROWSER_CONTRACTID, &rv);
            if (NS_FAILED(rv)) return rv;

            // Give the WebBrowser a pointer to the embedding component which
            // implements the callback interfaces. Replace 'this' with
            // an appropriate object...
            rv = webBrowser->SetContainerWindow((nsIWebBrowserChrome*)this);
            if (NS_FAILED(rv)) return rv;
            baseWindow = do_QueryInterface(webBrowser);

            // Initialize the WebBrowser with a native parent window
            // (ie. HWND on Win32). Replace 'nativeWindow' with a

            // reference to an appropriate native resource...
            rv = baseWindow->InitWindow(nativeWindow, // Native
            window
            nsnull, // Always nsnull.
            x, y, cx, cy); // Initial dimensions...
            if (NS_FAILED(rv)) return rv;

            // Create the child window for the WebBrowser.
            rv = baseWindow->Create();
            if (NS_FAILED(rv)) return rv;

            // At this point webBrowser contains the new initialized instance
            // of the nsWebBrowser component...
            // Save webBrowser before it goes out of scope :-)

Web Navigation

The nsIWebNavigation interface is used to load URIs into the WebBrowser and provide access to session history capabilities - such as back and forward.

Clipboard

The WebBrowser exposes access to the system clipboard via the nsIClipboardCommands interface. This interface supports cut/copy/paste operations on the current selection within the WebBrowser window.

Printing (not yet implemented)

Printing the contents of a DOMWindow within a WebBrowser is a two step process. First, the printer and page options are collected via the nsIPrintOptions interface. On most platforms this involves displaying a native Print dialog box. Once all of the options have been set, the nsIWebBrowserPrint interface is used to print the contents of the desired DOMWindow.

Searching

Searching within a nsWebBrowser is controlled via the nsIWebBrowserFind interface. The search is always performed within the DOMWindow which currently has the focus.

Focus Management

Focus managment within the WebBrowser is accessed via the nsIWebBrowserFocus interface.

This interface serves two purposes. First, it provides methods for the embedding application to notify a WebBrowser of activation/deactivation and to control tabbing order... This interface also allows access to the currently focused DOMWindow and DOMElement.

Context Menu notifications

Right-click context menu notifications are passed up to the embedding application through the nsIContextMenuListener interface. These notifications allow the embedding application to display context menus based on user activity within the WebBrowser (such as a right-click on a hypertext link).

Saving Documents

Notification Interfaces which the embedding application should implement

nsFile

Public Interfaces

nsISupports

Base Component Object Model interface. This interface provides runtime interface discovery and a reference counted memory model fashioned after the Microsoft COM IUnknown interface. More...

Interface status... none

Interface definition: nsISupportsUtils.h

nsIInterfaceRequestor

This Interface provides an interface discovery mechanism which does not imply aggregation. More...

Interface status... none

Interface definition: nsIInterfaceRequestor.idl

nsIWeakReference

This interface is used to retern a proxy reference to a component. More...

Interface status... being reviewed

Interface definition: nsIWeakReference.idl

nsISimpleEmunerator

This interface provides a simple enumeration abstraction. More...

Interface status... being reviewed

Interface definition: nsISimpleEnumerator.idl

nsIServiceManager

This interface allows access to global services within mozilla. More...

Interface status... none

Interface definition: nsIServiceManager.h

nsIShutdownListener

This interface is used to receive notifications when the Service Manager is being shutdown. More...

Interface status... none

Interface definition: nsIServiceManager.h

nsIComponentManager

This interface allows new instances of registered XPCOM components to be instantiated. More...

Interface status... none

Interface definition: nsIComponentManager.idl

nsIFactory

This interface is used by the Component Manager to create new instances of a particular XPCOM component. Each component must provide a factory implementation for creating new instances. More...

Interface status... none

Interface definition: nsIFactory.idl

nsIMemory

This interface provides access to the global memory management functionality.More...

Interface status: being reviewed

Interface definition: nsIMemory.idl

nsIDOMWindow

This interface is used to represent the window containing a specific document. More...

Interface status... being reviewed

Interface definition: nsIDOMWindow.idl

nsIBaseWindow

This interface provides access to various window operations. More...

Interface status... being reviewed

Interface definition: nsIBaseWindow.idl

nsIRequest

This interface provides a means to control various operations. More...

Interface status... being reviewed

Interface definition: nsIRequest.idl

nsIWebBrowser

This is the primary interface to the WebBrowser component More...

Interface status... being reviewed

Interface definition: nsIWebBrowser.idl

nsIWebBrowserSetup

This interface is used to enable or disable various capabilities of a nsWebBrowser instance. More...

Interface status... being reviewed

Interface definition: nsIWebBrowserSetup.idl

nsIWebBrowserChrome

This interface provides access to the window containing an nsWebBrowser instance. More...

Interface status... being reviewed

Interface definition: nsIWebBrowserChrome.idl

nsIWebNavigation

This interface exposes the web navigation functionality of the nsWebBrowser component. More...

Interface status... being reviewed

Interface definition: nsIWebNavigation.idl

nsIWebBrowserPersist

This interface exposes the save-as functionality of the nsWebBrowser component. More...

Interface status... being reviewed

Interface definition: nsIWebBrowserPersist.idl

nsIWebBrowserPrint

This interface allows printing of individual (or a collection of) DOM Windows within a nsWebBrowser component. More...

Interface status: being reviewed

Interfaced definition: nsIWebBrowserPrint.idl

nsIWebBrowserFind

This interface exposes the searching capabilities of the nsWebBrowser component. More...

Interface status: none

Interface definition: nsIWebBrowserFind.idl

nsIWebBrowserFocus

This interface provides access to the focus information of a nsWebBrowser instance. More...

Interface status: being reviewed

Interface definition: nsIWebBrowserFocus.idl

nsIWebProgress

More...

Interface status...

Interface definition:

nsIWebProgressListener

More...

Interface status...

Interface definition:

nsIPrompt

More...

Interface status...

Interface definition:

nsIPrefs

More...

Interface status...

Interface definition:

nsIProfile

More...

Interface status...

Interface definition:

nsIDirectoryServiceProvider

More...

Interface status...

Interface definition:

nsILocalFile

More...

Interface status...

Interface definition:

nsIFile

More...

Interface status...

Interface definition:

nsIClipboardCommands

More...

Interface status...

Interface definition:

nsISelection

More...

Interface status...

Interface definition:

nsIURILoader

More...

Interface status...

Interface definition:

nsIURIContentListener

More...

Interface status...

Interface definition:

Defining New XPCOM Components


Original Document Information

  • Author(s): Rick Potts
  • Last Updated Date: May 07, 2001
  • Copyright Information: Creative Commons license

Revision Source

<p>
</p>
<h2 name="Introduction"> Introduction </h2>
<p>The Mozilla Public API consists of a collection of services and components which are accessed via XPCOM interfaces. Mozilla's XPCOM layer consists of a component model (called XPCOM) and the infrastructure necessary to support dynamic registration, instantiation and manipulation of XPCOM components.
</p><p>At the heart of XPCOM's implementation is the Service Manager and the Component Manager. Together, these two services provide a centralized point for gaining access to all of the public Mozilla interfaces.
</p><p>The Service Manager exposes all of the available XPCOM services - each service represents a global object which provides some piece of functionality. The Component Manager allows new instances of registered XPCOM components to be instantiated.
</p><p><img alt="Image:public-apis-image2.gif" src="File:en/Media_Gallery/Public-apis-image2.gif">
</p><p>The embedding layer consists of several components built on top of XPCOM and its services. Much of the Gecko functionality is exposed through a component called the nsWebBrowser. Embedding applications can leverage this component to easily access many of Gecko's features. Each WebBrowser instance represents the "client-area" of a typical browser window. The WebBrowser exposes a set of interfaces which allow the embedding application to control activity and respond to changes within this client area. Using these interfaces an embedding application can build up its own user interface around a WebBrowser instance.<br><img alt="Image:public-apis-image1.gif" src="File:en/Media_Gallery/Public-apis-image1.gif">
</p>
<h3 name="Public_Classes"> Public Classes </h3>
<p>The following utility classes are available from the XPCOM DLL. They provide some basic functionality which should be leveraged when building new XPCOM components.
</p>
<ul><li> <code><a href="en/NsCOMPtr">nsCOMPtr</a></code>
</li></ul>
<p>These are templatized <i>smart pointers</i> which transparently deal with XPCOM reference counting issues. See <a href="en/Using_nsCOMPtr">using nsCOMPtr</a> for more information.
</p>
<ul><li> <code>nsString</code>
</li></ul>
<p>There are a collection of string classes which support both unicode and ASCII strings. These classes provide a variety of string operations as well as dealing with the memory management issues of storing the underlying data. See the <a href="en/XPCOM_string_guide">XPCOM string guide</a> for more details.
</p>
<ul><li> <code><a href="en/Weak_reference">nsWeakPtr</a></code>
</li></ul>
<p>This is an nsCOMPtr which encapsulates XPCOM weak reference support. See the <a href="en/Weak_reference">Weak reference</a> document for more information.
</p>
<h3 name="Public_Return_Codes"> Public Return Codes </h3>
<ul><li> <code>NS_SUCCEEDED</code>
</li><li> <code>NS_ERROR_FAILURE</code>
</li><li> <code>NS_ERROR_NOT_IMPLEMENTED</code>
</li></ul>
<h3 name="Public_Functions"> Public Functions </h3>
<p>The following functions are available from the XPCOM DLL.
</p>
<ul><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi2.html#1099700">NS_InitEmbedding</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/base/nsEmbedAPI.h#40">(source)</a></code>
</li></ul>
<p>This function initializes the Gecko embedding support. This must be the first function call made into Gecko.
</p>
<ul><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi2.html#1101115">NS_TermEmbedding</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/base/nsEmbedAPI.h#47">(source)</a></code>
</li></ul>
<p>This function shuts down Gecko and cleans up any remaining resources... Currently, once Gecko has been shutdown, it cannot be restarted in the same process space... This should change in the future.
</p>
<ul><li> <code><a href="en/NsMemory">nsMemory</a></code>
<ul><li> <code><a href="en/NsMemory/Alloc">nsMemory::Alloc</a></code>
</li><li> <code><a href="en/NsMemory/Realloc">nsMemory::Realloc</a></code>
</li><li> <code><a href="en/NsMemory/Free">nsMemory::Free</a></code>
</li></ul>
</li></ul>
<p>This helper class provides static accessors to the global nsMemory Service.
</p>
<ul><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsComponentManagerUtils.h#63">NS_GetGlobalComponentManager</a></code><br> This function returns an instance of the Component Manager service.
</li><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/ds/nsString2.h#626">NS_ConvertASCIItoUCS2</a></code>
</li></ul>
<p>This is a helper class which converts an ASCII string into a UCS2 string. Typically, instances of this class are stack allocated, and wrap ASCII arguments which must be converted into UCS2.
</p>
<ul><li> <code><a class="external" href="http://www.mozilla.org/projects/xpcom/nsCOMPtr.html#quad2">do_QueryInterface</a></code><br> This is a helper class which works in conjunction with nsCOMPtr to perform a simplified call to <code>nsISupports::QueryInterface(...)</code> with a typesafe assignment.
</li><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIInterfaceRequestor.idl#77">do_GetInterface</a></code>
</li></ul>
<p>This function simplfies retrieving interfaces via the <code>nsIInterfaceRequestor::GetInterface(...)</code> method. Using this function, one can use nsISupports instances and still easily access other interfaces via nsIInterfaceRequestor.
Internally, this function tries to convert the nsISupports argument into an nsIInterfaceRequestor and then calls <code>GetInterface(...)</code> to retrieve the requested interface.
</p>
<ul><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIWeakReference.idl#134">do_QueryReferent</a></code>
</li></ul>
<p>This function is the equivilent of <code>do_QueryInterface</code> except that it performs the QI through a weak reference.
</p>
<ul><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIServiceManager.h#243">do_GetService</a></code>
</li></ul>
<p>This function simplifies accessing services from the Service Manager.
</p>
<ul><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsComponentManagerUtils.h#240">do_CreateInstance</a></code><br> This function simplifies creating new component instances.
</li><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsISupportsUtils.h#1222">nsCOMTypeInfo&lt;<i>interface-type</i>&gt;::GetIID()</a></code>
</li></ul>
<p>This template helper class allows easy access to an interface's nsIID. Typically the <code><a href="en/Implementing_QueryInterface#The_NS_GET_IID_macro">NS_GET_IID</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsISupportsUtils.h#1230">(source)</a></code> macro is used instead of using the <code>nsCOMTypeInfo</code> template directly.
</p>
<ul><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIWeakReference.idl#88">NS_GetWeakReference</a></code>
</li></ul>
<p>This function creates a weak reference to a component which implements the nsIWeakReference interface.
</p>
<h3 name="Global_Services"> Global Services </h3>
<h4 name="nsServiceManager"> nsServiceManager </h4>
<p>The Service Manager is the central repository for accessing instances of the various XPCOM services. Each service is represented by a singleton object which is instantiated the first time it is requested and remains alive until the Service Manager is shut down, or the service is explicitly unloaded.
</p><p>Through the Service Manager, individual services can be loaded, unloaded and accessed.
</p>
<h5 name="Implemented_Interfaces:"> Implemented Interfaces: </h5>
<ul><li> <code><a href="en/NsIServiceManager">nsIServiceManager</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIServiceManager.h">(source)</a></code>
</li></ul>
<h5 name="Related_Interfaces:"> Related Interfaces: </h5>
<ul><li> <code><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIServiceManager.h#158">nsIShutdownListener</a></code>
</li></ul>
<h4 name="nsMemory"> nsMemory </h4>
<p>The nsMemory service provides the global memory manager implementation for XPCOM. In addition to memory allocation and release, this service provides low memory notifications, called a {{mediawiki.external('nsIMemory#Remarks|memory pressure observers')}}, which are notified when memory is <i>low</i> - thus allowing cached resources to be freed.
</p><p>All heap access should be done via the nsMemory service. To facilitate this, a set of global functions are available to access the nsMemory methods without requiring an instance of the nsMemory service (see <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsMemory.h">nsMemory.h</a>).
</p>
<h5 name="Contract-id:"> Contract-id: </h5>
<p><code>NS_MEMORY_CONTRACTID</code>
</p>
<h5 name="Implemented_Interfaces:_2"> Implemented Interfaces: </h5>
<ul><li> <code><a href="en/NsIMemory">nsIMemory</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIMemory.idl">(source)</a></code>
</li></ul>
<h5 name="Related_Interfaces:_2"> Related Interfaces: </h5>
<ul><li> <code><a href="en/NsIObserver">nsIObserver</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/ds/nsIObserver.idl">(source)</a></code>
</li></ul>
<h4 name="nsComponentManager"> nsComponentManager </h4>
<p>The nsComponentManager service is responsible for creating new instances of XPCOM components. The Component Manager is also responsible for registering and managing the class factories used for component creation...
</p><p><i><b>Contract-id:</b></i><br><code>NS_COMPONENTMANAGER_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIComponentManager">nsIComponentManager</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIComponentManager.idl">(source)</a></code>
</li><li> <code><a href="en/NsIInterfaceRequestor">nsIInterfaceRequestor</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIInterfaceRequestor.idl">)(source)</a></code>
</li></ul>
<p><i><b>Requestor Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIServiceManager">nsIServiceManager</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIServiceManager.h">(source)</a></code>
</li></ul>
<p><i><b>Related Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIFactory">nsIFactory</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIFactory.idl">(source)</a></code>
</li></ul>
<h4 name="nsURILoader"> nsURILoader </h4>
<p>The nsURILoader service is responsible for targeting a URI at an appropriate content handler. A content handler may be an existing or new window, a helper application or the Unknown Content Handler - if no other handler can be found for the content-type.
</p><p><i><b>Contract-id:</b></i>
<code>"@mozilla.org/uriloader;1"</code> <code>NS_URI_LOADER_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIURILoader">nsIURILoader</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/uriloader/base/nsIURILoader.idl">(source)</a></code>
</li></ul>
<p><i><b>Related Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIURIContentListener">nsIURIContentListener</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/uriloader/base/nsIURIContentListener.idl">(source)</a></code>
</li></ul>
<h4 name="nsUnknownContentTypeHandler"> nsUnknownContentTypeHandler </h4>
<p>The UnknownContentTypeHandler service is the <i>last resort</i> of the URILoader when no other content handler can be located. If no registered content handlers are available, the UnknownContentTypeHandler is notified.
</p><p>The default implementation of this service displays a dialog box asking the user if the content should be saved to disk...
</p><p><i><b>Contract-id:</b></i><br><code>NS_IUNKNOWNCONTENTTYPEHANDLER_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIUnkContentTypehandler">nsIUnkContentTypehandler</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpfe/components/ucth/public/nsIUnkContentTypeHandler.idl">(source)</a></code>
</li></ul>
<h4 name="HelperApp_Launch_Dialog"> HelperApp Launch Dialog </h4>
<p><i><b>Contract-id:</b></i><br><code>NS_EXTERNALHELPERAPPSERVICE_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIExternalHelperAppService">nsIExternalHelperAppService</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/uriloader/exthandler/nsIExternalHelperAppService.idl">(source)</a></code>
</li></ul>
<h4 name="Preferences_Service"> Preferences Service </h4>
<p>The Preferences service provides access to persistent data stored within a user's profile directory.
</p><p><i><b>Contract-id:</b></i><br><code>NS_PREF_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIPrefService">nsIPrefService</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/modules/libpref/public/nsIPrefService.idl">(source)</a></code>
</li><li> <code><a href="en/NsIPrefBranch">nsIPrefBranch</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/modules/libpref/public/nsIPrefBranch.idl">(source)</a></code>
</li></ul>
<p><i><b>Related Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIPrefListener">nsIPrefListener</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/modules/libpref/public/nsIPrefListener.idl">(source)</a></code>
</li></ul>
<h4 name="Profile_Manager_Service"> Profile Manager Service </h4>
<p><i><b>Contract-id:</b></i>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<h4 name="Document_Loader_Service_.28WebProgress.29"> Document Loader Service (WebProgress) </h4>
<p>Eventually, this service will be replaced by theWebProgress service...
</p><p><i><b>Contract-id:</b></i>
</p><p><code>NS_DOCUMENT_LOADER_SERVICE_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIWebProgress">nsIWebProgress</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/uriloader/base/nsIWebProgress.idl">(source)</a></code>
</li><li> <code><a href="en/NsIDocumentLoader">nsIDocumentLoader</a><a class="external" href="http://mxr.mozilla.org/seamonkey/source/uriloader/base/nsIDocumentLoader.idl">(source)</a></code>
</li></ul>
<p><i><b>Related Interfaces:</b></i>
</p>
<ul><li> <code><a href="en/NsIWebProgressListener">nsIWebProgressListener</a><a class="external" href="http://lxr.mozilla.org/seamonkey/source/uriloader/base/nsIWebProgressListener.idl">(source)</a></code>
</li></ul>
<h3 name="Public_Components"> Public Components </h3>
<h4 name="nsWebBrowser"> nsWebBrowser </h4>
<p>The nsWebBrowser is the main embedding component which Gecko exposes. Conceptually, each nsWebBrowser instance represents a HTML content area.
</p><p>Conceptually, for each document being rendered, Gecko creates a container called a <i>DOMWindow</i>. Each WebBrowser exposes a tree of DOMWindows - representing the frame hierarchy for the current document. As such, access to individual document frames is done via the DOMWindow interfaces. Manipulation of the entire document structure is done via the various WebBrowser interfaces.
</p><p><i><b>Contract-id:</b></i> <code>NS_WEBBROWSER_CONTRACTID</code>
</p><p><i><b>Implemented Interfaces:</b></i>
</p>
<ul><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi4.html">nsIWebBrowser</a></code>
</li><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIWebNavigation.html">nsIWebNavigation</a></code>
</li><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi10.html">nsIWebBrowserSetup</a></code>
</li><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIWebBrowserPersist.html">nsIWebBrowserPersist</a></code>
</li><li> <code><a class="external" href="http://mozilla.org/projects/embedding/embedapiref/embedapi14.html">nsIWebBrowserFind</a></code>
</li><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi9.html#1148946">nsIWebBrowserPrint</a></code>
</li><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi8.html#1148903">nsIWebBrowserFocus</a></code>
</li><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIBaseWindow.html">nsIBaseWindow</a></code>
</li></ul>
<p><i><b>Requestor Interfaces:</b></i>
</p>
<ul><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIDOMWindow.html">nsIDOMWindow</a></code>
</li><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIDOMDocument.html">nsIDOMDocument</a></code>
</li><li> <code><a href="en/NsIWebProgress">nsIWebProgress</a></code>
</li><li> <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi20.html#1034036">nsIClipboardCommands</a></code>
</li><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIPrompt.html">nsIPrompt</a></code>
</li></ul>
<p><i><b>Related Interfaces:</b></i>
</p>
<ul><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIPrompt.html">nsIPrompt</a></code>
</li><li> <code><a class="external" href="http://mozilla.org/projects/embedding/embedapiref/embedapi6.html">nsIWebBrowserChrome</a></code>
</li><li> <code><a href="en/NsIWebBrowserSiteWindow">nsIWebBrowserSiteWindow</a></code>
</li><li> <code><a href="en/NsIWebProgressListener">nsIWebProgressListener</a></code>
</li><li> <code><a class="external" href="http://mozilla.org/projects/embedding/embedapiref/embedapi5.html">nsIContextMenuListener</a></code>
</li><li> <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIPrintOptions.html">nsIPrintOptions</a></code>
</li></ul>
<p><b>Overview:</b>
</p><p>Most of Gecko's functionality is exposed through the nsWebBrowser component. The WebBrowser provides a simple mechanism for other applications to leverage Gecko functionality. Each instance of a WebBrowser encapsulates a full featured HTML content area.
</p><p>The embedding application receives notifications from Gecko through a set of callback interfaces it may choose to implement.
</p><p><img alt="Image:public-apis-image3.gif" src="File:en/Media_Gallery/Public-apis-image3.gif">
</p><p>Below is a code snippet which an embedding application can use to create and initialize a WebBrowser:
</p><p><br> 
</p>
<pre class="eval">            nsresult rv;
            nsCOMPtr&lt;nsIBaseWindow&gt; baseWindow;
            nsCOMPtr&lt;nsIWebBrowser&gt; webBrowser;

            <span class="remark">// Create a nsWebBrowser instance...</span>

            webBrowser = do_CreateInstance(NS_WEBBROWSER_CONTRACTID, &amp;rv);
            if (NS_FAILED(rv)) return rv;

            <span class="remark">// Give the WebBrowser a pointer to the embedding component which</span>
            <span class="remark">// implements the callback interfaces. Replace 'this' with</span>
            <span class="remark">// an appropriate object...</span>
            rv = webBrowser-&gt;SetContainerWindow((nsIWebBrowserChrome*)this);
            if (NS_FAILED(rv)) return rv;
            baseWindow = do_QueryInterface(webBrowser);

            <span class="remark">// Initialize the WebBrowser with a native parent window</span>
            <span class="remark">// (ie. HWND on Win32). Replace 'nativeWindow' with a</span>

            <span class="remark">// reference to an appropriate native resource...</span>
            rv = baseWindow-&gt;InitWindow(nativeWindow, // Native
            window
            nsnull, // Always nsnull.
            x, y, cx, cy); // Initial dimensions...
            if (NS_FAILED(rv)) return rv;

            <span class="remark">// Create the child window for the WebBrowser.</span>
            rv = baseWindow-&gt;Create();
            if (NS_FAILED(rv)) return rv;

            <span class="remark">// At this point webBrowser contains the new initialized instance</span>
            <span class="remark">// of the nsWebBrowser component...</span>
            <span class="remark">// Save webBrowser before it goes out of scope :-)</span>

</pre>
<p><b>Web Navigation</b>
</p><p>The <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIWebNavigation.html">nsIWebNavigation</a></code> interface is used to load URIs into the WebBrowser and provide access to session history capabilities - such as back and forward.
</p><p><b>Clipboard</b>
</p><p>The WebBrowser exposes access to the system clipboard via the <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi20.html#1034036">nsIClipboardCommands</a></code> interface. This interface supports cut/copy/paste operations on the current selection within the WebBrowser window.
</p><p><b>Printing</b> <i>(not yet implemented)</i>
</p><p>Printing the contents of a DOMWindow within a WebBrowser is a two step process. First, the printer and page options are collected via the <code><a class="external" href="http://www.xulplanet.com/references/xpcomref/ifaces/nsIPrintOptions.html">nsIPrintOptions</a></code> interface. On most platforms this involves displaying a native Print dialog box. Once all of the options have been set, the <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi9.html#1148946">nsIWebBrowserPrint</a></code> interface is used to print the contents of the desired DOMWindow.
</p><p><b>Searching</b>
</p><p>Searching within a nsWebBrowser is controlled via the <code><a class="external" href="http://mozilla.org/projects/embedding/embedapiref/embedapi14.html">nsIWebBrowserFind</a></code> interface. The search is always performed within the DOMWindow which currently has the focus.
</p><p><b>Focus Management</b>
</p><p>Focus managment within the WebBrowser is accessed via the <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi8.html#1148903">nsIWebBrowserFocus</a></code> interface.
</p><p>This interface serves two purposes. First, it provides methods for the embedding application to notify a WebBrowser of activation/deactivation and to control tabbing order... This interface also allows access to the currently focused DOMWindow and DOMElement.
</p><p><b>Context Menu notifications</b>
</p><p>Right-click context menu notifications are passed up to the embedding application through the <code><a class="external" href="http://www.mozilla.org/projects/embedding/embedapiref/embedapi5.html#1033710">nsIContextMenuListener</a></code> interface. These notifications allow the embedding application to display context menus based on user activity within the WebBrowser (such as a right-click on a hypertext link).
</p><p><b>Saving Documents</b>
</p><p><b>Notification Interfaces which the embedding application should implement</b>
</p>
<h4 name="nsFile"> nsFile </h4>
<h3 name="Public_Interfaces"> Public Interfaces </h3>
<h4 name="nsISupports"> nsISupports </h4>
<p>Base Component Object Model interface. This interface provides runtime interface discovery and a reference counted memory model fashioned after the Microsoft COM IUnknown interface. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsISupports.html">More...</a></b>
</p><p><b>Interface status...</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsISupportsUtils.h#92">nsISupportsUtils.h</a>
</p>
<h4 name="nsIInterfaceRequestor"> nsIInterfaceRequestor </h4>
<p>This Interface provides an interface discovery mechanism which does not imply aggregation. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIInterfaceRequestor.html">More...</a></b>
</p><p><b>Interface status...</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIInterfaceRequestor.idl">nsIInterfaceRequestor.idl</a>
</p>
<h4 name="nsIWeakReference"> nsIWeakReference </h4>
<p>This interface is used to retern a proxy reference to a component. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIWeakReference.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWeakReference">being reviewed</a>
</p><p>In<b>terface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIWeakReference.idl">nsIWeakReference.idl</a>
</p>
<h4 name="nsISimpleEmunerator"> nsISimpleEmunerator </h4>
<p>This interface provides a simple enumeration abstraction. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsISimpleEnumerator.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsISimpleEnumerator">being reviewed</a>
</p><p><b>Interface definition:</b> nsISimpleEnumerator.idl
</p>
<h4 name="nsIServiceManager"> nsIServiceManager </h4>
<p>This interface allows access to global services within mozilla. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIServiceManager.html">More...</a></b>
</p><p><b>Interface status...</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIServiceManager.h">nsIServiceManager.h</a>
</p>
<h4 name="nsIShutdownListener"> nsIShutdownListener </h4>
<p>This interface is used to receive notifications when the Service Manager is being shutdown. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIShutdownListener.html">More...</a></b>
</p><p><b>Interface status...</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIServiceManager.h#150">nsIServiceManager.h</a>
</p>
<h4 name="nsIComponentManager"> nsIComponentManager </h4>
<p>This interface allows new instances of registered XPCOM components to be instantiated. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIComponentManager.html">More...</a></b>
</p><p><b>Interface status...</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIComponentManager.idl">nsIComponentManager.idl</a><br><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIComponentManager.idl">
</a></p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIComponentManager.idl">
<h4 name="nsIFactory"> nsIFactory </h4>
</a><p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIComponentManager.idl">This interface is used by the Component Manager to create new instances of a particular XPCOM component. Each component must provide a factory implementation for creating new instances. <b></b></a><b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIFactory.html">More...</a></b>
</p><p><b>Interface status...</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIFactory.idl">nsIFactory.idl</a><br><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIFactory.idl">
</a></p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIFactory.idl">
<h4 name="nsIMemory"> nsIMemory </h4>
</a><p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/components/nsIFactory.idl">This interface provides access to the global memory management functionality.<b></b></a><b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/xpcom/dox/class_nsIMemory.html">More...</a></b>
</p><p><b>Interface status:</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIMemory">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/xpcom/base/nsIMemory.idl">nsIMemory.idl</a>
</p>
<h4 name="nsIDOMWindow"> nsIDOMWindow </h4>
<p>This interface is used to represent the window containing a specific document. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/dom/dox/class_nsIDOMWindow.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIDOMWindow">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/dom/public/idl/base/nsIDOMWindow.idl">nsIDOMWindow.idl</a><br><a class="external" href="http://lxr.mozilla.org/seamonkey/source/dom/public/idl/base/nsIDOMWindow.idl">
</a></p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/dom/public/idl/base/nsIDOMWindow.idl">
<h4 name="nsIBaseWindow"> nsIBaseWindow </h4>
</a><p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/dom/public/idl/base/nsIDOMWindow.idl">This interface provides access to various window operations. <b></b></a><b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/widget/dox/class_nsIBaseWindow.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIBaseWindow">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/widget/public/nsIBaseWindow.idl">nsIBaseWindow.idl</a>
</p>
<h4 name="nsIRequest"> nsIRequest </h4>
<p>This interface provides a means to control various operations. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/netwerk/dox/class_nsIRequest.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIRequest">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/netwerk/base/public/nsIRequest.idl">nsIRequest.idl</a>
</p>
<h4 name="nsIWebBrowser"> nsIWebBrowser </h4>
<p>This is the primary interface to the WebBrowser component <b>More...</b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebBrowser">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowser.idl">nsIWebBrowser.idl</a>
</p>
<h4 name="nsIWebBrowserSetup"> nsIWebBrowserSetup </h4>
<p>This interface is used to enable or disable various capabilities of a nsWebBrowser instance. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/embedding/dox/class_nsIWebBrowserSetup.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebBrowserSetup">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserSetup.idl">nsIWebBrowserSetup.idl</a>
</p>
<h4 name="nsIWebBrowserChrome"> nsIWebBrowserChrome </h4>
<p>This interface provides access to the window containing an nsWebBrowser instance. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/embedding/dox/class_nsIWebBrowserChrome.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebBrowserChrome">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserChrome.idl">nsIWebBrowserChrome.idl</a>
</p>
<h4 name="nsIWebNavigation"> nsIWebNavigation </h4>
<p>This interface exposes the web navigation functionality of the nsWebBrowser component. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/docshell/dox/class_nsIWebNavigation.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebNavigation">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/docshell/base/nsIWebNavigation.idl">nsIWebNavigation.idl</a>
</p>
<h4 name="nsIWebBrowserPersist"> nsIWebBrowserPersist </h4>
<p>This interface exposes the save-as functionality of the nsWebBrowser component. <b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/embedding/dox/class_nsIWebBrowserPersist.html">More...</a></b>
</p><p><b>Interface status...</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebBrowserPersist">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPersist.idl">nsIWebBrowserPersist.idl</a><br><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPersist.idl">
</a></p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPersist.idl">
<h4 name="nsIWebBrowserPrint"> nsIWebBrowserPrint </h4>
</a><p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPersist.idl">This interface allows printing of individual (or a collection of) DOM Windows within a nsWebBrowser component. <b></b></a><b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/embedding/dox/class_nsIWebBrowserPrint.html">More...</a></b>
</p><p><b>Interface status:</b> <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebBrowserPrint">being reviewed</a>
</p><p><b>Interfaced definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPrint.idl">nsIWebBrowserPrint.idl</a><br><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPrint.idl">
</a></p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPrint.idl">
<h4 name="nsIWebBrowserFind"> nsIWebBrowserFind </h4>
</a><p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserPrint.idl">This interface exposes the searching capabilities of the nsWebBrowser component. <b></b></a><b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/embedding/dox/class_nsIWebBrowserFind.html">More...</a></b>
</p><p><b>Interface status:</b> none
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserFind.idl">nsIWebBrowserFind.idl</a><br><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserFind.idl">
</a></p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserFind.idl">
<h4 name="nsIWebBrowserFocus"> nsIWebBrowserFocus </h4>
</a><p><a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserFind.idl">This interface provides access to the focus information of a nsWebBrowser instance. <b></b></a><b><a class="external" href="http://unstable.elemental.com/mozilla/build/latest/mozilla/embedding/dox/class_nsIWebBrowserFocus.html">More...</a></b>
</p><p>Interface status: <a class="external" href="http://www.mozilla.org/projects/embedding/apiReviewNotes.html#nsIWebBrowserFocus">being reviewed</a>
</p><p><b>Interface definition:</b> <a class="external" href="http://lxr.mozilla.org/seamonkey/source/embedding/browser/webBrowser/nsIWebBrowserFocus.idl">nsIWebBrowserFocus.idl</a>
</p><p><code>nsIWebProgress</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIWebProgressListener</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIPrompt</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIPrefs</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIProfile</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIDirectoryServiceProvider</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsILocalFile</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIFile</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIClipboardCommands</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsISelection</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIURILoader</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p><p><code>nsIURIContentListener</code>
</p><p><b>More...</b>
</p><p><b>Interface status...</b>
</p><p><b>Interface definition:</b>
</p>
<h3 name="Defining_New_XPCOM_Components"> Defining New XPCOM Components </h3>
<hr>
<div class="originaldocinfo">
<h2 name="Original_Document_Information"> Original Document Information </h2>
<ul><li> Author(s): Rick Potts
</li><li> Last Updated Date: May 07, 2001
</li><li> Copyright Information: Creative Commons license
</li></ul>
</div>
Revert to this revision