Questions tagged [document-based]

Document-based application design enables users to create and manage documents containing their data. In cocoa, this is enabled via the "document architecture" subsystem which provides inbuilt support for applications that manage documents.

112 questions
0
votes
1 answer

NSDocument has ivar to NSArrayController

Is this ok, to load NSWindowController from NSDocument, and keep reference to NSArrayController? I need this instance of array controller to save data. - (void)makeWindowControllers { ImageWindowController *controller = [[[ImageWindowController…
0
votes
0 answers

How to Sort Parent Documents on Values from Child Documents in SOLR?

I'm working with Solr and facing a challenge related to sorting parent documents based on values from associated child documents. Scenario: I have two types of documents: products (as parent documents) and reviews (as child documents). (They are…
0
votes
0 answers

Best way to make Paywall for document-based SwiftUI apps

My app displays a Paywall right away. Everything should be working fine as of my tests, but every time I upload the app update to App Store connect, they tell me that there is a problem: Users are not able to get access to premium features after…
0
votes
1 answer

How to stop MacOS Document-based App from automatically loading cached file

On launching my app from Xcode, my document-based app automatically apparently tries to load a cached document from a previous launch. That document appears to be corrupted as the app crashes in initWithCoder [which was called from…
Carl Carlson
  • 500
  • 4
  • 17
0
votes
0 answers

Document based app using one single window

I have a document-based macOS application, which is a basic text editor. The default behavior is to create a new window for every opened document. But I want to only have one window displayed at a time and when opening a document or creating a new…
Codey
  • 1,131
  • 2
  • 15
  • 34
0
votes
0 answers

How to get data from SwiftUI TextField to NSDokument class

What I'm trying to do is store some data from a MacOS App with NSDocument provided class in a file. I decided to use SwiftUI , but all tutorials I found are using Storyboards. And from those I cannot adapt how to get the data from my textfield into…
0
votes
1 answer

Document-based application, or not?

I am building a beer recipe application in Cocoa. It's has one main window, with a couple of textfields, tableviews etc. I want to be able to Open and Save recipes in XML format. I found some examples of reading/writing XML. Should my application be…
Joran
  • 69
  • 6
0
votes
1 answer

NSWindow "Edited" not shown

I have an application, which is primarily for presenting documents but can under certain circumstances also change the presented document. That's why my app isn't a real document based app. Nevertheless I want to display the "— Edited" additive to…
Codey
  • 1,131
  • 2
  • 15
  • 34
0
votes
1 answer

Centering a document window

I am writing a core data, document based app. I am trying to center the document's window. I have tried calling the following code from the document's makeWindowControllers method, from the window controller's awakeFromNib method and from the window…
0
votes
1 answer

MongoDB Query from multiple models / schemas and return in one field

I am using Nodejs and MongoDB, mongoose and expressjs, creating a Blog API having users, articles, likes & comments schema. Below are schemas that I use. const UsersSchema = new mongoose.Schema({ username: { type: String }, …
byal
  • 167
  • 1
  • 12
0
votes
2 answers

Change Window in Cocoa Document-Based Application

I have one window in a Cocoa-Document based application. I want to make this application have no titlebar. I know how to do this in a regular Cocoa app because there is a window called "window" in Cocoa-Document based apps I don't see any window…
foobar5512
  • 2,470
  • 5
  • 36
  • 52
0
votes
1 answer

Accessing NSDocument from NSWindowController subclass?

I am creating simple document based app. So far I have implemented NSDocument subclass, which is Document and NSWindowController subclass, which is ToolbarWindowController. ToolbarWindowController controlls the toolbar, which has sliders to modify…
Vidux
  • 183
  • 1
  • 11
0
votes
1 answer

Opening multiple documents in a UIDocumentBrowserViewController based app

Apple's documentation is thin on the subject of UIDocumentBrowserViewController-based apps that want to support opening multiple documents simultaneously. I'd like to enable this, so that the user can copy/paste between two or more documents easily,…
bright
  • 4,700
  • 1
  • 34
  • 59
0
votes
1 answer

Working with the frontmost window's controls in a document-based app?

I've scanned the documentation and googled fairly extensively and found nothing on this subject. What I'm needing to do is interact with a specific instance of one of my NSWindows - that is, one created through the NSDocument system put in place by…
John Wells
  • 1,139
  • 1
  • 10
  • 27
0
votes
1 answer

Changing NSMenuItem depending on user selection

I am working on a Cocoa document based application. I have a menu item in the file menu named "Export Things…". This menu item is connected to the first responder, and calls a selector in MyDocument. So far so good. I would like to change the title…
Jakob Egger
  • 11,981
  • 4
  • 38
  • 48