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

NSLayoutManager strangeness


  • Subject: NSLayoutManager strangeness
  • From: Duncan Campbell <email@hidden>
  • Date: Fri, 5 Aug 2005 14:57:23 +1000

Hi folks.

I've created an NSTextView subclass with a little piece of code in drawRect: to draw a background shaded rectangle to indicate pagebreaks (like xCode does).

This works a-ok.

However, if I try to use my own NSLayoutManager, my draw code does not work correctly until i press a key.

Even if I simply do:

        NSLayoutManager *lm = [[NSLayoutManager alloc] init];
        [[self textContainer] replaceLayoutManager:lm];
        [lm release];

In my NSTextView's initWithFrame: (i.e. no subclass code at all) things break.

Anyone have any clue what's going on, and how to fix?

Cheers.

D.


_______________________________________________ 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
  • Follow-Ups:
    • Re: NSLayoutManager strangeness
      • From: Satoshi Matsumoto <email@hidden>
  • Prev by Date: Re: NSNumberFormatter localize bug in IB?
  • Next by Date: Converting any NSImageRep to a 16 bits NSImageRep
  • Previous by thread: Re: NSNumberFormatter localize bug in IB?
  • Next by thread: Re: NSLayoutManager strangeness
  • Index(es):
    • Date
    • Thread