Apple Developer Connection
Member Login Log In | Not a Member? Contact ADC

Next Page > Hide TOC

WebFrameView Class Reference

Inherits from
Conforms to
Framework
/System/Library/Frameworks/WebKit.framework
Availability
Available in Mac OS X v10.2 with Safari 1.0 and later.
Available in Mac OS X v10.2.7 and later.
Companion guide
Declared in
WebFrameView.h

Overview

WebFrameView objects and their subviews display the actual web content contained in a frame. You never create instances of WebFrameView directly—WebView objects create and manage a hierarchy of WebFrameView objects, one for each frame. WebFrameView objects use a scroll view whose document view conforms to the WebDocumentView protocol.

Tasks

Getting the Web Frame

Getting Subviews

Setting Scrolling Behavior

Printing Views

Instance Methods

allowsScrolling

Returns whether or not the user should be allowed to scroll.

- (BOOL)allowsScrolling

Discussion

This method returns YES if the receiver allows the user to scroll, NO otherwise.

Availability
See Also
Declared In
WebFrameView.h

canPrintHeadersAndFooters

Returns a Boolean value indicating whether or not the receiver can print headers and footers.

- (BOOL)canPrintHeadersAndFooters

Return Value

YES if the receiver can print headers and footers; otherwise, NO.

Availability
Declared In
WebFrameView.h

documentView

Returns the subview that actually displays the web content.

- (NSView < WebDocumentView > *)documentView

Discussion

Use setAllowsScrolling: to enable scrolling of this view.

Availability
Declared In
WebFrameView.h

documentViewShouldHandlePrint

Returns a Boolean value indicating whether or not the document view should handle a print operation.

- (BOOL)documentViewShouldHandlePrint

Return Value

YES if the document view handles the print operation; otherwise, NO. If this method returns NO, the application aborts its print operation and sends printDocumentView to the web frame view.

Availability
Declared In
WebFrameView.h

printDocumentView

Prints the receiver.

- (void)printDocumentView

Discussion

This method is invoked if the documentViewShouldHandlePrint method returns NO.

Availability
Declared In
WebFrameView.h

printOperationWithPrintInfo:

Returns a print operation to print this frame.

- (NSPrintOperation *)printOperationWithPrintInfo:(NSPrintInfo *)printInfo

Parameters
printInfo

An NSPrintInfo object that encapsulates information about the print settings.

Return Value

A newly created NSPrintOperation object set up to print this frame.

Availability
Declared In
WebFrameView.h

setAllowsScrolling:

Sets whether the frame view should allow the user to scroll.

- (void)setAllowsScrolling:(BOOL)flag

Discussion

If flag is YES scrolling is allowed, otherwise it is not. If the frame contains a scrolling element, then that value is used as the default, otherwise the default is YES.

Availability
See Also
Declared In
WebFrameView.h

webFrame

Returns the WebFrame object associated with the receiver.

- (WebFrame *)webFrame

Availability
Declared In
WebFrameView.h

Next Page > Hide TOC


Last updated: 2008-06-19




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Get information on Apple products.
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Copyright © 2007 Apple Inc.
All rights reserved. | Terms of use | Privacy Notice