Posts

Post marked as solved
1 Replies
130 Views
There is a new Integrate menu in XCode. Does anyone know how to use it? I stage my changes. Then I try to commit and can't make it do anything. I have looked for docs on this, found nothing useful. What's the process?
Posted Last updated
.
Post marked as solved
2 Replies
609 Views
You know how XCode shows your compile errors in real time with the red ribbons to the right of the code? Now they are not there. Or they might appear occasionally after a deliberate build, but then they disappear after a few seconds, or after I click on anything. I can't write code like this. Yes, I have restarted. Didn't help. Is there some new configuration I have to set?
Posted Last updated
.
Post marked as solved
1 Replies
374 Views
NSMutableAttributedString does strange things with 𝛑 and 𝒆. This is Unicode "Mathematical Bold Small Pi" and the 𝒆 that is near it in the Unicode table. Less exotic characters don't have this problem. Changing the attribute map of an existing NSMutableAttributedString containing these characters with some foreground colors (like white, for instance) results in a strange doubling of the character when the resulting string is rendered in a CATextLayer. It doesn't happen if the NSMutableAttributedString is created with the different map. It only happens when you use #setAttributes on an existing string. Displaying an NSMutableAttributedString containing these characters with various colors applied in a UITextField results in the strange doubling regardless of the colors involved. Furthermore, attribute ranges are thrown off by this.
Posted Last updated
.
Post not yet marked as solved
2 Replies
428 Views
In iPadOS, I'm building a tree on the screen using CALayer subclasses. Touching a visible node on the screen selects the node using CALayer.hitTest(CGPoint). This works reliably when I arrange the layers like this: But when I rearrange the same CALayer objects to look like this, after an unpredictable number of touches on the a*b composite structure, the app dies with EXC_BAD_ACCESS: Here is my code at the point of death. The LOOK HERE print statement just before invoking hitTest verifies that both layer and ksCGPoint have reasonable values. Here is the stack trace: Here is where the code actually dies in computeZ, which is called by CALayer.hitTest, which is invoked by VNode.touchesBegan, where VNode is a subclass of UIView. Does anyone know what's going on here, or how to fix it?
Posted Last updated
.
Post not yet marked as solved
3 Replies
937 Views
I am moving layers around using UIView.animate(withDuration:,animations:,completion:). The animation works as it is supposed to, but changing the duration parameter doesn't change the duration. It always goes at the same speed. What might I be doing wrong? Is there some global thing I have to turn on for this to work?
Posted Last updated
.
Post not yet marked as solved
0 Replies
278 Views
I imported an external project into my project by dragging its project file into mine. It didn't work. Now those files show up whenever I check something in. I don't want them and I never select them at checkin, but how do I get rid of them? I don't find them in the underlying file system, and I haven't found any controls that will get rid of them. They appear in the source control navigator under the changes tab as Local Changes.
Posted Last updated
.
Post not yet marked as solved
4 Replies
539 Views
I need to specify certain strings in my RTF documents as non-breaking, but haven't found a way to do this. Any suggestions?
Posted Last updated
.
Post not yet marked as solved
4 Replies
827 Views
I have a newer iPad and an older iPad2. My app is written in Swift and compiled for 9.3.5, which is the OS installed on the older iPad2. ***My app runs fine in the simulator and on the newer iPad.*** On the older iPad2, a lot of mundane things work in the app, but it crashes with errors that are only semi-repeatable when I ask it to do its real work. The problem seems to have something to do with an object being garbage collected before it should be, but I am not sure that is really the problem, as the debugger sometimes gives other death messages that are completely different. Any ideas on this?
Posted Last updated
.
Post not yet marked as solved
2 Replies
484 Views
I use UITextView to display rtf text loaded from a file. The text has links in it. Tapping a link opens the correct page in Safari. Then I go back to my app. When I tap another link, or even the same one, nothing happens. Is there some kind of reset that I have to invoke on UITextView to make this behave correctly?
Posted Last updated
.
Post not yet marked as solved
2 Replies
278 Views
My app is configured for iOS 9.3.5. It runs fine on newer versions of iOS. But when I run it on an actual 9.3.5 device (iPad2 from 2011) it crashes with memory management issues. In particular, when a specific class is instantiated, the allocation is visible in the stack trace and the init runs. But as soon as I put anything into its instance variables, the deinit runs on that instance and the app crashes. I put a print statement at the start of the init method. That executes just fine. The next line is where value initializations begin, and that is where the deinit is invoked behind my back. I don't know why it would do this. Do you?
Posted Last updated
.
Post marked as solved
2 Replies
370 Views
I'm building an iPad app. I have a custom screen keyboard attached to a text field, which all works. But when it pops up, there is this other thing on top of it, containing four controls. These appear to be undo and redo arrows, copy-to-pasteboard, and a down-arrow over on the right. The down-arrow on the right makes this extra stuff go away, but not permanently. The other three controls don't seem to do anything. I don't want this stuff. I haven't figured out how to make it go away in code. I tried setting the text field's inputAccessoryView to nil. Didn't help. What is this thing? How do I make it go away? If I wanted to use it, how would I?
Posted Last updated
.
Post marked as solved
1 Replies
1.6k Views
I am using UITextFieldDelegate.textField(_,shouldChangeCharactersin,replacementString) in my ViewController. I receive the correct input from my app's software keyboard. But the hardware keyboards on my iPad and my simulator both deliver uppercase characters only to my app. This won't do. Yes, I have checked the keyboards' CapsLock state. Suggestions?
Posted Last updated
.
Post marked as solved
3 Replies
1.3k Views
How to make UIAlertController modal in iOS 9.3? The dialog box comes up, looks right and works correctly, but the app doesn't wait for an answer. I'm using #present(_,animated:,completion:) to bring it up. Even the completion block runs before the user can do anything. There is some API from versions long after 9.3 that might help if I was targeting later versions, but I'm not. I have read a bunch of articles on the net: they all say this easy, and it is easy, but it isn't modal.
Posted Last updated
.
Post not yet marked as solved
2 Replies
1.3k Views
A few days ago, I downloaded and installed the most recent Xcode update. My project immediately broke. Lots of unexplainable error messages. Spent a lot of time googling error messages. Saw something about colons no longer working in project names or directories. This is kind of a rude shock. Is it true? Is anyone at Apple willing to reconsider this? My project is now a mess from trying to reconfigure things to work.
Posted Last updated
.