|
Re: Centering image view in scroll view
I don’t think there’s any magical solution. From what I see in Preview, it has a 2-phase approach — it lets you zoom normally via a pinch gesture (that is, doesn’t force any centering), then
I don’t think there’s any magical solution. From what I see in Preview, it has a 2-phase approach — it lets you zoom normally via a pinch gesture (that is, doesn’t force any centering), then
|
By
Quincey Morris
·
#416
·
|
|
Re: Simple iOS App with Foundation InputStream and OutputStream...
Hi Brandon.
One other consideration with iOS is that you may need to whitelist the destinations you want to connect to by declaring them in your info.plist under the NSAppTransportSecurity key. I
Hi Brandon.
One other consideration with iOS is that you may need to whitelist the destinations you want to connect to by declaring them in your info.plist under the NSAppTransportSecurity key. I
|
By
listservices@...
·
#415
·
|
|
Re: Simple iOS App with Foundation InputStream and OutputStream...
Just take a look at the header. It’s only the older version that takes an NSHost that’s deprecated:
@interface NSStream (NSSocketStreamCreationExtensions)
+
Just take a look at the header. It’s only the older version that takes an NSHost that’s deprecated:
@interface NSStream (NSSocketStreamCreationExtensions)
+
|
By
Jens Alfke
·
#414
·
|
|
Centering image view in scroll view
Ack. I'm having a hard time figuring out how to make an NSImageView in an NSScrollView act like it does in Preview.app, where it will stay centered within the window when any axis is smaller than the
Ack. I'm having a hard time figuring out how to make an NSImageView in an NSScrollView act like it does in Preview.app, where it will stay centered within the window when any axis is smaller than the
|
By
Steve Mills
·
#413
·
|
|
Re: Simple iOS App with Foundation InputStream and OutputStream...
Jens,
Thanks for reply. I thought the +[NSStream getStreamsToHostWithName:…] was deprecated in iOS 11+?
--Brandon
On Nov 15, 2017, at 12:41, Jens Alfke <jens@...> wrote:
Jens,
Thanks for reply. I thought the +[NSStream getStreamsToHostWithName:…] was deprecated in iOS 11+?
--Brandon
On Nov 15, 2017, at 12:41, Jens Alfke <jens@...> wrote:
|
By
Brandon Peters <bap04e@...>
·
#412
·
|
|
Re: Simple iOS App with Foundation InputStream and OutputStream...
Consider using NSURLSessionStreamTask; it’s higher-level with IMHO a better API, and it supports proxies.
If you’re using an NSURL for this, I don’t think you’re doing it correctly. URLs have
Consider using NSURLSessionStreamTask; it’s higher-level with IMHO a better API, and it supports proxies.
If you’re using an NSURL for this, I don’t think you’re doing it correctly. URLs have
|
By
Jens Alfke
·
#411
·
|
|
Simple iOS App with Foundation InputStream and OutputStream...
All,
I created a simple iOS app to connect to a server and receive a message. I am doing this as an example app using InputStream, OutputStream, and StreamDelegate. The Server is a simple Java app
All,
I created a simple iOS app to connect to a server and receive a message. I am doing this as an example app using InputStream, OutputStream, and StreamDelegate. The Server is a simple Java app
|
By
bap04e@...
·
#410
·
|
|
Re: Cancelling dispatch_after?
The way I always do this:
- create a weakSelf, then in the block assign it to a strongSelf, and test strongSelf for nil
- have a property on your class "delayedBlockCancelled" (you can use an ivar
The way I always do this:
- create a weakSelf, then in the block assign it to a strongSelf, and test strongSelf for nil
- have a property on your class "delayedBlockCancelled" (you can use an ivar
|
By
dhoerl
·
#409
·
|
|
Re: Add overflow indicator to text
I'm not sure where my brain was, but I totally blanked this out and was too focused on trying to roll my own. This works just fine in my scenario, even when oddly shaped exclusionPaths are applied.
I'm not sure where my brain was, but I totally blanked this out and was too focused on trying to roll my own. This works just fine in my scenario, even when oddly shaped exclusionPaths are applied.
|
By
Steve Mills
·
#408
·
|
|
TextFields in a Row with AutoLayout
macOS 12.6, Xcode Version 9.1 (9B55).
A window with:
fixedSpace | fixedTextField | fixedSpace | textField(width ≥ 50) | fixedSpace | textField(width ≥ 100) | variableSpace( width ≥ 10)
This
macOS 12.6, Xcode Version 9.1 (9B55).
A window with:
fixedSpace | fixedTextField | fixedSpace | textField(width ≥ 50) | fixedSpace | textField(width ≥ 100) | variableSpace( width ≥ 10)
This
|
By
Gerriet M. Denkmann
·
#407
·
|
|
Re: How to configure NumberFormatter in Xcode
Indeed. The only place where I didn’t look.
Thanks a lot!
Kind regards,
Gerriet.
Indeed. The only place where I didn’t look.
Thanks a lot!
Kind regards,
Gerriet.
|
By
Gerriet M. Denkmann
·
#406
·
|
|
Re: How to configure NumberFormatter in Xcode
Select the formatter and in the Attributes inspector change the Behavior to OS X 10.4+ Custom.
--
Shane Stanley <sstanley@...>
<www.macosxautomation.com/applescript/apps/>,
Select the formatter and in the Attributes inspector change the Behavior to OS X 10.4+ Custom.
--
Shane Stanley <sstanley@...>
<www.macosxautomation.com/applescript/apps/>,
|
By
Shane Stanley
·
#405
·
|
|
How to configure NumberFormatter in Xcode
macOS 12.6, Xcode Version 9.1 (9B55).
I added a NumberFormatter (Decimal) to some TextField. This now shows: “12.345”.
Not bad, but I want to see: “12.3”.
NSNumberFormatter has a property:
macOS 12.6, Xcode Version 9.1 (9B55).
I added a NumberFormatter (Decimal) to some TextField. This now shows: “12.345”.
Not bad, but I want to see: “12.3”.
NSNumberFormatter has a property:
|
By
Gerriet M. Denkmann
·
#404
·
|
|
Re: Add overflow indicator to text
Thanks for the input, everyone. I mentioned that exclusionPaths are used, so the text flows inside arbitrary shapes, mostly comic book balloon type blobs. As such, there's rarely a straight bottom
Thanks for the input, everyone. I mentioned that exclusionPaths are used, so the text flows inside arbitrary shapes, mostly comic book balloon type blobs. As such, there's rarely a straight bottom
|
By
Steve Mills
·
#403
·
|
|
Re: Add overflow indicator to text
This is what we do in a drawing app, which works well for us. When the text box is selected, it shows the + symbol as part of the frame. If not selected that’s not visible, so the text itself
This is what we do in a drawing app, which works well for us. When the text box is selected, it shows the + symbol as part of the frame. If not selected that’s not visible, so the text itself
|
By
Graham Cox
·
#402
·
|
|
Re: Add overflow indicator to text
Quincy, your observation reminds me of how Quark Xpress handled this in circa 1989. It was a surprisingly nice indicator that “there is more to this text box”. I think they may have put a small
Quincy, your observation reminds me of how Quark Xpress handled this in circa 1989. It was a surprisingly nice indicator that “there is more to this text box”. I think they may have put a small
|
By
Alex Zavatone
·
#401
·
|
|
Re: Cancelling dispatch_after?
Yes, that sounds correct. I was thinking that there was a problem for the original caller (the one in whose stack frame the block resides), because the block might have moved after the call returns.
Yes, that sounds correct. I was thinking that there was a problem for the original caller (the one in whose stack frame the block resides), because the block might have moved after the call returns.
|
By
Quincey Morris
·
#400
·
|
|
Re: Add overflow indicator to text
In text layout apps that I’ve used, which can flow text through multiple containers, there’s typically a small box outside the top-left and bottom-right corners of the container frame. The boxes
In text layout apps that I’ve used, which can flow text through multiple containers, there’s typically a small box outside the top-left and bottom-right corners of the container frame. The boxes
|
By
Quincey Morris
·
#399
·
|
|
Add overflow indicator to text
I'm using NSTextContainer with exclusionPaths, NSLayoutManager, and UITextView for rendering text into balloons, and the user can control the font size. When overflow occurs, I'd like to show an
I'm using NSTextContainer with exclusionPaths, NSLayoutManager, and UITextView for rendering text into balloons, and the user can control the font size. When overflow occurs, I'd like to show an
|
By
Steve Mills
·
#398
·
|
|
Re: Cancelling dispatch_after?
No, because then blocks would always be copied to the heap, even in common cases where they don’t escape, like calling NSDictionary’s -enumerateKeysAndValues: method. That would make these a lot
No, because then blocks would always be copied to the heap, even in common cases where they don’t escape, like calling NSDictionary’s -enumerateKeysAndValues: method. That would make these a lot
|
By
Jens Alfke
·
#397
·
|