• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Creating / Printing WebViews programmatically
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Creating / Printing WebViews programmatically


  • Subject: Re: Creating / Printing WebViews programmatically
  • From: George Orthwein <email@hidden>
  • Date: Thu, 14 Sep 2006 13:45:16 -0400

On Sep 14, 2006, at 7:51 AM, Rob Chahin wrote:

The setHostWindow: is in there because the Apple docs mention attaching a WebView to a window, but don't go into detail about when you need to do it. The result is the same regardless.

From looking at list archives (don't forget webkitsdk-dev), it looks like adding the webview to an offscreen window is something people have done successfully for printing.



The problem seems to be that I'm creating my webView incorrectly, since it more or less works with the IB webView. I tried printView = [WebView new]; but that didn't work either.

I create a webview in much the same way and then add it to a tabview which works fine. (MyWebView is a subclass):


MyWebView* newWebView = [[MyWebView alloc] initWithFrame:[theTabView contentRect] frameName:nil groupName:nil];
[newTabItem setView:newWebView];


So perhaps it is just the attaching it to a window bit.

Hope that helps,
George
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Creating / Printing WebViews programmatically (From: Rob Chahin <email@hidden>)

  • Prev by Date: Hide a window on close?
  • Next by Date: NSOutlineView variable width cell
  • Previous by thread: Creating / Printing WebViews programmatically
  • Next by thread: GuardMalloc question
  • Index(es):
    • Date
    • Thread