Re: More elegance than a long if/else

2017-03-11 Thread Quincey Morris
On Mar 11, 2017, at 06:30 , Pascal Bourguignon wrote: > > My argument is that algebraic expressions are clearer than switches. And it’s a *convincing* argument when you switch to a purely arithmetic problem (such as: how to add two numbers). Seriously, though, I

Re: Unicode filenames with Apple File System and UIManagedDocument

2017-03-11 Thread davelist
> On Mar 9, 2017, at 7:31 AM, Chris Ridd wrote: > > >> On 8 Mar 2017, at 22:56, Peter Edberg wrote: >> >>> >>> On Mar 8, 2017, at 1:44 PM, David Reed wrote: >>> >>> Thanks Peter. >>> >>> I am going to try to find time in the next few

Re: More elegance than a long if/else

2017-03-11 Thread Pascal Bourguignon
> On 11 Mar 2017, at 09:57, Quincey Morris > wrote: > > On Mar 10, 2017, at 17:35 , Pascal Bourguignon > wrote: >> >> this is much clearer in intent than return x+y. So much clearer… > > My

Printing in a Mac app with multiple philosophies

2017-03-11 Thread Daryle Walker
There are two IBActions for printing in a Mac app, “print:” and “printDocument:”. The Xcode project samples pick one of those actions to use based on if you requested a document-based app or not. But what are you supposed to do in a mixed-app, one with both NSDocument subclasses and printable

Re: More elegance than a long if/else

2017-03-11 Thread Quincey Morris
On Mar 10, 2017, at 17:35 , Pascal Bourguignon wrote: > > this is much clearer in intent than return x+y. So much clearer… My argument is not that the original solution was clearer because longer, but that it was longer because clearer.