def renderPageSelectorOn(r)
    r.cssId(:nav)
    r.center do
      if @page.contents == self.allPages.first then
        r.text('<<')
      else
        r.anchorWithAction_text(proc do self.prevPage end, '<<')
      end
      self.allPages.each_with_index do |ea, i|
        r.space
        text = ea.copyAfter(?e)
        if @page.contents == ea then
          r.text(i)
        else
          r.anchorWithAction_text(proc do
            self.choosePage(ea) end,
            i)
        end
      end
      r.space
      if @page.contents == self.allPages.last then
        r.text('>>')
      else
        r.anchorWithAction_text(proc do self.nextPage end, '>>')
      end
    end
  end