interface-builder

ios create and then dynamically add UI elements

谁说胖子不能爱 提交于 2019-12-12 20:58:02
问题 I don't know if this is possible but it sounds like something that should be. What i want to do is, to create UIViews (or UIViewControllers not really sure how it would work) in Interface Builder say... 10 of them, and use them according to what the user choose to. For example in state A i wanna show him widgets 1,2 and 3; in state B widgets 3,5 and 7 etc. EDIT: what i mean by state, is that according to what the user chose in the previous steps, they all lead to the same UIViewController but

Orientation handling in Interface Builder

筅森魡賤 提交于 2019-12-12 19:55:11
问题 I need to handle orientation (Portrait - Landscape) in my application. Basic layout of my screen is UIView -> UIImageView -> UITableView (Background = ClearColor) (in that z-order) so that it looks like the table has a background image. I need to do the following: Different images in UIImageView in both modes. Each cell in the table needs to have 3/4 images laid out side-by-side (3 in portrait and 4 in landscape). All of this needs to be done in the interface builder (to the maximum possible

NSWindowController circular dependency caused by bindings?

流过昼夜 提交于 2019-12-12 19:12:20
问题 Suppose you have a window nib, owned by a NSWindowController which loads the nib. The NSWindowController has an IBOutlet bound (via Interface Builder) to a UI control on the window. Is it true that you can't dispose the window controller by releasing it because the binding causes a unbreakable circular dependency between the window controller and the control? Do you know any common situation which may lead to similar circular dependencies? 回答1: In situations like this, writing a focused

Made a change in Interface Builder, Xcode is not showing it

扶醉桌前 提交于 2019-12-12 18:08:58
问题 So here is what my interface looks like at the moment: Here is what I have changed it to in Interface Builder: This is what is shown after I run it in Xcode: Obviously the two programs are not communicating - if someone could point me in the right direction it would be great. Thanks heaps! 回答1: If stuff isn't in sync, try cleaning your build. Product>Clean should do the trick. 回答2: The programs communicate through the NIB/XIB files. Make sure you have saved your changes from Interface Builder

How to Wrap words in UILabel

。_饼干妹妹 提交于 2019-12-12 17:23:15
问题 I have a UILabel thats inside a Custom UITableViewCell, I am trying to get the word to wrap inside the UILabel.. But I am having some issues. This is how the UITableViewCell looks in Interface Builder The UILabel Label needs to wrap.. So in Interface Builder I have set the labels lines to 0 (which I think means multiple lines), and the line break to words.. which should wrap the words.. However now I think I have to put some code into something so that if the word wraps it expands the cell..

Can I add an NSManagedObject to the selected parent object just using Interface Builder and Core Data?

眉间皱痕 提交于 2019-12-12 16:42:33
问题 I'm learning Core Data and at the moment just using Interface Builder and the XCode data model (following the Aaron Hillegass Cocoa book examples). I have an MVC application and core data set up and working within interface builder (no hand-written code yet). I've set up various arraycontrollers, views and buttons to add and remove objects and edit data and determine relationships between objects. However my object model is strictly hierarchical parent-child (and grandchildren) and each

NSColorWell not sending action on click?

心不动则不痛 提交于 2019-12-12 16:17:17
问题 Inside my .xib, I've placed an NSColorWell inside an NSView , and connected an IBAction in the controller to the NSColorWell 's Sent Actions (via File's Owner). I figured I would respond to a click in my controller and send activate to bring up the NSColorPanel . But unlike other my controls, I'm not getting the IBAction called. Clicking invokes a drag action on the color. I noticed this control doesn't derive from NSActionCell (like all my other controls). What's the proper control that is

MonoTouch - missing header files when editing xib [duplicate]

时间秒杀一切 提交于 2019-12-12 16:17:00
问题 This question already has answers here : Missing h-files and Assistant Editor not working because of it (monoTouch/MonoDevelop) (3 answers) Closed 6 years ago . I am on Mac OSX Lion 10.7.0 with Xcode 4.2 for IOS 5 and Xamarin's MonoTouch. ("Cross platform mobile development tools that allow you to use C# and .NET to create apps for iOS and Android") and on VMWare 8.0.0 on Ubuntu 11.10. I am testing MonoTouch and when I follow this tutorial then at one step, I have to do my xib file with xcode

Cocoa Bindings: Binding to the “many” end of a to-many relationship

╄→尐↘猪︶ㄣ 提交于 2019-12-12 13:48:29
问题 Using the Employees-Departments example what I want to do is bind a column to "Departments.arrangedObjects.employees.@sum.hoursWorked" as outlined below: Entity Employee attributes: "firstName", "lastName", "hoursWorked" relationship: "departments" Entity Department attributes: "name" relationship: "employees" I want a table which will display some summary info about departments. I bind the first column to my "Departments" array controller, "arrangedObjects.name". I can have a column

App frozen by UIKit after upgrading to Xcode 7

扶醉桌前 提交于 2019-12-12 13:15:23
问题 After upgrading my project to Swift 2.0 and using Xcode 7 (GM) I noticed some of my view controllers freeze the app on navigation. Instruments show me that CPU usage is over 9000% and is used by UIKit and Foundation. Have you encountered this problem? 回答1: It seems to be one of those Interface Builder issues. I've successfully defeated this by removing any text from UITextView in storyboard. And it comes again if I set text property back. Hopefully, this will help someone to not waste