• 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
Multiple NSTextContainer
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Multiple NSTextContainer


  • Subject: Multiple NSTextContainer
  • From: Leonardo <email@hidden>
  • Date: Fri, 30 May 2014 11:55:46 +0200
  • Thread-topic: Multiple NSTextContainer

I have 3 NSTextViews A, B and C sharing the same text.
To do that I added the second textViewB.textContainer and the third
textViewC.textContainer to the first textViewA.layoutManager.

[textViewA.layoutManager addTextContainer:textViewB.textContainer];
[textViewA.layoutManager addTextContainer:textViewC.textContainer];

It works well. I can see the text flowing from the first to the second and
to the third textView. Now I would like to save all of that to the disk. How
can I do?

I thought to assign an ID to each textView and save the connection scheme as
e.g.:
    texViewA ID 0 connected to
        textViewB ID 1
        textViewC ID 2

So when I reopen the document file I firstly create all the textViews A, B
and C, then I reconnect the 3 textViews using the same API addTextContainer:

Or is a better archiving method?

Regards
-- Leonardo


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: Multiple NSTextContainer
      • From: Graham Cox <email@hidden>
  • Prev by Date: How to write a .icns file
  • Next by Date: NSTextFieldCell Drawing Offset in NSTextView
  • Previous by thread: Re: How to write a .icns file
  • Next by thread: Re: Multiple NSTextContainer
  • Index(es):
    • Date
    • Thread