• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Printing page breaks in an attributed string?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Printing page breaks in an attributed string?


  • Subject: Re: Printing page breaks in an attributed string?
  • From: Douglas Davidson <email@hidden>
  • Date: Mon, 5 Jun 2006 09:16:34 -0700


On Jun 4, 2006, at 7:17 PM, Joshua Scott Emmons wrote:

Take a look at TextEdit's MultiplePageView. You can insert a formfeed (\f) character into it and it will cause a page break.


While, empirically, I know this is true (as I've inserted a form feed and seen the page break) I, for the life of me, cannot figure out how this is accomplished. It certainly doesn't happen in in MutiplePageView. That only maps rects to already existing text views, near as I can tell. I don't see any processing that looks for formfeed and creates a new "page" (in this case, a text view) for it.


Is this done automatically by the layout manager? Reading between the lines of the TextEdit example makes me think that it might be the case that, if presented with multiple containers that it must flow text for, the layout manager might interpret a \f as a sign to "skip to the next container". I can't find any documentation on this, though. Can anyone confirm that's what's supposed to happen?


It is the typesetter that interprets form feeds, but yes, that is what happens. There is one notable exception--if the current container is very long, long enough that the typesetter considers it to be effectively infinitely long, then form feeds are ignored. The default size for a text container is of this sort; thus, for example, form feeds are ignored when TextEdit is not in wrap to page mode.


Douglas Davidson

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Printing page breaks in an attributed string? (From: Joshua Scott Emmons <email@hidden>)
 >Re: Printing page breaks in an attributed string? (From: Todd Ransom <email@hidden>)
 >Re: Printing page breaks in an attributed string? (From: Joshua Scott Emmons <email@hidden>)

  • Prev by Date: Issue during group resizing
  • Next by Date: Re: which cocoa wrapper for sqlite should i get?
  • Previous by thread: Re: Printing page breaks in an attributed string?
  • Next by thread: NSTextList question
  • Index(es):
    • Date
    • Thread