Re: Adjusting Font Size to fit View Rectangle
Sandor Szatmari
Multiline, or single line?
toggle quoted messageShow quoted text
Sandor
On Sep 19, 2018, at 14:29, Dave <dave@looktowindward.com> wrote:
|
|
Can NSView and NSImageView respond to Mouse Clicks?
Dave
Hi,
Can an Custom NSView respond to Mouse Clicks via IBActions? Can the same be done with NSImageView? I’ve added an image view and connected it to an IBAction method define in my View Controller, but when I click the NSImageView nothing happens….. Any help greatly appreciated. All the Best Dave
|
|
Adjusting Font Size to fit View Rectangle
Dave
Hi All,
Is there a Cocoa method I can use that will return the best fitting Font Size for a given String and Font? I seem to remember using a method that does it but can’t seem to find it any more….. All the Best Dave
|
|
Re: Segue
Gerriet M. Denkmann
On 19 Sep 2018, at 20:35, Steve Mills via Groups.Io <sjmills=mac.com@groups.io> wrote:The Xcode template Master-Detail App does it without custom transition animation. It uses: Master : UITableViewController → UINavigationController → Detail : UIViewController Detail slides in from right, and the user can remove the topmost view controller using the back button in the navigation bar or using a left-edge swipe gesture. The only way I got it to work: Master : UITableViewController → Detail : UIViewController Storyboard Segue Kind = Show (e.g. Push) Transition Style and Presentation of Master seems to have no effect. Gerriet.
|
|
Re: Segue
Alex Zavatone
Change the Kind of the segue. You’re going to want it set to Show (e.g. Push).
toggle quoted messageShow quoted text
Also check below in the right panel and see which Presentation and which Transition you use.
|
|
Re: Segue
Steve Mills
On Sep 19, 2018, at 05:14:11, Gerriet M. Denkmann <g@mdenkmann.de> wrote:
Perhaps you just need to provide a custom transition animation. See this guide: https://developer.apple.com/library/archive/featuredarticles/ViewControllerPGforiPhoneOS/CustomizingtheTransitionAnimations.html -- Steve Mills Drummer, Mac geek
|
|
Segue
Gerriet M. Denkmann
iOS 11, Xcode 10
I have an UITableViewController and the UITableViewCells have a Detail Accessory with an accessory action = Navigation Controller Show Detail The UITableViewController does prepareForSegue. The Storyboard Segue is of Kind Show Detail (e.g. Replace) and it Animates. But: the Detail View slides in from *below* (expect: from right); sliding the Detail View from left to right does *not* get back to the UITableViewController and on top there is no “< Master” button which does the same. I tried to copy the Master-Detail App (supplied by Xcode) as closely as possible. Everything looks the same, but it behaves differently. What am I doing wrong? Gerriet.
|
|
Re: iOS: TableView inside ScrollView
Gerriet M. Denkmann
On 19 Sep 2018, at 07:16, Quincey Morris <quinceymorris@rivergatesoftware.com> wrote:Yes. It certainly looks better than my current work-around: NSLayoutConstraint *heightConstraint = self.tableView.constraints.firstObject; heightConstraint.constant = nbr of rows in table * row height; The documentation says: “See the Settings application for examples of grouped tables.” So I am going to implement this. Thanks a lot. Kind regards, Gerriet.
|
|
Re: iOS: TableView inside ScrollView
Quincey Morris
On Sep 18, 2018, at 01:47 , Gerriet M. Denkmann <g@...> wrote:
Keep in mind that UITableView is a kind of UIScrollView, which isn’t how NSTableView works. Your intended solution nests a scroll view within a scroll view, which is kind of hard to know how to lay out satisfactorily. Steve’s suggestion of a table view with 3 sections is a good solution.
|
|
Re: XPC Question
Sandor Szatmari
On Sep 18, 2018, at 12:46, Jens Alfke <jens@...> wrote:
We have several in house apps using DO over the LAN (in a 10.12 environment, in deployment since 10.5 or 10.4 if not earlier) and aside from security concerns for public use it has been great for implementing RPC. We’ve had these services running for many years and they have been very stable. As long as you know the demarcation between local and remote, things go smoothly. I am looking to implement some new functionality and wanted to make sure there was nothing I was overlooking. I don’t think I’ll use DO as I’d like to not continue a dependency on outdated technology. I would prefer to not have to implement my own protocol at a low level. Any higher level options you can suggest would be appreciated. The scenario is a launchd daemon running on multiple machines that can be controlled by a console app. Send commands from the console app to the daemons, read statuses from the daemons. Thanks! Sandor
|
|
Re: XPC Question
On 18 Sep 2018, at 9:46 am, Jens Alfke <jens@mooseyard.com> wrote:This thread would be incomplete without at least a nostalgic mention of Distributed Objects though! https://developer.apple.com/library/archive/documentation/Cocoa/Conceptual/DistrObjects/Concepts/AboutDistributedObjects.html (The revision history page is a sobering testament to its obsoleteness) b
|
|
Re: XPC Question
Not as far as I know. In general, it’s a bad idea to use this sort of “hidden” RPC across a network. Networking is fundamentally unlike local function calls, and making a network call look exactly like a method call hides those differences and makes it easy to run into problems handling failures, dealing with protocol changes, enforcing security, and more. Unfortunately Apple doesn’t have any good frameworks for implementing messaging between computers, especially on the listener (“server”) end. The best general purpose protocol right now is probably WebSockets, but there’s still no support for it in Apple’s frameworks, and it’s not easy to implement yourself. —Jens
|
|
Re: iOS: TableView inside ScrollView
Steve Mills
On Sep 18, 2018, at 03:47:36, Gerriet M. Denkmann <g@mdenkmann.de> wrote:
That's simply a table view with static sections, and each section has a set number of rows. The Choose a Network section has variable number of rows, added programmatically. You don't need to add these things to a scroll view - the table view takes care of that. -- Steve Mills Drummer, Mac geek
|
|
XPC Question
Sandor Szatmari
Can you do XPC RPC over an IP connection? Or, in other words… Can you do XPC between two computers?
Thanks, Sandor
|
|
iOS: TableView inside ScrollView
Gerriet M. Denkmann
iOS 11, Xcode 10
I have a view with an UIScrollView, which is bound on all 4 sides to the save area. This ScrollView contains: UILabel UITableView UILabel The problem: if the TableView does *not* have a definite height, then Xcode complains: “The ScrollView needs y-position or height fixed”. But the whole point of the TableView is that the number of rows can change at run time. The effect I want is similar to Settings → Wi-Fi where unter “Choose a Network” there is a dynamically changing list of names. And the whole page can be scrolled vertically. How to achieve this? Gerriet.
|
|
Re: Window Position and Size Restored
Dave
Got it thanks, I knew there was a property for it somewhere, but was looking in the wrong pane.
toggle quoted messageShow quoted text
On 17 Sep 2018, at 17:07, Jon Gotow <gotow@stclairsoft.com> wrote:
|
|
Re: Window Position and Size Restored
Andy Lee
Try unchecking the "Restorable" checkbox in IB. I don't know why you aren't able to manually "override" this. --Andy
On Sep 17, 2018, at 10:56 AM, Dave <dave@...> wrote:
|
|
Re: Window Position and Size Restored
Jon Gotow
See NSWindow.frameAutosaveName. That should take care of it for you.
toggle quoted messageShow quoted text
- Jon
On Sep 17, 2018, at 8:56 AM, Dave <dave@looktowindward.com> wrote:
|
|
Re: Maintaining Aspect Ration of a Window
Dave
Thanks a lot, I think this should do the trick!
toggle quoted messageShow quoted text
|
|
Window Position and Size Restored
Dave
Hi,
Mac, Manual Layout. I’m trying to reset the Window Position Size each time my App is run. When I run it under Debug, the Window Position keeps getting restored (AFAICT), I’ve subclassed NSWindow awakeFromNib and have tried resetting the Window FrameRect, but it doesn’t seem to have any affect. I’ve checked and it is getting called ok. I’ve tried setting the Frame before super awakeFromNib is called, but no effect. -(void) awakeFromNib { [super awakeFromNib]; [self setFrame:NSMakeRect(0,0,256,256) display:YES]; } Any suggestions or help greatly appreciated. All the Best Dave
|
|