Questions tagged [nscollectionview]

NSCollectionView is a NSView subclass which provides basic functionality for displaying, arranging, grouping and manipulating graphical representations of collections of objects.

NSCollectionView is a NSView () subclass which provides basic functionality for displaying, arranging, grouping and manipulating graphical representations of collections of objects.

Xcode 7 introduced a new API for NSCollectionView so that it can be implemented similarly to the iOS counterpart (UICollectionView). In OS X 10.11+ you can access NSCollectionView using its datasource and delegate protocols.

428 questions
0
votes
3 answers

How can i create a plist file from these arrays?

I have a NSCollectionView that can read data like this code: self.contents = @[ @{@"itemTitle":@"Product 1", @"itemPrice":@"$20.90", @"itemImage":@"PastedGraphic-1.png"}, …
0
votes
0 answers

NSCollectionView maxes out at 2796202 items

I created a simple Mac OSX app in XCode that tries to display a collection view (flow layout) with 10 million items. But, it seems to max out at 2796202 and I can't figure out why. Any ideas?
user1007895
  • 3,925
  • 11
  • 41
  • 63
0
votes
1 answer

Get document object with current focus from NSCollectionView

I have a (subclassed) NSCollectionView open, containing multiple text views. Each of the text views is mapped to a (subclassed) NSDocument object. (The idea is to use the document architecture's save functions but not its windowing functions,…
Displaced Hoser
  • 871
  • 3
  • 13
  • 35
0
votes
1 answer

How to force a NSView subviews to resize "now"?

I have an NSCollectionView, which items are dynamically sized. When the item is returned by [collectionView makeItemWithIdentifier:reuseIdentifier forIndexPath:indexPath] its view has the desired size BUT the subviews are not yet sized accordingly,…
AirXygène
  • 2,409
  • 15
  • 34
0
votes
0 answers

NSCollectionView Reloads content but not the [sender tag]

i am having a programatically created NSCollectionview _upcomingVideosCollection = [[NSCollectionView alloc] initWithFrame:NSRectFromCGRect(CGRectMake(0, 0, 300, 1200))]; _upcomingVideosCollectionItem = [Videos new]; Videos.m #import…
0
votes
1 answer

textDidChange points to the wrong NSCollectionViewItem

I am trying to build an NSCollectionView filled with multiple editable TextViews. (OS X app in Swift.) My subclass of NSCollectionViewItem is called NoteViewItem. I am trying to have the program detect when one of the TextView has changed. I tried…
Displaced Hoser
  • 871
  • 3
  • 13
  • 35
0
votes
1 answer

Turn multiple values from NSCollectionView into one NSString

This checks my collection view if there is something called "BETA". When this is the case, it should look what the itemID of it is. This should be brought together and return something like "2 4" in a plist file. In my log I get "Teststring 2" and…
0
votes
1 answer

Setting scroll indicator insets on NSCollectionView

I know UIScrollView has scrollIndicatorInsets, so if I had a UICollectionView I could do something like collectionView.scrollIndicatorInsets = UIEdgeInsetsMake(0,0,0,0); But how can I set the scroll indicator insets on an NSCollectionView since…
Adam Johns
  • 35,397
  • 25
  • 123
  • 176
0
votes
1 answer

NSCollectionView Delegate Method on Select Header

The latest update to NSCollectionView allows the delegate to detect the selection of items with - (NSSet*)collectionView:(NSCollectionView*)collectionView shouldSelectItemsAtIndexPaths:(NSSet*)indexPaths and -…
Stuart Barth
  • 301
  • 2
  • 10
0
votes
1 answer

Selection delegates for NSCollectionView in a AIPanelPlatformWindow

I'm writing a simple Adobe Illustrator plugin. Starting from the EmptyPanel sample I've added an NSCollectionView to the AIPanelPlatformWindow. The CollectionView is setup just as you would normally ( delegate, datasource, etc... ). Problem is, I'm…
Alex
  • 712
  • 1
  • 5
  • 11
0
votes
1 answer

NSCollectionView selection and deselection

I recently got my NSCollectionView worked in the way, that it handles section the right way. I reached this by adding a binding with the Model Key Path "selected". This action hides a blue view, that shows a selection to the user. The Problem is,…
0
votes
1 answer

Using NSCollectionView with CoreData and an NSImageView

I'm trying to setup up a NSCollectionView which is binded to an entity and I'm trying to load an image into an NSImageView out of this entity. I stored the image as a NSData object. I did a little research and found out that I'm supposed to set a…
Tom Kuschka
  • 463
  • 1
  • 8
  • 17
0
votes
0 answers

NSCollectionView with CoreData

I just tried to create my first OSX-Application with swift. For my Project I need a CollectionView which works with CoreData. I build up my App along the lines of this tutorial. The only difference between the tutorial and my project is that, I'm…
Tom Kuschka
  • 463
  • 1
  • 8
  • 17
0
votes
2 answers

Alternative to NSCollectionView in pre-OSX10.5, Cocotron?

NSCollectionView was introduced in OS X 10.5, and is not yet implemented in Cocotron. I am trying to implement a small app that will allow creating properly packaged data files for an online service, which will then be uploaded by an administrator.…
Ivan Vučica
  • 9,529
  • 9
  • 60
  • 111
0
votes
2 answers

NSCollectionView finished drop event

I'm working on the app that displays svg icons inside NSCollectionView. I want to implement drag&drop feature to allow users drags svg to Finder or another app. There are I have two questions: 1.) To implement drag to another app I'm using…