[webkit-dev] Duplicate page: Implementing Print Preview

2009-05-27 Thread Sverrir Á . Berg
Hi all,
I'm working on Google Chrome and trying to come up with a way to implement
print preview.  To be able to display it in a separate tab we need to be
able to duplicate the current page in memory so the user can continue to
interact with the original page.  Javacript, animations etc should continue
on the original page but be frozen in the print preview version.
What I've tried so far is to select everything on the page
(Frame::selection()-SelectAll()) and Frame::GetSelection(true) but the HTML
does not fully describe the page and this has the downside of modifying the
users selection on the page.
I've poked around in WebKit a bit and as far as I can tell the document,
rendertree and the views are fairly integrated and not easy to take a
snapshot of the full state of the document.  I would appreciate any insights
on this though since I might have missed something obvious.

If nothing existing can be reused then adding this functionality should
benefit all ports.  But again I need your insights on how this can be done
(if at all).

Sverrir
___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] Duplicate page: Implementing Print Preview

2009-05-27 Thread Sverrir Á . Berg
Interesting idea.  I see two downsides to that though.  Firstly I think need
some kind of PDF library since only Mac's have native support and when the
user needs to change the layout of the page (margins, portrait/landscape) I
would need to re-create the PDF again?

Sverrir


On Wed, May 27, 2009 at 1:03 PM, David Hyatt hy...@apple.com wrote:

 Can you render the page to PDF and display the PDF?  Maybe you could render
 the page into bitmaps if you aren't able to support PDF.
 dave
 (hy...@apple.com)

 On May 27, 2009, at 11:53 AM, Sverrir Á. Berg wrote:

 Hi all,
 I'm working on Google Chrome and trying to come up with a way to implement
 print preview.  To be able to display it in a separate tab we need to be
 able to duplicate the current page in memory so the user can continue to
 interact with the original page.  Javacript, animations etc should continue
 on the original page but be frozen in the print preview version.
 What I've tried so far is to select everything on the page
 (Frame::selection()-SelectAll()) and Frame::GetSelection(true) but the HTML
 does not fully describe the page and this has the downside of modifying the
 users selection on the page.
 I've poked around in WebKit a bit and as far as I can tell the document,
 rendertree and the views are fairly integrated and not easy to take a
 snapshot of the full state of the document.  I would appreciate any insights
 on this though since I might have missed something obvious.

 If nothing existing can be reused then adding this functionality should
 benefit all ports.  But again I need your insights on how this can be done
 (if at all).

 Sverrir
 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev



___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] Is it OK to remove Frame::setIsDisconnected() and isDisconnected() ?

2009-04-15 Thread Sverrir Á . Berg
Hi Adam,Thanks for the links.  These are simply exposing the functions as a
formal a API's.  I understand that you typically don't want to change
externally exposed API's but these can easily be stubbed out (or removed).
I should have pointed out in my original email that I have tried to remove
these API's and I can still run all the WebKit/Mac tests fine.  So at least
two things are missing (IMHO) - tests that verify that this functionality is
working as intended and documentation to tell what that intent is.  But this
is only required if somebody is actually using these functions...

Thanks,
Sverrir


On Wed, Apr 15, 2009 at 4:17 PM, Adam Roben aro...@apple.com wrote:

 On Apr 15, 2009, at 3:48 PM, Sverrir Á. Berg wrote:

  Working on a change in FrameTree and noticed that the checks in top() and
 parent() for 'checkForDisconnectedFrame' rely on a flag in Frame that as far
 as I can tell is never set.
 So my naive question is: Can I remove the corresponding code from Frame
 and FrameTree?  If not I would like if somebody could explain how they are
 used so I don't break anything with my change.

 More detail:
 * My search for calls to Frame::setIsDisconnected reveals no callers in
 WebKit, Chromium or Google code search.


 There are two callers:


 http://trac.webkit.org/browser/trunk/WebKit/mac/WebView/WebFrame.mm?rev=42451#L1115

 and

 http://trac.webkit.org/browser/trunk/WebKit/win/WebFrame.cpp?rev=42451#L283

 -Adam


___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


Re: [webkit-dev] Fw: not enough space error???

2009-04-01 Thread Sverrir Á . Berg
I've had this problem and I've heard of others.  My solution was switching
to a Mac for development.  Number of people have no problems building with
that setup but I think the mainstream setup for Windows is moving towards
64-bit Vista with lots of memory (but still building 32-bit)...
Sverrir


2009/4/1 Ben Murdoch bmurd...@gmail.com

 Hi,

 I'm running into the same problem, C1083 (not enough space) trying to link
 WebCore.lib on Windows XP SP3 in Cygwin (working with r42007). I've tried
 setting the /3GB boot option, but that doesn't seem to help. Were you able
 to solve this problem Aman? Has anyone else run into it and found a
 solution? Debug builds work fine for me.

 Thanks, Ben

 2008/12/13 Justin Haygood jhayg...@reaktix.com

  No, but all the source code and object files used to create it are.

 - Original Message -
  *From:* Aman zhaiqi...@gmail.com
 *To:* webkit-dev webkit-dev@lists.webkit.org
 *Sent:* Saturday, December 13, 2008 2:08 AM
 *Subject:* [webkit-dev] Fw: not enough space error???

 Hi,

 The release version of the WebCore.lib is about 1.2G, not really???
 anybody knows that??

 Aman

  *From:* Aman zhaiqi...@gmail.com
 *Sent:* Saturday, December 13, 2008 1:59 PM
 *To:* aro...@apple.com
 *Cc:* webkit-dev webkit-dev@lists.webkit.org
 *Subject:* not enough space error???

 Hi, Adam and everybody:

 I received this error the message while building WebCore(release) as
 someone else before:

 Linking...
 fatal error C1083: Cannot open compiler intermediate file:
 'C:\cygwin\home\Administrator\webkit\WebKitBuild\lib\WebCore.lib': Not
 enough space
 and i saw your post message about this error , but i think it is not like
 https://bugs.webkit.org/show_bug.cgi?id=19743.(i am using the newest
 version)

 Aman

 --

 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev




 --
 Ben Murdoch
 http://www.omgwtf.me.uk
 b...@omgwtf.me.uk | bmurd...@gmail.com

 ___
 webkit-dev mailing list
 webkit-dev@lists.webkit.org
 http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev


___
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev