which_page_number (PDF::Writer)

          # File lib/pdf/writer.rb, line 2157
    2157:   def which_page_number(page_num, scheme = 0)
    2158:     return nil unless @page_numbering
    2159:
    2160:     num   = nil
    2161:     start = start_num = 1
    2162:
    2163:     @page_numbering[scheme].each do |kk, vv|
    2164:       if kk <= page_num
    2165:         if vv.kind_of?(Hash)
    2166:           unless vv[:starting].nil?
    2167:             start = vv[:starting]
    2168:             start_num = kk
    2169:             num = page_num - start_num + start
    2170:           end
    2171:         else
    2172:           num = nil
    2173:         end
    2174:       end
    2175:     end
    2176:     num
    2177:   end