Source/WebCore: WebCore part of: Allow the length of a page along the pagination...
authormitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 Dec 2011 01:14:25 +0000 (01:14 +0000)
committermitz@apple.com <mitz@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 1 Dec 2011 01:14:25 +0000 (01:14 +0000)
https://bugs.webkit.org/show_bug.cgi?id=73476

Reviewed by Anders Carlsson.

* page/Page.cpp:
(WebCore::Page::setPagination): Changed to use Pagination::operator==.
* page/Page.h:
(WebCore::Page::Pagination::Pagination): Added initializer for the new pageLength member variable.
(WebCore::Page::Pagination::operator==): Added.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::layoutColumns): Narrowed the scope of a local variable.
* rendering/RenderBlock.h: Promoted setDesiredColumnCountAndWidth() from private to protected,
allowing its use from RenderView::calcColumnWidth(). Made calcColumnWidth() virtual.
* rendering/RenderView.cpp:
(WebCore::RenderView::calcColumnWidth): Added. Uses the page length specified in the pagination
parameters to set the column width, if pages are to be laid out one next to the other.
(WebCore::RenderView::viewLogicalHeight): Added. Uses the page length specified in the pagination
parameters as the height, if pages are to be laid out one after the other.
* rendering/RenderView.h:

Source/WebKit/mac: WebKit/mac part of: Allow the length of a page along the pagination axis to differ from the length of the view
https://bugs.webkit.org/show_bug.cgi?id=73476

Reviewed by Anders Carlsson.

* WebView/WebView.mm:
(-[WebView _setPageLength:]): Added this accessor.
(-[WebView _pageLength]): Ditto.
* WebView/WebViewPrivate.h:

Source/WebKit2: WebKit2 part of: Allow the length of a page along the pagination axis to differ from the length of the view
https://bugs.webkit.org/show_bug.cgi?id=73476

Reviewed by Anders Carlsson.

* Shared/WebPageCreationParameters.cpp:
(WebKit::WebPageCreationParameters::encode): Encode pageLength.
(WebKit::WebPageCreationParameters::decode): Decode pageLength.
* Shared/WebPageCreationParameters.h: Added pageLength.
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageLength): Added this accessor.
(WKPageGetPageLength): Ditto.
* UIProcess/API/C/WKPagePrivate.h:
* UIProcess/API/mac/WKBrowsingContextController.mm:
(-[WKBrowsingContextController setPageLength:]): Ditto.
(-[WKBrowsingContextController pageLength]): Ditto.
* UIProcess/API/mac/WKBrowsingContextControllerPrivate.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy): Added initializer for m_pageLength.
(WebKit::WebPageProxy::setPageLength): Added.
(WebKit::WebPageProxy::creationParameters): Initialize pageLength.
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::pageLength): Added.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage): Set the page length based on the creation parameters.
(WebKit::WebPage::setPageLength): Added.
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in: Added SetPageLength.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@101574 268f45cc-cd09-0410-ab3c-d52691b4dbfc

22 files changed:
Source/WebCore/ChangeLog
Source/WebCore/page/Page.cpp
Source/WebCore/page/Page.h
Source/WebCore/rendering/RenderBlock.cpp
Source/WebCore/rendering/RenderBlock.h
Source/WebCore/rendering/RenderView.cpp
Source/WebCore/rendering/RenderView.h
Source/WebKit/mac/ChangeLog
Source/WebKit/mac/WebView/WebView.mm
Source/WebKit/mac/WebView/WebViewPrivate.h
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/WebPageCreationParameters.cpp
Source/WebKit2/Shared/WebPageCreationParameters.h
Source/WebKit2/UIProcess/API/C/WKPage.cpp
Source/WebKit2/UIProcess/API/C/WKPagePrivate.h
Source/WebKit2/UIProcess/API/mac/WKBrowsingContextController.mm
Source/WebKit2/UIProcess/API/mac/WKBrowsingContextControllerPrivate.h
Source/WebKit2/UIProcess/WebPageProxy.cpp
Source/WebKit2/UIProcess/WebPageProxy.h
Source/WebKit2/WebProcess/WebPage/WebPage.cpp
Source/WebKit2/WebProcess/WebPage/WebPage.h
Source/WebKit2/WebProcess/WebPage/WebPage.messages.in

index 8a63e974d5473c0128908a5b4b800c20b61905dd..6a9f60c957d24765c8960588651cbcf614f4b7f6 100644 (file)
@@ -1,3 +1,26 @@
+2011-11-30  Dan Bernstein  <mitz@apple.com>
+
+        WebCore part of: Allow the length of a page along the pagination axis to differ from the length of the view
+        https://bugs.webkit.org/show_bug.cgi?id=73476
+
+        Reviewed by Anders Carlsson.
+
+        * page/Page.cpp:
+        (WebCore::Page::setPagination): Changed to use Pagination::operator==.
+        * page/Page.h:
+        (WebCore::Page::Pagination::Pagination): Added initializer for the new pageLength member variable.
+        (WebCore::Page::Pagination::operator==): Added.
+        * rendering/RenderBlock.cpp:
+        (WebCore::RenderBlock::layoutColumns): Narrowed the scope of a local variable.
+        * rendering/RenderBlock.h: Promoted setDesiredColumnCountAndWidth() from private to protected,
+        allowing its use from RenderView::calcColumnWidth(). Made calcColumnWidth() virtual.
+        * rendering/RenderView.cpp:
+        (WebCore::RenderView::calcColumnWidth): Added. Uses the page length specified in the pagination
+        parameters to set the column width, if pages are to be laid out one next to the other.
+        (WebCore::RenderView::viewLogicalHeight): Added. Uses the page length specified in the pagination
+        parameters as the height, if pages are to be laid out one after the other.
+        * rendering/RenderView.h:
+
 2011-11-30  Chris Fleizach  <cfleizach@apple.com>
 
         AX: Nodes are reporting that focus can be set when they really can't
index c08812cf43a65a4ab9314e9656ad9b3d97e989ff..77200fe2274c8328e570e703f85eb013572d20b6 100644 (file)
@@ -677,7 +677,7 @@ void Page::setDeviceScaleFactor(float scaleFactor)
 
 void Page::setPagination(const Pagination& pagination)
 {
-    if (m_pagination.mode == pagination.mode && m_pagination.gap == pagination.gap)
+    if (m_pagination == pagination)
         return;
 
     m_pagination = pagination;
index 3d0ee7a9bd45d785fb66314d9c9a280fe4dddc70..49801b55f90597f1b0f619c6fbb7b633abf61a5f 100644 (file)
@@ -261,11 +261,18 @@ namespace WebCore {
 
             Pagination()
                 : mode(Unpaginated)
+                , pageLength(0)
                 , gap(0)
             {
             };
 
+            bool operator==(const Pagination& other) const
+            {
+                return mode == other.mode && pageLength == other.pageLength && gap == other.gap;
+            }
+
             Mode mode;
+            unsigned pageLength;
             unsigned gap;
         };
 
index 51a22f940a62a96712b44be70ee0b13df40a8fcc..12d8b12dbbe32a0c6725d406cf182fb8a74e538c 100755 (executable)
@@ -4619,10 +4619,10 @@ bool RenderBlock::layoutColumns(bool hasSpecifiedPageLogicalHeight, LayoutUnit p
     // FIXME: We don't balance properly at all in the presence of forced page breaks.  We need to understand what
     // the distance between forced page breaks is so that we can avoid making the minimum column height too tall.
     ColumnInfo* colInfo = columnInfo();
-    int desiredColumnCount = colInfo->desiredColumnCount();
     if (!hasSpecifiedPageLogicalHeight) {
         LayoutUnit columnHeight = pageLogicalHeight;
         int minColumnCount = colInfo->forcedBreaks() + 1;
+        int desiredColumnCount = colInfo->desiredColumnCount();
         if (minColumnCount >= desiredColumnCount) {
             // The forced page breaks are in control of the balancing.  Just set the column height to the
             // maximum page break distance.
index 7013820b002e96c79b5c403507c8898bca383ebe..7b752511e26b2dd52ab2eafc4a65f0eb0a9ee1a1 100644 (file)
@@ -414,6 +414,8 @@ protected:
     bool simplifiedLayout();
     void simplifiedNormalFlowLayout();
 
+    void setDesiredColumnCountAndWidth(int, LayoutUnit);
+
     void computeOverflow(LayoutUnit oldClientAfterEdge, bool recomputeFloats = false);
     virtual void addOverflowFromChildren();
     void addOverflowFromFloats();
@@ -750,7 +752,6 @@ private:
 
     LayoutUnit desiredColumnWidth() const;
     unsigned desiredColumnCount() const;
-    void setDesiredColumnCountAndWidth(int count, LayoutUnit width);
 
     void paintContinuationOutlines(PaintInfo&, const LayoutPoint&);
 
@@ -769,7 +770,7 @@ private:
     // Adjust from painting offsets to the local coords of this renderer
     void offsetForContents(LayoutPoint&) const;
 
-    void calcColumnWidth();
+    virtual void calcColumnWidth();
     bool layoutColumns(bool hasSpecifiedPageLogicalHeight, LayoutUnit pageLogicalHeight, LayoutStateMaintainer&);
     void makeChildrenAnonymousColumnBlocks(RenderObject* beforeChild, RenderBlock* newBlockBox, RenderObject* newChild);
 
index 92a97f7da38796cdc4dfd4c2364ac9cc384c3cae..754e3290d6b9c03d861e393ce28690233ec6b1cb 100644 (file)
@@ -185,6 +185,20 @@ bool RenderView::requiresColumns(int desiredColumnCount) const
     return RenderBlock::requiresColumns(desiredColumnCount);
 }
 
+void RenderView::calcColumnWidth()
+{
+    int columnWidth = contentLogicalWidth();
+    if (m_frameView && style()->hasInlineColumnAxis()) {
+        if (Frame* frame = m_frameView->frame()) {
+            if (Page* page = frame->page()) {
+                if (int pageLength = page->pagination().pageLength)
+                    columnWidth = pageLength;
+            }
+        }
+    }
+    setDesiredColumnCountAndWidth(1, columnWidth);
+}
+
 void RenderView::paint(PaintInfo& paintInfo, const LayoutPoint& paintOffset)
 {
     // If we ever require layout but receive a paint anyway, something has gone horribly wrong.
@@ -734,6 +748,24 @@ int RenderView::viewWidth() const
     return width;
 }
 
+int RenderView::viewLogicalHeight() const
+{
+    int height = style()->isHorizontalWritingMode() ? viewHeight() : viewWidth();
+
+    if (hasColumns() && !style()->hasInlineColumnAxis()) {
+        if (Frame* frame = m_frameView->frame()) {
+            if (Page* page = frame->page()) {
+                if (frame == page->mainFrame()) {
+                    if (int pageLength = page->pagination().pageLength)
+                        height = pageLength;
+                }
+            }
+        }
+    }
+
+    return height;
+}
+
 float RenderView::zoomFactor() const
 {
     Frame* frame = m_frameView->frame();
index 615010c857724a23bb031fb5f48d82b844298844..c8c150d4d4df814d99fcc76f0a349b61123b58f5 100644 (file)
@@ -61,7 +61,7 @@ public:
     int viewHeight() const;
     int viewWidth() const;
     int viewLogicalWidth() const { return style()->isHorizontalWritingMode() ? viewWidth() : viewHeight(); }
-    int viewLogicalHeight() const { return style()->isHorizontalWritingMode() ? viewHeight() : viewWidth(); }
+    int viewLogicalHeight() const;
 
     float zoomFactor() const;
 
@@ -194,6 +194,8 @@ protected:
     virtual bool requiresColumns(int desiredColumnCount) const OVERRIDE;
 
 private:
+    virtual void calcColumnWidth() OVERRIDE;
+
     bool shouldRepaint(const IntRect& r) const;
 
     // These functions may only be accessed by LayoutStateMaintainer.
index 85861eeda3614f17427d864478aa599d27ac679a..a4a82c2e5685ce082ac0ed54f3d73c9ea1bb3504 100644 (file)
@@ -1,3 +1,15 @@
+2011-11-30  Dan Bernstein  <mitz@apple.com>
+
+        WebKit/mac part of: Allow the length of a page along the pagination axis to differ from the length of the view
+        https://bugs.webkit.org/show_bug.cgi?id=73476
+
+        Reviewed by Anders Carlsson.
+
+        * WebView/WebView.mm:
+        (-[WebView _setPageLength:]): Added this accessor.
+        (-[WebView _pageLength]): Ditto.
+        * WebView/WebViewPrivate.h:
+
 2011-11-30  Alexey Proskuryakov  <ap@apple.com>
 
         Download page URL should be set by WebCore
index e4b875ca3441b293a59ec33b2b89832bc591e449..0f684a5aad3c1a0fdf3a43f8aa5272c93623ea46 100644 (file)
@@ -2778,6 +2778,27 @@ static PassOwnPtr<Vector<String> > toStringVector(NSArray* patterns)
     return WebPaginationModeUnpaginated;
 }
 
+- (void)_setPageLength:(CGFloat)pageLength
+{
+    Page* page = core(self);
+    if (!page)
+        return;
+
+    Page::Pagination pagination = page->pagination();
+    pagination.pageLength = pageLength;
+
+    page->setPagination(pagination);
+}
+
+- (CGFloat)_pageLength
+{
+    Page* page = core(self);
+    if (!page)
+        return 1;
+
+    return page->pagination().pageLength;
+}
+
 - (void)_setGapBetweenPages:(CGFloat)pageGap
 {
     Page* page = core(self);
index 6aaab9dea359aa1cd836e27e2f628de399e8c557..dbe094c15ce11088de163d0bea7a400a4a2f116d 100644 (file)
@@ -563,6 +563,9 @@ Could be worth adding to the API.
 
 - (void)_setPaginationMode:(WebPaginationMode)paginationMode;
 - (WebPaginationMode)_paginationMode;
+// Set to 0 to have the page length equal the view length.
+- (void)_setPageLength:(CGFloat)pageLength;
+- (CGFloat)_pageLength;
 - (void)_setGapBetweenPages:(CGFloat)pageGap;
 - (CGFloat)_gapBetweenPages;
 - (NSUInteger)_pageCount;
index cbb5e6de5f1e87b4db155248dc08cde2fab17bdb..cae2a19e1f7226c502d9f9df02c1b018a94f1019 100644 (file)
@@ -1,3 +1,34 @@
+2011-11-30  Dan Bernstein  <mitz@apple.com>
+
+        WebKit2 part of: Allow the length of a page along the pagination axis to differ from the length of the view
+        https://bugs.webkit.org/show_bug.cgi?id=73476
+
+        Reviewed by Anders Carlsson.
+
+        * Shared/WebPageCreationParameters.cpp:
+        (WebKit::WebPageCreationParameters::encode): Encode pageLength.
+        (WebKit::WebPageCreationParameters::decode): Decode pageLength.
+        * Shared/WebPageCreationParameters.h: Added pageLength.
+        * UIProcess/API/C/WKPage.cpp:
+        (WKPageSetPageLength): Added this accessor.
+        (WKPageGetPageLength): Ditto.
+        * UIProcess/API/C/WKPagePrivate.h:
+        * UIProcess/API/mac/WKBrowsingContextController.mm:
+        (-[WKBrowsingContextController setPageLength:]): Ditto.
+        (-[WKBrowsingContextController pageLength]): Ditto.
+        * UIProcess/API/mac/WKBrowsingContextControllerPrivate.h:
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::WebPageProxy): Added initializer for m_pageLength.
+        (WebKit::WebPageProxy::setPageLength): Added.
+        (WebKit::WebPageProxy::creationParameters): Initialize pageLength.
+        * UIProcess/WebPageProxy.h:
+        (WebKit::WebPageProxy::pageLength): Added.
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::WebPage): Set the page length based on the creation parameters.
+        (WebKit::WebPage::setPageLength): Added.
+        * WebProcess/WebPage/WebPage.h:
+        * WebProcess/WebPage/WebPage.messages.in: Added SetPageLength.
+
 2011-11-30  Alejandro G. Castro  <alex@igalia.com>
 
         [GTK] Add accelerated compositing compilation option
index fdce1ef7e6f5a61f54e049c7a2bb84dd4360cc70..2e4d99db12b42223ebeb4e1b7d41746a75926f5a 100644 (file)
@@ -47,6 +47,7 @@ void WebPageCreationParameters::encode(CoreIPC::ArgumentEncoder* encoder) const
     encoder->encode(useFixedLayout);
     encoder->encode(fixedLayoutSize);
     encoder->encodeEnum(paginationMode);
+    encoder->encode(pageLength);
     encoder->encode(gapBetweenPages);
     encoder->encode(userAgent);
     encoder->encode(sessionState);
@@ -94,6 +95,8 @@ bool WebPageCreationParameters::decode(CoreIPC::ArgumentDecoder* decoder, WebPag
         return false;
     if (!decoder->decodeEnum(parameters.paginationMode))
         return false;
+    if (!decoder->decode(parameters.pageLength))
+        return false;
     if (!decoder->decode(parameters.gapBetweenPages))
         return false;
     if (!decoder->decode(parameters.userAgent))
index 613357b5e98106617dc03da7a73262bc6604e151..972dcb083a113f03bec3abd016eaade4fa5fda8a 100644 (file)
@@ -64,6 +64,7 @@ struct WebPageCreationParameters {
     WebCore::IntSize fixedLayoutSize;
 
     WebCore::Page::Pagination::Mode paginationMode;
+    double pageLength;
     double gapBetweenPages;
 
     String userAgent;
index ede4ea629098de093ab1ad686036f75158485403..39e87cbf785d7230ac81b91c16390d0ecea68366 100644 (file)
@@ -379,6 +379,16 @@ WKPaginationMode WKPageGetPaginationMode(WKPageRef pageRef)
     return kWKPaginationModeUnpaginated;
 }
 
+void WKPageSetPageLength(WKPageRef pageRef, double pageLength)
+{
+    toImpl(pageRef)->setPageLength(pageLength);
+}
+
+double WKPageGetPageLength(WKPageRef pageRef)
+{
+    return toImpl(pageRef)->pageLength();
+}
+
 void WKPageSetGapBetweenPages(WKPageRef pageRef, double gap)
 {
     toImpl(pageRef)->setGapBetweenPages(gap);
index a1cea0bc52ee782858f3d5920f6021f0727be7f2..2699e9c519ca21974d2c08c9df326b1b8be65656 100644 (file)
@@ -61,6 +61,8 @@ typedef uint32_t WKPaginationMode;
 
 WK_EXPORT void WKPageSetPaginationMode(WKPageRef page, WKPaginationMode paginationMode);
 WK_EXPORT WKPaginationMode WKPageGetPaginationMode(WKPageRef page);
+WK_EXPORT void WKPageSetPageLength(WKPageRef page, double pagesPerView);
+WK_EXPORT double WKPageGetPageLength(WKPageRef page);
 WK_EXPORT void WKPageSetGapBetweenPages(WKPageRef page, double gap);
 WK_EXPORT double WKPageGetGapBetweenPages(WKPageRef page);
 
index 8bb1ab7631fc3484677cb05cb5c21d6d94b21297..fc2ca4f9592e655fbf3c9d223afa10b1675f68f9 100644 (file)
@@ -234,6 +234,16 @@ static inline NSURL *autoreleased(WKURLRef url)
     return WKPaginationModeUnpaginated;
 }
 
+- (void)setPageLength:(CGFloat)pageLength
+{
+    WKPageSetPageLength(self.pageRef, pageLength);
+}
+
+- (CGFloat)pageLength
+{
+    return WKPageGetPageLength(self.pageRef);
+}
+
 - (void)setGapBetweenPages:(CGFloat)gapBetweenPages
 {
     WKPageSetGapBetweenPages(self.pageRef, gapBetweenPages);
index c597ffeb1ac7f82c956cb3d43d39abdd4c9879e2..3585642d39321884875d1671020f36b63dd500b5 100644 (file)
@@ -35,6 +35,8 @@ typedef NSUInteger WKBrowsingContextPaginationMode;
 @interface WKBrowsingContextController (Private)
 
 @property WKBrowsingContextPaginationMode paginationMode;
+// Set to 0 to have the page length equal the view length.
+@property CGFloat pageLength;
 @property CGFloat gapBetweenPages;
 
 @property(readonly) NSUInteger pageCount;
index e3599ba61b74760ed143c58425fc6d2955e9a92a..ae78afc285c60b539b7f9d249776db59a393cc77 100644 (file)
@@ -161,6 +161,7 @@ WebPageProxy::WebPageProxy(PageClient* pageClient, PassRefPtr<WebProcessProxy> p
     , m_areMemoryCacheClientCallsEnabled(true)
     , m_useFixedLayout(false)
     , m_paginationMode(Page::Pagination::Unpaginated)
+    , m_pageLength(0)
     , m_gapBetweenPages(0)
     , m_isValid(true)
     , m_isClosed(false)
@@ -1296,6 +1297,18 @@ void WebPageProxy::setPaginationMode(WebCore::Page::Pagination::Mode mode)
     process()->send(Messages::WebPage::SetPaginationMode(mode), m_pageID);
 }
 
+void WebPageProxy::setPageLength(double pageLength)
+{
+    if (pageLength == m_pageLength)
+        return;
+
+    m_pageLength = pageLength;
+
+    if (!isValid())
+        return;
+    process()->send(Messages::WebPage::SetPageLength(pageLength), m_pageID);
+}
+
 void WebPageProxy::setGapBetweenPages(double gap)
 {
     if (gap == m_gapBetweenPages)
@@ -3191,6 +3204,7 @@ WebPageCreationParameters WebPageProxy::creationParameters() const
     parameters.useFixedLayout = m_useFixedLayout;
     parameters.fixedLayoutSize = m_fixedLayoutSize;
     parameters.paginationMode = m_paginationMode;
+    parameters.pageLength = m_pageLength;
     parameters.gapBetweenPages = m_gapBetweenPages;
     parameters.userAgent = userAgent();
     parameters.sessionState = SessionState(m_backForwardList->entries(), m_backForwardList->currentIndex());
index 8212417a380bda394f8bec8c751079196b35ee90..5ef294b0be233c38b1ddda2b968d6d5b0abe2abf 100644 (file)
@@ -415,6 +415,8 @@ public:
 
     void setPaginationMode(WebCore::Page::Pagination::Mode);
     WebCore::Page::Pagination::Mode paginationMode() const { return m_paginationMode; }
+    void setPageLength(double);
+    double pageLength() const { return m_pageLength; }
     void setGapBetweenPages(double);
     double gapBetweenPages() const { return m_gapBetweenPages; }
     unsigned pageCount() const { return m_pageCount; }
@@ -900,6 +902,7 @@ private:
     WebCore::IntSize m_fixedLayoutSize;
 
     WebCore::Page::Pagination::Mode m_paginationMode;
+    double m_pageLength;
     double m_gapBetweenPages;
 
     // If the process backing the web page is alive and kicking.
index 97945bf96954dc8c6f606bdf1b2e8091123258ee..de644df83ce4508effad6ba44519d0888797b639 100644 (file)
@@ -249,6 +249,7 @@ WebPage::WebPage(uint64_t pageID, const WebPageCreationParameters& parameters)
     setDrawsTransparentBackground(parameters.drawsTransparentBackground);
 
     setPaginationMode(parameters.paginationMode);
+    setPageLength(parameters.pageLength);
     setGapBetweenPages(parameters.gapBetweenPages);
 
     setMemoryCacheMessagesEnabled(parameters.areMemoryCacheClientCallsEnabled);
@@ -934,6 +935,13 @@ void WebPage::setPaginationMode(uint32_t mode)
     m_page->setPagination(pagination);
 }
 
+void WebPage::setPageLength(double pageLength)
+{
+    Page::Pagination pagination = m_page->pagination();
+    pagination.pageLength = pageLength;
+    m_page->setPagination(pagination);
+}
+
 void WebPage::setGapBetweenPages(double gap)
 {
     Page::Pagination pagination = m_page->pagination();
index cdf196dd61b498ab03c40c851bc304f57b17726f..8ab02f992ae8089d5c0d796340ae6971e9b41af8 100644 (file)
@@ -268,6 +268,7 @@ public:
     void setFixedLayoutSize(const WebCore::IntSize&);
 
     void setPaginationMode(uint32_t /* WebCore::Page::Pagination::Mode */);
+    void setPageLength(double);
     void setGapBetweenPages(double);
 
     bool drawsBackground() const { return m_drawsBackground; }
index d755f5eed3a273cb08342dd19aebec8c7dcdd37c..b9787edbc3df2ea32bc9de6acfabcfdf47fcd519 100644 (file)
@@ -122,6 +122,7 @@ messages -> WebPage {
     SetFixedLayoutSize(WebCore::IntSize size)
 
     SetPaginationMode(uint32_t mode);
+    SetPageLength(double pageLength);
     SetGapBetweenPages(double gap);
 
     # Find.