Re: setting tab stops in swift

2015-08-27 Thread Marc Khadpe
It looks like your code should be: let theTabStop: NSTextTab = NSTextTab(type: .LeftTabStopType, location: tabInterval * cnt) Check the documentation on NSTextTab here https://developer.apple.com/library/mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSTextTab_Class/#//apple_ref/occ/

Re: setting tab stops in swift

2015-08-27 Thread Jens Alfke
> On Aug 27, 2015, at 5:32 PM, Boyd Collier wrote: > > I’ve tried > let theTabStop: NSTextTab = NSTextTab(NSLeftTabStopType, loc, > (tabInterval * cnt)) > > but am told that NSLeftTabStopType is an “unresolved identifier”, which I > understand has to do with enums being quite different

setting tab stops in swift

2015-08-27 Thread Boyd Collier
I’m in the process of re-writing some obj-c code in swift for OS X and am stumped on how to set tab stops. The relevant obj-c code looks like this: [paraStyle setTabStops:[NSArray array]]; for (cnt = 1; cnt <= numStops; cnt++) { tabStop = [[NSTextTab alloc

Re: Auto-Layout Again

2015-08-27 Thread Ken Thomases
On Aug 27, 2015, at 10:46 AM, Dave wrote: > >> On 27 Aug 2015, at 16:29, Ken Thomases wrote: >> >> You want the stack view to size itself to match the scroll view? Why? That >> would mean that the scroll view would never scroll, defeating the purpose of >> its existence. > > Sorry match th

Re: Auto-Layout Again

2015-08-27 Thread Conrad Shultz
> On Aug 27, 2015, at 8:07 AM, Jerry Krinock wrote: > > In a hurry here, but, I know Auto Layout does not always play well with > scroll views. If you encounter a situation where Auto Layout is not playing well with NSScrollView (or, really, any view), please file a bug report at https://bug

Re: removeItemAtPath in 10.7

2015-08-27 Thread sqwarqDev
> On 27 Aug 2015, at 04:44, Stephane Sudre wrote: > > Side note, you probably want to change your loop to: > > for(NSString * thisPath in offenderList) > { > } > I normally do use fast enum’; can’t recall why I didn’t do here, but this: > > offenderList.count would then be a NSUInteger and

Re: Auto-Layout Again

2015-08-27 Thread Dave
> On 27 Aug 2015, at 16:29, Ken Thomases wrote: > > On Aug 27, 2015, at 8:41 AM, Dave wrote: > >> I’m trying to setup a StackView inside a ScrollView, I’ve based by code on >> the InfoBarView and the TSInfoBarView sample Apps. Basically I have the >> following elements: >> >> LTWDetailWind

Re: Auto-Layout Again

2015-08-27 Thread Dave
> On 27 Aug 2015, at 16:14, Cosmo wrote: > > Also not enough time to make specific suggestions, except for checking out > this blog post: > > http://natashatherobot.com/ios-autolayout-scrollview/ > > It recently helped me conquer a scrollview layout issue on iOS. My App is Mac, so I’m not su

Re: Auto-Layout Again

2015-08-27 Thread Ken Thomases
On Aug 27, 2015, at 8:41 AM, Dave wrote: > I’m trying to setup a StackView inside a ScrollView, I’ve based by code on > the InfoBarView and the TSInfoBarView sample Apps. Basically I have the > following elements: > > LTWDetailWindowController This is the main Window Controller, the Windo

Re: Auto-Layout Again

2015-08-27 Thread Dave
> On 27 Aug 2015, at 16:07, Jerry Krinock wrote: > > In a hurry here, but, I know Auto Layout does not always play well with > scroll views. Thanks, even more reason to ditch it then, because it probably won’t work even if I manage to set up the constraints in XCode/IB , I’m going to give it

Re: Auto-Layout Again

2015-08-27 Thread Cosmo
Also not enough time to make specific suggestions, except for checking out this blog post: http://natashatherobot.com/ios-autolayout-scrollview/ It recently helped me conquer a scrollview layout issue on iOS. > On Aug 27, 2015, at 8:07 AM, Jerry Krinock wrote: > > In a hurry here, but, I know

Re: Auto-Layout Again

2015-08-27 Thread Jerry Krinock
In a hurry here, but, I know Auto Layout does not always play well with scroll views. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins

Auto-Layout Again

2015-08-27 Thread Dave
Hi, I’m still trying to get my head around Auto-Layout and how to set it up in XCode. I’m trying to setup a StackView inside a ScrollView, I’ve based by code on the InfoBarView and the TSInfoBarView sample Apps. Basically I have the following elements: LTWDetailWindowController This is

Re: NSSegmentedControl & NSSegmentStyleSeparated & autolayout

2015-08-27 Thread Arjan van Leeuwen
Hi Thaddeus, On Wed, Aug 26, 2015 at 6:20 PM, Thaddeus Cooper wrote: > I just checked the documentation and did not see NSSegmentStyleSeparated > in the list of NSSegmentStyle enums. Here is the list: > > enum { > NSSegmentStyleAutomatic = 0, > NSSegmentStyleRounded = 1, >

Re: NSSegmentedControl & NSSegmentStyleSeparated & autolayout

2015-08-27 Thread Jacek Oleksy
It is in the documentation, see https://developer.apple.com/library/mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSSegmentedControl_Class/#//apple_ref/c/tdef/NSSegmentStyle This is the list for 10.10 (copied from NSSegmentedControl.h): typedef NS_ENUM(NSInteger, NSSegmentStyle) {