Helper function to start a new page. Not intended for external use.
195954
def _new_page(self):
        
        self._current_page = Drawing(*self._pagesize)
        if self._bgimage:
            self._current_page.add(self._bgimage)
        self._pages.append(self._current_page)
        self.page_count += 1
        self._position = [1, 0]
1078220
function start() {
  if (isStarted()) {
    return;
  }

  // Debounce the scroll event by executing the onScroll callback using a timed
  // interval.
  window.addEventListener('scroll', onScroll_, {'passive': true});
  interval = window.setInterval(function() {
    if (scrolled) {
      for (var i = 0, delegate; delegate = delegates[i]; i++) {
        delegate.onScroll();
      }
      scrolled = false;
    }
  }, 250);
}
1071497
def _create_blank_page(self):
        """"""
        loading_template = Template(BLANK)
        page = loading_template.substitute(css_path=self.css_path)
        return page
839381
function (newPage) {
			this.writeDebug('paginationChange',arguments);

			// Page change callback
			if (this.settings.callbackPageChange) {
				this.settings.callbackPageChange.call(this, newPage);
			}

			mappingObj.page = newPage;
			this.mapping(mappingObj);
		}
55749
def append_page(page = Page.new)
            init_page_tree

            self.Catalog.Pages.append_page(page)
            yield(page) if block_given?

            self
        end
1089096
protected void newPage() {
		if (!bean.isSubreport()) {
			try {
				stream.print("</table>\n");
				stream.println("<p style=\"page-break-before: always\"></p>\n");
				if (bean.getReportLayout().isUseSize()) {
		            stream.print("<table>");
		        } else {
		            stream.print("<table style='width:100%'>");
		        }
				if (bean.getReportLayout().isHeaderOnEveryPage()) {					
					printHeaderBand();					
				}
			} catch (Exception e) {
				e.printStackTrace();
			}
		}
	}
1255132
function startModulesAfterPageLoad( lo ) {
  // header hooks
  if ( ( lo != null ) && ( lo.header != null ) && ( lo.header.modules != null ) ) {
    for ( var i = 0; i < lo.header.modules.length; i++ ) {
      startModuleAfterPageLoad( lo.header.modules[i] );
    }
  }
  // footer hooks
  if ( ( lo != null ) && ( lo.footer != null ) && ( lo.footer.modules != null ) ) {
    for ( var i = 0; i < lo.footer.modules.length; i++ ) {
      startModuleAfterPageLoad( lo.footer.modules[i] );
    }
  }
  ajaxOngoing--;
}
372722
def generate_referral(self, start_page, destination_page):
        
        if not page_utils.is_valid_url(destination_page):
            raise Exception(
                "Exception: destination_page {%s} is not a valid URL!"
                % destination_page)
        if start_page:
            if not page_utils.is_valid_url(start_page):
                raise Exception(
                    "Exception: start_page {%s} is not a valid URL! "
                    "(Use an empty string or None to start from current page.)"
                    % start_page)
            self.open(start_page)
            time.sleep(0.08)
            self.wait_for_ready_state_complete()
        referral_link = ('''<body>'''
                         '''<a class='analytics referral test' href='%s' '''
                         '''style='font-family: Arial,sans-serif; '''
                         '''font-size: 30px; color: #18a2cd'>'''
                         '''Magic Link Button</a></body>''' % destination_page)
        self.execute_script(
            '''document.body.outerHTML = \"%s\"''' % referral_link)
        self.click(
            "a.analytics.referral.test", timeout=2)  # Clicks generated button
        time.sleep(0.15)
        try:
            self.click("html")
            time.sleep(0.08)
        except Exception:
            pass
444877
def _get_whitelist_page_generator(self, start_page=0, page_size=None):
        

        return Page.get_page_generator(self.get_whitelist_page, start_page, page_size)
674533
def from(start)
      raise InvalidPageStart if start.nil? || start.empty?
      raise EventNotFound.new(start) unless reader.has_event?(start)
      Specification.new(reader, result.dup { |r| r.start = start })
    end
197129
function (page) {
            var index = util.clamp(page - 1, 0, this.numPages),
                $precedingPage,
                $currentPage;

            paged.setCurrentPage.call(this, page);

            // update CSS classes
            this.$doc.find('.' + CSS_CLASS_PRECEDING_PAGE)
                .removeClass(CSS_CLASS_PRECEDING_PAGE);

            $precedingPage = this.$doc.find('.' + CSS_CLASS_CURRENT_PAGE);
            $currentPage = this.$pages.eq(index);

            if ($precedingPage[0] !== $currentPage[0]) {
                $precedingPage
                    .addClass(CSS_CLASS_PRECEDING_PAGE)
                    .removeClass(CSS_CLASS_CURRENT_PAGE);
                $currentPage.addClass(CSS_CLASS_CURRENT_PAGE);
            }

            this.updateVisiblePages(true);
            this.updatePageClasses(index);
        }
633004
def create_bookmark_action(parent, url, title, icon=None, shortcut=None):
    """"""
    
    @Slot()
    def open_url():
        return programs.start_file(url)
    
    return create_action( parent, title, shortcut=shortcut, icon=icon,
                          triggered=open_url)
109809
function ezNewPage()
    {
        $pageRequired = 1;
        if ( isset( $this->ez['columns'] ) && $this->ez['columns']['on'] == 1 )
        {
            // check if this is just going to a new column
            // increment the column number

            $this->ez['columns']['colNum']++;
            if ( $this->ez['columns']['colNum'] <= $this->ez['columns']['options']['num'] )
            {
                // then just reset to the top of the next column
                $pageRequired=0;
            }
            else
            {
                $this->ez['columns']['colNum'] = 1;
                $this->ez['topMargin'] = $this->ez['columns']['margins'][2];
            }

            $width = $this->ez['columns']['width'];
            $this->ez['leftMargin'] = $this->ez['columns']['margins'][0] + ( $this->ez['columns']['colNum'] - 1 ) * ( $this->ez['columns']['options']['gap'] + $width );
            $this->ez['rightMargin'] = $this->ez['pageWidth'] - $this->ez['leftMargin'] - $width;
        }

        if ( $pageRequired )
        {
            // make a new page, setting the writing point back to the top
            $this->y = $this->ez['pageHeight']-$this->ez['topMargin'] - $this->getFontHeight();
            $this->ez['xOffset'] = 0;
            // make the new page with a call to the basic class.
            $this->ezPageCount++;
            if ( isset( $this->ez['insertMode'] ) && $this->ez['insertMode'] == 1 )
            {
                $id = $this->ezPages[$this->ezPageCount] = $this->newPage( 1, $this->ez['insertOptions']['id'], $this->ez['insertOptions']['pos'] );
                // then manipulate the insert options so that inserted pages follow each other
                $this->ez['insertOptions']['id'] = $id;
                $this->ez['insertOptions']['pos'] = 'after';
            }
            else
            {
                $this->ezPages[$this->ezPageCount] = $this->newPage();
            }
        }
        else
        {
            $this->y = $this->ez['pageHeight']-$this->ez['topMargin'] - $this->getFontHeight();
            $this->ez['xOffset'] = 0;
        }
        $this->RightMarginArray = array();
        $this->LeftMarginArray = array();
    }
453134
def add_page(self, page, default = True):
        
        """
        self._pages[page.page_id] = page
        page._add_display(self)
        if default or not self._active_page:
            self._active_page = page
226243
def starter(cls):
        """"""
        data = cls.getPage(cls.url)
        url1 = cls.fetchUrl(cls.url, data, cls.prevSearch)
        data = cls.getPage(url1)
        url2 = cls.fetchUrl(url1, data, cls.nextSearch)
        return cls.prevUrlModifier(url2)
560631
def check_page(fn):
        ""
        @wraps(fn)
        def wrapper(self, *args, **kwargs):
            if not self.page and not kwargs.get('split_only'):
                self.error("No page open, you need to call add_page() first")
            else:
                return fn(self, *args, **kwargs)
        return wrapper
40207
def startElement (self, name, attrs):
                '''
                '''
                func = getattr(self, 'start_' + name, None)
                if func:
                        func(attrs)