MBS Plugin Documentation
Statistics - FAQ - Plugin Parts (All, Dependencies) - Class hierarchie
New in Version 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 9.0
The list of the themes, classes, controls, modules, global methods by category, global methods by name, screenshots, licenses and examples.
Platforms to show: All Mac Windows Linux Cross-Platform
WebViewMBS.ApplicationNameForUserAgent as String
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The application name.
Example:
This name will be used in user-agent strings that are chosen for best results in rendering web pages.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The application name.
Example:
webview1.ApplicationNameForUserAgentMBS="test"
// useragent is now "Mozilla/5.0 (Macintosh; U; PPC Mac OS X; de-de) AppleWebKit/417.9 (KHTML, like Gecko) test"
Notes: This name will be used in user-agent strings that are chosen for best results in rendering web pages.
(Read and Write runtime property)
WebViewMBS.backForwardList as WebBackForwardListMBS
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The backforward list for this webView.
Notes: Nil on failure.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The backforward list for this webView.
Notes: Nil on failure.
WebViewMBS.canGoBack as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the history can be used to move back one website.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the history can be used to move back one website.
WebViewMBS.canGoForward as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the history can be used to move forward one website.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the history can be used to move forward one website.
WebViewMBS.canMakeTextLarger as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the text size can be increased.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the text size can be increased.
WebViewMBS.canMakeTextSmaller as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the text size can be decreased.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the text size can be decreased.
WebViewMBS.CanShowMIMEType(mime as string) as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Checks if the WebKit can show content of a certain MIME type.
Notes: Returns false on any error and true on success.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Checks if the WebKit can show content of a certain MIME type.
Notes: Returns false on any error and true on success.
WebViewMBS.CanShowMIMETypeAsHTML(mime as string) as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Checks if the the MIME type is a type that the WebKit will interpret as HTML.
Notes: Returns false on any error and true on success.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Checks if the the MIME type is a type that the WebKit will interpret as HTML.
Notes: Returns false on any error and true on success.
class WebViewMBS
class, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The class to handle a webview.
Notes:
A webview is simply a content viewer for any web based content. It can render html pages, text pages and with plugins also flash or pdf files.
All methods in this class will catch exceptions from Cocoa and raise a NSExceptionMBS instead. Using the message, name and reason properties you can see what was the reason for this exception. Please report if you find a method which does not handle exceptions correct.
Subclass of the NSViewMBS class.
class, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The class to handle a webview.
Notes:
A webview is simply a content viewer for any web based content. It can render html pages, text pages and with plugins also flash or pdf files.
All methods in this class will catch exceptions from Cocoa and raise a NSExceptionMBS instead. Using the message, name and reason properties you can see what was the reason for this exception. Please report if you find a method which does not handle exceptions correct.
Subclass of the NSViewMBS class.
WebViewMBS.ClearFocus
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Clears the focus.
Example:
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Clears the focus.
Example:
webview.ClearFocus
Notes: If the focus is on the webpage, it will be cleared so there is no focus on the window. Useful if you want to workaround a focus bug in the htmlviewer control.WebViewMBS.Constructor
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The dummy constructor doing nothing.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The dummy constructor doing nothing.
WebViewMBS.Constructor(x as double, y as double, w as double, h as double)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Initializes a webview with a frame rectangle.
Example:
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Initializes a webview with a frame rectangle.
Example:
dim w as WebViewMBS
w=new WebViewMBS(0,0,800,600)
w.LoadHTMLString "Hello World",""
// and later
Backdrop=w.Image.CopyPicture
Notes: On success the handle property is not zero.WebViewMBS.Constructor(x as double, y as double, w as double, h as double, FrameName as string, GroupName as string)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Initializes a webview with a frame rectangle, a WebFrame name, and a group name.
Example:
The frameName should not be one of the pre-defined frame names (see the WebFrame findFrameNamed for a description of their meaning), but a custom name or a name used in HTML source. The groupName argument is an arbitrary identifier used to group related frames. For example, JavaScript running in a frame can access any other frame in the same group. It's up to the application how it chooses to scope related frames. Both frameName and groupName may be "". This method is the designated initializer for the WebView class.
On success the handle property is not zero.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Initializes a webview with a frame rectangle, a WebFrame name, and a group name.
Example:
dim w as WebViewMBS
w=new WebViewMBS(0,0,800,600,"test","test")
w.LoadHTMLString "Hello World",""
// and later
Backdrop=w.Image.CopyPicture
Notes: The frameName should not be one of the pre-defined frame names (see the WebFrame findFrameNamed for a description of their meaning), but a custom name or a name used in HTML source. The groupName argument is an arbitrary identifier used to group related frames. For example, JavaScript running in a frame can access any other frame in the same group. It's up to the application how it chooses to scope related frames. Both frameName and groupName may be "". This method is the designated initializer for the WebView class.
On success the handle property is not zero.
WebViewMBS.ContinuousSpellCheckingEnabled as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether continuous spell checking is enabled.
Example:
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether continuous spell checking is enabled.
Example:
webview1.ContinuousSpellCheckingEnabledMBS=True
Notes: (Read and Write runtime property)WebViewMBS.CustomTextEncodingName as String
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The custom text encoding name.
Notes:
On getting:
The custom text encoding name or "" if no custom text encoding name has been set.
On setting:
Make the page display with a different text encoding; stops any load in progress.
The text encoding passed in overrides the normal text encoding smarts including what's specified in a web page's header or HTTP response.
The text encoding automatically goes back to the default when the top level frame changes to a new location.
Setting the text encoding name to nil makes the webView use default encoding rules.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The custom text encoding name.
Notes:
On getting:
The custom text encoding name or "" if no custom text encoding name has been set.
On setting:
Make the page display with a different text encoding; stops any load in progress.
The text encoding passed in overrides the normal text encoding smarts including what's specified in a web page's header or HTTP response.
The text encoding automatically goes back to the default when the top level frame changes to a new location.
Setting the text encoding name to nil makes the webView use default encoding rules.
(Read and Write runtime property)
WebViewMBS.CustomUserAgent as String
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The custom user-agent string or nil if no custom user-agent string has been set.
Example:
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The custom user-agent string or nil if no custom user-agent string has been set.
Example:
webiew1.CustomUserAgentMBS=NewCFStringMBS("HelloWorldBrowser")
Notes: (Read and Write runtime property)WebViewMBS.dashboardBehavior(behavior as integer) as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.8, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Get or set the htmlviewer behavior.
Notes:
This is a private API from Apple which may break in the future.
It seems to exist for the dashboard application to switch some flags for event handling.
Behavior constants:
const WebDashboardBehaviorAlwaysSendMouseEventsToAllWindows = 0
const WebDashboardBehaviorAlwaysSendActiveNullEventsToPlugIns = 1
const WebDashboardBehaviorAlwaysAcceptsFirstMouse = 2
const WebDashboardBehaviorAllowWheelScrolling = 3
const WebDashboardBehaviorUseBackwardCompatibilityMode = 4
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.8, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Get or set the htmlviewer behavior.
Notes:
This is a private API from Apple which may break in the future.
It seems to exist for the dashboard application to switch some flags for event handling.
Behavior constants:
const WebDashboardBehaviorAlwaysSendMouseEventsToAllWindows = 0
const WebDashboardBehaviorAlwaysSendActiveNullEventsToPlugIns = 1
const WebDashboardBehaviorAlwaysAcceptsFirstMouse = 2
const WebDashboardBehaviorAllowWheelScrolling = 3
const WebDashboardBehaviorUseBackwardCompatibilityMode = 4
(Read and Write runtime property)
WebViewMBS.DrawsBackground as Boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Enable or disable the background drawing.
Notes:
Works only with Webkit on Mac OS X 10.3.9 and newer.
Returns false on unsupported Webkit versions.
If you set it to false, the background is not drawn and you can have transparent websites like the Dashboard widgets.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Enable or disable the background drawing.
Notes:
Works only with Webkit on Mac OS X 10.3.9 and newer.
Returns false on unsupported Webkit versions.
If you set it to false, the background is not drawn and you can have transparent websites like the Dashboard widgets.
(Read and Write runtime property)
WebViewMBS.EstimatedProgress as double
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: An estimate of the percent complete for a document load.
Example:
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: An estimate of the percent complete for a document load.
Example:
// waits till rendering is done:
WebView.mainFrame.LoadURL f.URLPath
while WebView.EstimatedProgress>0
DelayMBS 0.1
wend
// this works only because EstimatedProgress is set to 0.1 by LoadURL
// and set back to zero when the load process finishes.
// If future Webkit versions change the EstimatedProgress results,
// it will break.
Notes: This value will range from 0 to 1.0 and, once a load completes, will remain at 1.0 until a new load starts, at which point it will be reset to 0. The value is an estimate based on the total number of bytes expected to be received for a document, including all it's possible subresources. For more accurate progress indication it is recommended that you implement a WebFrameLoadDelegate and a WebResourceLoadDelegate.WebViewMBS.EvaluateJavaScript(code as string) as string
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Runs the given java script and returns the result.
Example:
Returns "" on any error.
In Safari 2 we used "return 1+2;" while in Safari 3 we only need "1+2;". The return is no longer needed.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Runs the given java script and returns the result.
Example:
// shows current user agent string which the control sends to website
MsgBox webview1.EvaluateJavaScriptMBS("navigator.userAgent;")
Notes: Returns "" on any error.
In Safari 2 we used "return 1+2;" while in Safari 3 we only need "1+2;". The return is no longer needed.
WebViewMBS.GoBack
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Go back to the previous URL in the backforward list.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Go back to the previous URL in the backforward list.
WebViewMBS.GoForward
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Go forward to the next URL in the backforward list.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Go forward to the next URL in the backforward list.
WebViewMBS.goToBackForwardItem(item as WebHistoryItemMBS) as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Moves on the history to the given item.
Notes: Returns true on success or false on failure.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Moves on the history to the given item.
Notes: Returns true on success or false on failure.
WebViewMBS.GroupName as string
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The group name for this WebView.
Notes:
JavaScript may access named frames within the same group.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The group name for this WebView.
Notes:
JavaScript may access named frames within the same group.
(Read and Write runtime property)
InstallWebFrameLoadDelegate(extends w as WebViewMBS, theDelegate as WebFrameLoadDelegateMBS)
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a WebFrameLoadDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this WebFrameLoadDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a WebFrameLoadDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this WebFrameLoadDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
InstallWebPolicyDelegate(extends w as WebViewMBS, theDelegate as WebPolicyDelegateMBS)
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a WebPolicyDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this WebPolicyDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a WebPolicyDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this WebPolicyDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
InstallWebResourceLoadDelegate(extends w as WebViewMBS, theDelegate as WebResourceLoadDelegateMBS)
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a WebResourceLoadDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this WebResourceLoadDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a WebResourceLoadDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this WebResourceLoadDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
InstallWebUIDelegate(extends w as WebViewMBS, theDelegate as WebUIDelegateMBS)
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a HTMLViewerUIDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this HTMLViewerUIDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
global method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerDelegate), Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Installs a HTMLViewerUIDelegateMBS to receive events from a webview control.
Notes: You need to keep a reference to this HTMLViewerUIDelegateMBS object in the window where the htmlviewer is inside so the class is not destroyed too early.
WebViewMBS.LoadHTMLString(data as string, mime as string, encoding as string, url as string)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads data as a webpage.
Example:
data: The data to use for the main page of the document.
mime: The MIME type of the data. e.g. "text/html"
textencoding: The encoding of the data.
url: The base URL to apply to relative URLs within the document.
All parameters can be empty if needed.
Using "text/plain" mime type you can show source code of website.
Like most Webkit Methods this one can not be called from a thread.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads data as a webpage.
Example:
webview.LoadHTMLStringMBS "<b>test</b>","text/plain","","" // show as plain text
webview.LoadHTMLStringMBS "<b>test</b>","text/html","","" // show as html
Notes: data: The data to use for the main page of the document.
mime: The MIME type of the data. e.g. "text/html"
textencoding: The encoding of the data.
url: The base URL to apply to relative URLs within the document.
All parameters can be empty if needed.
Using "text/plain" mime type you can show source code of website.
Like most Webkit Methods this one can not be called from a thread.
WebViewMBS.LoadHTMLString(text as string, url as string)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads a html page from a string.
Notes:
html: The string to use for the main page of the document.
url: The base URL to apply to relative URLs within the document. (optional)
Like most Webkit Methods this one can not be called from a thread.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads a html page from a string.
Notes:
html: The string to use for the main page of the document.
url: The base URL to apply to relative URLs within the document. (optional)
Like most Webkit Methods this one can not be called from a thread.
WebViewMBS.LoadURL(url as string)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads the url.
Example:
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads the url.
Example:
webview.LoadURLMBS "http://www.monkeybreadsoftware.de"
Notes: Like most Webkit Methods this one can not be called from a thread.WebViewMBS.LoadURL(url as string, CachePolicy as integer, TimeOut as double)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads the URL.
Example:
The timeout interval is in seconds.
Constants for the CachePolicy parameter:
Like most Webkit Methods this one can not be called from a thread.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Loads the URL.
Example:
webview.LoadURLMBS "http://www.monkeybreadsoftware.de", 1, 2.0
Notes: The timeout interval is in seconds.
Constants for the CachePolicy parameter:
| const UseProtocolCachePolicy | = 0 | Specifies that the caching logic defined in the protocol implementation, if any, is used for a particular URL load request. This is the default policy for URL load requests. |
| const ReloadIgnoringCacheData | = 1 | Specifies that the data for the URL load should be loaded from the originating source. No existing cache data should be used to satisfy a URL load request. |
| const ReturnCacheDataElseLoad | = 2 | Specifies that the existing cached data should be used to satisfy the request, regardless of its age or expiration date. If there is no existing data in the cache corresponding the request, the data is loaded from the originating source. |
| const ReturnCacheDataDontLoad | = 3 | Specifies that the existing cache data should be used to satisfy a request, regardless of its age or expiration date. If there is no existing data in the cache corresponding to a URL load request, no attempt is made to load the data from the originating source, and the load is considered to have failed. This constant specifies a behavior that is similar to an “offline” mode. |
Like most Webkit Methods this one can not be called from a thread.
WebViewMBS.mainFrame as WebFrameMBS
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The main webframe currently displayed.
Notes: Nil if no is present.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The main webframe currently displayed.
Notes: Nil if no is present.
WebViewMBS.makeTextLarger
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Increases the text size in the webview.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Increases the text size in the webview.
WebViewMBS.makeTextSmaller
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Decreases the text size in the webview.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Decreases the text size in the webview.
WebViewMBS.mediaStyle as String
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The value to use for the CSS media property.
Example:
Set or get the media style for the WebView. The mediaStyle will override the normal value of the CSS media property. Setting the value to nil will restore the normal value.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The value to use for the CSS media property.
Example:
w.mediaStyle="print"
Notes: Set or get the media style for the WebView. The mediaStyle will override the normal value of the CSS media property. Setting the value to nil will restore the normal value.
(Read and Write runtime property)
WebViewMBS.preferences as WebPreferencesMBS
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The preferences for this webview.
Notes:
Nil on failure.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The preferences for this webview.
Notes:
Nil on failure.
(Read and Write runtime property)
WebViewMBS.PreferencesIdentifier as string
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The string to use a prefix for storing values for this WebView in the user defaults database.
Notes:
If the WebPreferences for this WebView are stored in the user defaults database, the string set in this method will be used a key prefix.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The string to use a prefix for storing values for this WebView in the user defaults database.
Notes:
If the WebPreferences for this WebView are stored in the user defaults database, the string set in this method will be used a key prefix.
(Read and Write runtime property)
WebViewMBS.Reload
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reloads the current page.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Reloads the current page.
WebViewMBS.RenderDocumentToEPS as String
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Returns the content of the view as a EPS file's data.
Example:
Returns "" on any error.
Will resize the eps page to match the size of the website.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Returns the content of the view as a EPS file's data.
Example:
dim f as FolderItem
dim b as BinaryStream
// create a new pdf with current content of view
f=DesktopFolder.Child("test.eps")
b=f.CreateBinaryFile("")
b.Write theWebView.RenderDocumentToEPS
b.Close
f.Launch // show the pdf in preview
#
Notes: Returns "" on any error.
Will resize the eps page to match the size of the website.
WebViewMBS.RenderDocumentToPDF as String
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Returns the content of the view as a PDF file's data.
Example:
Returns "" on any error.
Will resize the pdf page to match the size of the website.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Returns the content of the view as a PDF file's data.
Example:
dim f as FolderItem
dim b as BinaryStream
// create a new pdf with current content of view
f=DesktopFolder.Child("test.pdf")
b=f.CreateBinaryFile("")
b.Write thewebview.RenderDocumentToPDF
b.Close
f.Launch // show the pdf in preview
#
Notes: Returns "" on any error.
Will resize the pdf page to match the size of the website.
WebViewMBS.RenderWebsiteImage as variant
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Makes a screenshot of the current displayed content.
Example:
Nil on failure.
The image returned is the page completely without scrollbars, so it may be a few thousand pixels height and may not fit on a page to print.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.6, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Makes a screenshot of the current displayed content.
Example:
dim f as FolderItem
dim b as BinaryStream
dim i as NSImageMBS
dim p as string
i=webview.RenderWebsiteImage
p=i.PNGRepresentation
f=DesktopFolder.Child("test.png")
b=f.CreateBinaryFile("")
b.Write p
Notes: Nil on failure.
The image returned is the page completely without scrollbars, so it may be a few thousand pixels height and may not fit on a page to print.
WebViewMBS.ScrollHeight as single
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The height of the scroll view.
Notes: (Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The height of the scroll view.
Notes: (Read and Write runtime property)
WebViewMBS.ScrollLeft as single
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The left position of the scroll view.
Example:
You can set this value to scroll manually.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The left position of the scroll view.
Example:
myWebView.ScrollLeft=myWebView.ScrollLeft+5
Notes: You can set this value to scroll manually.
(Read and Write runtime property)
WebViewMBS.ScrollTop as single
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The top position of the scroll view.
Example:
You can set this value to scroll manually.
(Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The top position of the scroll view.
Example:
myWebView.ScrollTop=myWebView.ScrollTop+5
Notes: You can set this value to scroll manually.
(Read and Write runtime property)
WebViewMBS.ScrollWidth as single
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The width of the scroll view.
Notes: (Read and Write runtime property)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.5, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: The width of the scroll view.
Notes: (Read and Write runtime property)
WebViewMBS.SearchFor(text as string, Forward as boolean, CaseSensitive as boolean, Wrap as Boolean) as boolean
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Searches a document view for a string and highlights the string if it is found.
Notes:
Starts the search from the current selection. Will search across all frames.
text: The string to search for.
forward: True to search forward, False to seach backwards.
caseSensitive: True to for case-sensitive search, False for case-insensitive search.
Returns true if found, false if not found.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Searches a document view for a string and highlights the string if it is found.
Notes:
Starts the search from the current selection. Will search across all frames.
text: The string to search for.
forward: True to search forward, False to seach backwards.
caseSensitive: True to for case-sensitive search, False for case-insensitive search.
Returns true if found, false if not found.
WebViewMBS.setMaintainsBackForwardList(value as boolean)
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the back forward history list is created by the webview.
Notes: Default is true.
method, HTMLViewer, MBS Cocoa Plugin (HTMLViewerWeb), class WebViewMBS, Console safe, Plugin version: 7.7, Mac OS X: Works, Windows: Does nothing, Linux x86: Does nothing, Feedback.
Function: Whether the back forward history list is created by the webview.
Notes: Default is true.
The items on this page are in the following plugins: MBS Cocoa Plugin.
Monkeybread Software Realbasic Plugins - Messdiener Nickenich