• 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: AutoLayout textfield against accessory view
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: AutoLayout textfield against accessory view


  • Subject: Re: AutoLayout textfield against accessory view
  • From: Jonathan Mitchell <email@hidden>
  • Date: Wed, 20 Aug 2014 22:07:36 +0100

On 20 Aug 2014, at 05:26, Luther Baker <email@hidden> wrote:

> I'd like to place a UITextField in the center of a UITableViewCell such
> that initially, the textfield extends to all four sides.
>
> But ... I'd also like to make it AccessoryView friendly. Namely, when the
> accessory appears (or is always appearing) I want the aforementioned
> textField to shrink and not overlap the accessory. I want my textField's
> TRAILING attached to the accessoryView's LEADING.
>
> Thoughts? My initial pass complains about objects in different hierarchies.

I would likely initially retain a reference to the UITextField trailing constraint.
When the accessory view is displayed delete the above constraint and replace it with one that links the textview to the accessory.

J
_______________________________________________

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


References: 
 >AutoLayout textfield against accessory view (From: Luther Baker <email@hidden>)

  • Prev by Date: Re: Issuing NSTextField action message
  • Next by Date: Re: Good way to have default relationship to override nil?
  • Previous by thread: AutoLayout textfield against accessory view
  • Next by thread: Why do my WebView controls do a mini-reload when they become key?
  • Index(es):
    • Date
    • Thread