How do I set the part of the file name that is selected in NSSavePanel? I only want the file name selected and not the file extension.
Here's what I noticed. If I setAllowedFileTypes: for the save panel then only the file name is selected but not the file extension. However if I don't set the allowed file types then the file extension i...
In my application, I want to stream videos shot on an iPhone, *.movie files, from a server running on a Mac desktop to an iPhone or iPad client. What are some possible open source servers that do this that are small enough to be shipped or embedded with a downloadable Mac app? There is a product StreamToMe by Matt Gallagher that does t...
Hello,
I need to make a cvs file in cocoa. To see how to set it up I created one in Numbers and opened it with text edit it looked like this:
Results,,,,,,,,,,,,
,,,,,,,,,,,,
A,10,,,,,,,,,,,
B,10,,,,,,,,,,,
C,10,,,,,,,,,,,
D,10,,,,,,,,,,,
E,10,,,,,,,,,,,
So to replicate this in cocoa I used:
NSString *CVSData = [NSString stringWithF...
Hello,
Im attempting to make a little app that lets you add text boxes to you canvas (window). I have an NSTextField that needs to let you drag it around the window. When you drop it it needs to stay in the spot you mouse left it. Heres my code to make the fist text field:
NSTextField *myTextField=[[NSTextField alloc] initWithFrame:NS...
I am developing a Cocoa application which involves a chat element. One approach I've considered is using Websockets to handle client-server communication. This would be particularly desirable because chats will also be displayed on a website, and using Websockets could make the implementation very simple.
So: would it be possible to use...
I'm trying to create an vocabulary study application using Obj-C and the Cocoa frameworks. I have about two week's experience in both areas and have reached an edge of my current knowledge.
Here's where I'm stuck. When I press a checkbox, a corresponding plist is loaded into memory as an NSDictionary. I want to generate a "Label: Textf...
I'm having a hard time scraping together enough snippets of knowledge to implement an NSOutlineView with a static, never-changing structure defined in an NSArray. This link has been great, but it's not helping me grasp submenus. I'm thinking they're just nested NSArrays, but I have no clear idea.
Let's say we have an NSArray inside an N...
How do you hide the desktop icons and the windows open to show the desktop wallpaper in cocoa?
...
Hi all,
I have found that user can associate help with his application using Help Viewer. Users typically launch Help Viewer by choosing the application help item from the Help menu, or by typing a query in the Spotlight For Help text field in the Help menu.
I have some different requirement: I want to associate component specific help...
I'm writing an application to respond on a hotkey by copying highlighted text into NSPasteboard's generalPasteboard. After looking around here for a solution for sending virtual keystrokes, I found this: http://stackoverflow.com/questions/1505933/how-to-send-a-cmd-c-keystroke-to-the-active-application-in-objective-c-or-tell
I tried the ...
I'd like to get the image files for the constants definied in NSImage.h, like NSImageNameGoRightTemplate for example. I'd like to copy and edit some of them. Does anybody know where those images are located? I'm too stupid to find them on the drive...
...
Hi,
I'm fairly new to the world of bindings in cocoa, and I'm having some troubles (perhaps/probably due to a misunderstanding).
I have a singleton that contains an NSMutableArray called plugins, containing objects of class Plugin. It has a method called loadPlugins which adds objects to the plugins array. This may be called at any poi...
Hi,
How can i change a normal font to bold font, Here the text should be selected and say by clicking the button(Bold) button. the selected text should become bold.
...
I want to create a scrollview with a zooming control and a button next to the scrollbar. Sort of like the "tile window" button in XCode (top right corner of the editor), it should be in the same box that usually is used by the scrollbar only.
Do you have an idea of how to approach this?
I was thinking to use an NSScrollView and set the...
I have a problem in NSOperation. I tried many ways but it would run behind the screen, but will not make it appear on the my table view. Can anyone help me out with this. I am new to NSOperation.
Recents.h
#import <UIKit/UIKit.h>
#import "FlickrFetcher.h"
@interface Recents : UITableViewController {
FlickrFetcher *fetcher;
NSString ...
if(sqlite3_open([databasePath UTF8String], & database) == SQLITE_OK) {
NSLog(@"DB OPENED");
// Setup the SQL Statement and compile it for faster access
const char *sqlStatement ="select name from Medicine";
sqlite3_stmt *compiledStatement;
int result = sqlite3_prepare_v2(database, sqlStatement, -1, &compiledStatemen...
I am trying to make a popup button that always displays a + as its image and when you click on it, a context menu pops up that will allow you to decide what type of object you want to add. Is there anyway to do this using an NSPopupButton? I saw in the specs for NSPopupButotn that the method SetImage has no effect so it seems that this...
Hello,
I'm building an application that uses a NSStatusItem and run in the background. The problem I'm running into is entering text into a NSTextField.
I've got a menu item in my NSStatusItem which:
[NSApp activateIgnoringOtherApps:YES]
[prefPanel makeKeyAndOrderFront:nil]
It shows up fine, but when I try to enter text into the NST...
How do I create a button with an images for normal & highlighted states in interface builder for cocoa application? I need a button like custom button in cocoa-touch and provide a graphics for default and highlighted states. Again, it's for pure mac application not for iPhone.
TIA
...
I'm having some trouble with XSL-processing when there are stylesheets that include other stylesheets relatively.
(the XML-files may be irrelevant but are included for completeness - code is at the bottom).
Given the XML-file:
<?xml version="1.0" ?>
<famous-persons>
<persons category="medicine">
<person>
<firstname> Edward </fi...