Using iPad Views From iPhone/iPod Device

Discussion in 'iOS Programming' started by loon3y, May 3, 2016.

  1. loon3y macrumors 65816

    loon3y

    Joined:
    Oct 21, 2011
    #1
    Currently we two storyboards iPad & iPhone.


    In order for us to print we generate a PDF from our View. The problem with this is that when we generate the pdf, we are giving tableview.bounds.

    In theory is it possible to reference the iPad Storyboard and populate the iPad view and use that view for printing.


    since we are generating tableview.bounds it comes out very congested and small on the iPhone. I would really love to use the iPad View if possible.
     
  2. AxoNeuron macrumors 65816

    AxoNeuron

    Joined:
    Apr 22, 2012
    Location:
    The Left Coast
    #2
    No. You would need to actually initialize an instance of a view controller from the iPad storyboard.
     
  3. PhoneyDeveloper macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
    #3
    You would normally set the page size to a standard paper size, like USLETTER or A4. Then either center or scale the view into the paper size. Alternately you can build a view that is offscreen and make it whatever page size you want. There's nothing magical about the iPad size. It's just bigger than iPhone.
     
  4. AxoNeuron macrumors 65816

    AxoNeuron

    Joined:
    Apr 22, 2012
    Location:
    The Left Coast
    #4
    I would suggest creating a UITableView XIB layout file. Initialize an instance of it, draw it off screen or something and just take a screenshot of that view.

    You can set the size to be whatever you want. You could even make it super high res, use huge fonts, and print at 300dpi so that it looks really good.
     

Share This Page