views:

17

answers:

0

Problem: Users need a pdf document generated in a set font and size and a fixed number of lines per page (each line numbered).

Users are entering text into a standard NSTextView. If I just choose File->Print, the default layout will render as much text as will fit onto the page, more than just 25 lines.

I understand that I can use an NSLayoutManager to fill NSTextContainers that I set at a specific size, then insert the text container into a view, then put the view into another view within a NSSrollView, but I'm still at a loss.

I'm hoping someone's dealt with this before. The documentation I'm looking through isn't making it click for me yet.

Thanks!