autentification problem

2009-02-02 Thread Valentin Dan
Hi, I have a problem when loading pictures from a server. I'm doing this in code, but I also tried to load them from Safari and Firefox and neither succeeded so the code may not be the problem. I have paths like: \\10.1.1.11\SomeFolder\FileName.jpg

Re: becomeFirstResponder override issue

2009-02-02 Thread Chris Anderson
Thanks. And yes the controller has content. In my example below it returns 0 when inside becomeFirstResponder and returns 0 when I activate detectPicker in the same application instance. C. On 2-Feb-09, at 7:40 AM, Keary Suska wrote: On Feb 1, 2009, at 10:32 PM, Chris Anderson wrote:

Re: autentification problem

2009-02-02 Thread Glenn L. Austin
Well, an acceptable URL would be something like smb://serveraddr/sharename/path/to/file to be valid. The original address was a Windows-only server/file (NMB) path. It's not a URL, nor it is even close to anything that is working. It is no different than C:\\path\to\file. On Feb 2,

Re: [OT] Localizing an App or Plugin

2009-02-02 Thread glenn andreas
On Feb 2, 2009, at 9:34 AM, development2 wrote: I need to get all the textr from my app and plugins. Most of the text is in .string files so that is easy. But how do I pull the text form the UI in my .nib/.xib file to go out for translation? Then how do i put it back properly. I am

pyobjc, **out parameters, and informal protocols

2009-02-02 Thread Mani Ghasemlou
Hi all, From what I understand of the Python-Objective-C documentation, out pointer variables (such as NSError **outError) are actually appended to the list of return values for a bridge function. For example: int returnIntWithError: NSError **outError from Python would be invoked as:

Re: GUI threading question

2009-02-02 Thread Michael Ash
On Mon, Feb 2, 2009 at 11:03 AM, Scott Ribe scott_r...@killerbytes.com wrote: It has long been my understanding that in order to keep a GUI from freezing in Cocoa during LONG methods you have to create a NSOperationQueue and load the method as a NSInvocationOperation as seen No, you have to

Re: GUI threading question

2009-02-02 Thread Kyle Sluder
On Mon, Feb 2, 2009 at 10:49 AM, jurin...@eecs.utk.edu wrote: It has long been my understanding that in order to keep a GUI from freezing in Cocoa during LONG methods you have to create a NSOperationQueue and load the method as a NSInvocationOperation as seen here: You don't have to use

Re: becomeFirstResponder override issue

2009-02-02 Thread Keary Suska
On Feb 2, 2009, at 8:44 AM, Chris Anderson wrote: Thanks. And yes the controller has content. In my example below it returns 0 when inside becomeFirstResponder and returns 0 when I activate detectPicker in the same application instance. I was more interested in whether

Re: [OT] Localizing an App or Plugin

2009-02-02 Thread Vince
http://www.blue-tec.com/locsuite/ On Feb 2, 2009, at 4:34 PM, development2 wrote: I need to get all the textr from my app and plugins. Most of the text is in .string files so that is easy. But how do I pull the text form the UI in my .nib/.xib file to go out for translation? Then how do i

Re: [OT] Localizing an App or Plugin

2009-02-02 Thread development2
Yes I understand that. I will have to modify/resize the UI once I have the strings in there. But the people who we are sending the strings out to be localized do not know anything about IB, so I don't want to confuse them or have them screw anything up. Once the strings have been localized

Re: NSOperationQueue bug with leopard 10.5.6?

2009-02-02 Thread Barry Wark
On Fri, Jan 30, 2009 at 9:27 PM, Michael Ash michael@gmail.com wrote: On Fri, Jan 30, 2009 at 11:25 PM, Nick Zitzmann n...@chronosnet.com wrote: On Jan 30, 2009, at 6:32 PM, jurin...@eecs.utk.edu wrote: I attempted to use NSOperationQueue with NSInvocationOperations and after several

Re: NSOperationQueue bug with leopard 10.5.6?

2009-02-02 Thread Michael Ash
On Mon, Feb 2, 2009 at 1:59 PM, Barry Wark barryw...@gmail.com wrote: First of all, thank you for shedding light on this bug; we're all benefiting from your investigations. Thank you very much for saying so, it's much appreciated. Is this still the case if all operations are added on the main

Re: becomeFirstResponder override issue

2009-02-02 Thread Chris Anderson
Ok, upon further investigation it would seem that the objects are initializing in an order I don't understand. I verified this by overriding the mouseDown method and getting the same results. I also tried invoking awakeFromNib but that too did not work. I tried a

RE: Dynamic Sdef support - anyone had any luck? (Andy Klepack)

2009-02-02 Thread Jesse Grosjean
Has anyone had any luck implementing a dynamic sdef using a plugin model? Nothing fancy, targeting 10.5+, I haven't been able to locate any examples of this actually being done or documentation on how to do it. The 10.5 scripting release notes

Questions regarding programming custom visual components

2009-02-02 Thread Vince
Hi there, I hope someone in this list can give me a hint on these issues/ questions: (Note: all for OSX 10.5.x+) 1. Can I add elements to an NSWindow's title bar (without having to rebuild the entire window on my own)? In my case I'd just like to put an image right underneath the

[OT] Localizing an App or Plugin

2009-02-02 Thread development2
I need to get all the textr from my app and plugins. Most of the text is in .string files so that is easy. But how do I pull the text form the UI in my .nib/.xib file to go out for translation? Then how do i put it back properly. I am thinking I may have to change the app and plugins to

Re: Registering a protocol handler for an App

2009-02-02 Thread Dave
Hi Ken, On 31 Jan 2009, at 02:13, Ken Thomases wrote: On Jan 30, 2009, at 10:58 AM, Dave wrote: In order to register an Application to handle a protocol, do I have to change anything other than add URL Types in the Plist file? I'm having problems with my application not being opened

Re: Read lines from very large text file

2009-02-02 Thread Jacob Rhoden
Yea, I saw this and some posts on the apple forum saying NSInputStream is not the right way, hence the question, what is the right way to analyze a very large file line by line. cf the apple thread http://discussions.apple.com/thread.jspa?threadID=1187120tstart=400 On 3/2/09 12:57 AM,

Re: becomeFirstResponder override issue

2009-02-02 Thread Corbin Dunn
On Feb 2, 2009, at 11:19 AM, Chris Anderson wrote: Ok, upon further investigation it would seem that the objects are initializing in an order I don't understand. I verified this by overriding the mouseDown method and getting the same results. I also tried invoking awakeFromNib but that

Re: Questions regarding programming custom visual components

2009-02-02 Thread Kyle Sluder
On Mon, Feb 2, 2009 at 9:16 AM, Vince mailingli...@satsumac.com wrote: 1. Can I add elements to an NSWindow's title bar (without having to rebuild the entire window on my own)? In my case I'd just like to put an image right underneath the window's title. (kind of like what the OmniGroup did

Re: Read lines from very large text file

2009-02-02 Thread Robert Martin
Sorry - the link should have been: http://ridiculousfish.com/hexfiend/ On Feb 2, 2009, at 9:51 PM, Jacob Rhoden wrote: Yea, I saw this and some posts on the apple forum saying NSInputStream is not the right way, hence the question, what is the right way to analyze a very large file line by

RE: Dynamic Sdef support - anyone had any luck? (Andy Klepack)

2009-02-02 Thread Andy Klepack
Ah! Thanks Jesse, that's very straight forward. So having gotten it working in 10.5... what kind of support is there for dynamic sdef in 10.4 (if any)? It looks like the value of 'dynamic' for OSAScriptingDefinition was only enabled in 10.5 but perhaps there is a way around that? - Andy

Re: Read lines from very large text file

2009-02-02 Thread Kenneth Bruno II
On Feb 2, 2009, at 8:42 AM, Jacob Rhoden wrote: I am wondering what the best way to read a text file, line by line, when the file size is much larger than available memory. I know there are helper functions like stringWithContentsOfFile:encoding:error:, but this implies having to load

Re: autentification problem

2009-02-02 Thread Andrew Farmer
On 02 Feb 09, at 02:32, Valentin Dan wrote: I have paths like: \\10.1.1.11\SomeFolder\FileName.jpg file:///\\10.1.1.11\SomeFolder\FileName.jpg . I tested the path on Windows in InternetExplorer and it pops up a Login dialog. After authentication the picture is loaded and all further requests are

RE: autentification problem

2009-02-02 Thread Valentin Dan
I tried replacing \ with / ... same results :( ___ Valentin Dan, Software Engineer Direct: +1 905 886 1833 ext.3047 Email: valentin@masstech.com Office: +40 356-710158 Masstech

Re: [OT] Localizing an App or Plugin

2009-02-02 Thread mmalc Crawford
On Feb 2, 2009, at 7:34 AM, development2 wrote: I need to get all the textr from my app and plugins. Most of the text is in .string files so that is easy. But how do I pull the text form the UI in my .nib/.xib file to go out for translation? Then how do i put it back properly. I am

RE: autentification problem

2009-02-02 Thread Valentin Dan
It does sound like a lot of fun ... but I'm working so I'll live it to someone else who can afford to play around :) One more thing, I don't really care about hacking Firefox or Safari ... I just tried them out to see if my app is dumb or other apps have problems too :)

Read lines from very large text file

2009-02-02 Thread Jacob Rhoden
Hi Guys, I am wondering what the best way to read a text file, line by line, when the file size is much larger than available memory. I know there are helper functions like stringWithContentsOfFile:encoding:error:, but this implies having to load the entire file in memory. Google has not

Re: GUI threading question

2009-02-02 Thread Scott Ribe
It has long been my understanding that in order to keep a GUI from freezing in Cocoa during LONG methods you have to create a NSOperationQueue and load the method as a NSInvocationOperation as seen No, you have to run the long operations on another thread. NSOperationQueue is supposed to

Re: +[NSColor highlightColor] in NSTableView

2009-02-02 Thread Corbin Dunn
On Feb 1, 2009, at 2:41 PM, Graham Cox wrote: On 2 Feb 2009, at 1:46 am, Jerry Krinock wrote: +[NSColor selectedTextBackgroundColor] definitely gives a color based on System Preferences Appearance Highlight Color (for selected text). However, the color actually used in NSTableView is

Re: Stack trace without atos

2009-02-02 Thread Michael Ash
On Mon, Feb 2, 2009 at 12:04 PM, Arnab Ganguly agangul...@gmail.com wrote: Hi All, Is it possible to get stack trace along with symbol information without using atos? My application is going to run on Tiger so I don't hve the option to use the system calls backtrace_symbols. How many times do

Re: Questions regarding programming custom visual components

2009-02-02 Thread Michael Ash
On Mon, Feb 2, 2009 at 9:16 AM, Vince mailingli...@satsumac.com wrote: Hi there, I hope someone in this list can give me a hint on these issues/questions: (Note: all for OSX 10.5.x+) 1. Can I add elements to an NSWindow's title bar (without having to rebuild the entire window on my own)?

continue to solve problem with enterFullScreenMode...

2009-02-02 Thread Carlo Gulliani
Hi all, on last week i was writing about how to change window decoration after launching. After some manipulation i've got enterFullScreenMode. My app has main window, which has webView. webView is web view object of WebKit class. My webView can send and receive any arguments to/from

GUI threading question

2009-02-02 Thread jurincie
It has long been my understanding that in order to keep a GUI from freezing in Cocoa during LONG methods you have to create a NSOperationQueue and load the method as a NSInvocationOperation as seen here: - (IBAction)launchBigTask:(id)sender { NSInvocationOperation* theOp =

Re: NSOpenPanel - disabling the Open button for certain folders.

2009-02-02 Thread Mike Abdullah
Sadly I'm pretty certain there's no API to disable the button. But you can fairly easily implement the -panel:isValidFilename: delegate method and return NO to stop the user opening a folder. Calling NSBeep() at the same time wouldn't be amiss I imagine. Mike. On 30 Jan 2009, at 01:18,

NSTextFieldCell+NSDateFormatter in NSTableView

2009-02-02 Thread Jerry Krinock
It seems to be known that NSDatePickerCell does not work in an NSTableView [1]. I have just re-discovered that the minor digits are not editable and that it does not highlight properly, as reported in 2006 [2]. So, instead I tried an NSTextFieldCell with a date formatter. It edits and

Re: Receive drop event on dock icon

2009-02-02 Thread Ken Thomases
On Feb 1, 2009, at 3:19 PM, Johannes Plunien wrote: i've been searching without success for a hint how to receive a event when a file was dropped on my applications dock icon. I've already configured my apps properties to allow extensions png jpg jpeg gif with store type Binary and Role

Re: [OT] Localizing an App or Plugin

2009-02-02 Thread development2
Oh yeah, they already have the documentation with the screen shots in english... Well I have worked with companies in the past who supposedly knew how to work with nibs, and the screwed them all up for us. I really don't want any body near the nibs, but me :) Just want to save myself a

Re: Read lines from very large text file

2009-02-02 Thread Michael Ash
On Mon, Feb 2, 2009 at 3:51 PM, Jacob Rhoden li...@jacobrhoden.com wrote: Yea, I saw this and some posts on the apple forum saying NSInputStream is not the right way, hence the question, what is the right way to analyze a very large file line by line. cf the apple thread

Re: becomeFirstResponder override issue

2009-02-02 Thread Chris Anderson
So the fact that I am referencing a controller inside becomeFirstResponder hasn't raised any alarms with anyone yet so I could assume that it's ok to do so. If this is the case then I'm either doing something wrong somewhere or perhaps there is an issue with subclassing NSDatePicker. I

Re: OpenGL export is messed up

2009-02-02 Thread Jonathan Selander
I seem to have tracked the problem a little bit. If I use this line: _exporter = [[FrameMovieExporter alloc] initWithPath:[savePanel filename] codec:codec pixelsWide:size.width pixelsHigh:size.height options:options]; Things are messed up, but if I hardcode th resolution to 640x480, the

Re: Question on insertObject: inKeyAtIndex

2009-02-02 Thread Ken Thomases
On Feb 2, 2009, at 1:28 AM, mmalc Crawford wrote: On Jan 31, 2009, at 9:35 PM, Phillip Hall wrote: I then read about the insertObject: inKeyAtIndex: method. Reading the documentation it seems this should be called by the NSArrayController if its implemented by its content array (in my

Re: NSToolbar and constrolling visible items

2009-02-02 Thread Peter Ammon
On Jan 31, 2009, at 8:07 AM, Ferhat Ayaz wrote: Hello, I have added - (BOOL)validateToolbarItem:(NSToolbarItem *)toolbarItem to my code, which will control whether a toolbar item is enabled or not. However, I need a something similar to control whether a toolbar item is visible or not.

EXC_BAD_ACCESS down inside [NSOutlineView reloadItem:reloadChildren];

2009-02-02 Thread Graham Cox
I'm getting a crash (EXC_BAD_ACCESS) inside an internal NSOutlineView method. I'm sure it's my own fault but I'd like to know where I should be looking to fix it. The stack trace is: #0 0x92abf112 in -[NSOutlineView _adjustSelectionForItemEntry:numberOfRows:adjustFieldEditorIfNecessary:]

Re: autentification problem

2009-02-02 Thread Alexander Spohr
The strings are not ok. There is no \ in any valid URL, it is an error. That is _only_ working on windows file paths. Try using / instead. atze ps file:///\\ looks wrong as well. Am 02.02.2009 um 11:32 schrieb Valentin Dan: Hi, I have a problem when loading pictures from a

Re: NSOpenPanel - disabling the Open button for certain folders.

2009-02-02 Thread Corbin Dunn
On Feb 2, 2009, at 11:48 AM, Mike Abdullah wrote: Sadly I'm pretty certain there's no API to disable the button. But you can fairly easily implement the -panel:isValidFilename: delegate method and return NO to stop the user opening a folder. Calling NSBeep() at the same time wouldn't be

Re: EXC_BAD_ACCESS down inside [NSOutlineView reloadItem:reloadChildren];

2009-02-02 Thread Graham Cox
On 3 Feb 2009, at 10:44 am, Corbin Dunn wrote: On Feb 2, 2009, at 3:34 PM, Graham Cox wrote: I'm getting a crash (EXC_BAD_ACCESS) inside an internal NSOutlineView method. I'm sure it's my own fault but I'd like to know where I should be looking to fix it. The stack trace is: #0

Re: EXC_BAD_ACCESS down inside [NSOutlineView reloadItem:reloadChildren];

2009-02-02 Thread Corbin Dunn
On Feb 2, 2009, at 4:02 PM, Graham Cox wrote: On 3 Feb 2009, at 10:44 am, Corbin Dunn wrote: On Feb 2, 2009, at 3:34 PM, Graham Cox wrote: I'm getting a crash (EXC_BAD_ACCESS) inside an internal NSOutlineView method. I'm sure it's my own fault but I'd like to know where I should be

Re: NSOpenPanel - disabling the Open button for certain folders.

2009-02-02 Thread Ron Aldrich
On Feb 2, 2009, at 3:47 PM, Corbin Dunn wrote: On Feb 2, 2009, at 11:48 AM, Mike Abdullah wrote: Sadly I'm pretty certain there's no API to disable the button. But you can fairly easily implement the -panel:isValidFilename: delegate method and return NO to stop the user opening a folder.

Re: NSXMLParser and Unicode/Foreign Character problems

2009-02-02 Thread Todd Atkins
You know, I completely missed that. I've got it working just fine now. Thanks for helping me out. On Mon, Feb 2, 2009 at 2:08 AM, Stephen J. Butler stephen.but...@gmail.com wrote: On Sun, Feb 1, 2009 at 1:36 PM, Todd Atkins toddatk...@gmail.com wrote: What happens is that gNames ends up with

Objective C++ from Objective C

2009-02-02 Thread James Trankelson
Hi, For the majority of my OS X programming life, I've been using Objective C exclusively. However, I now have a reason to want to use some C++ standard template libraries, and have started looking into Objective C++. I've found the documentation on Objective C++ lacking, and was hoping if

Re: Objective C++ from Objective C

2009-02-02 Thread Wayne Packard
Hi, The build system uses the file extension of the source file to determine how to treat the code in the file. .m files get treated as Objective-C (by default). .mm files get treated as Objective-C++. Try renaming your source code file from sourcecode.cpp.objcpp to sourcecode.mm and

Re: Objective C++ from Objective C

2009-02-02 Thread James Trankelson
I guess I should have been more clear. My Objective C++ file is named with an .mm extension. The sourcecode.cpp.objcpp specification is the XCode setting that tells the compiler how to treat the file. jim On Tue, Feb 3, 2009 at 2:16 AM, Wayne Packard wpack...@mac.com wrote: Hi, The build

Grouping separator not working in table

2009-02-02 Thread Steve Nicholson
I'm having trouble getting grouping separators to show up in a table view. In IB, I've assigned a number formatter to a table column's text field cell and set up the formatter with grouping size 3 and turned on Grouping Separator. In tableView:objectValueForTableColumn:row: I'm returning

Re: Objective C++ from Objective C

2009-02-02 Thread Wayne Packard
This code works for me. Can you see any fundamental difference between it and what you have? It compiles with no error or warnings and it logs The list contains 1 items when run. //ObjCPPController.m #import ObjCPPController.h #import SomeObjCPPClass.h @implementation ObjCPPController -

Confused about NSTrackingAreas with autoscroll

2009-02-02 Thread Luke Evans
I have an overridden -updateTrackingAreas to compute some tracking areas in a table view. This is being called when I move the vertical scroll bar, but I have an event loop to handle drag operations in which I start NSPeriodic events and call -autoScroll on the view when the use drags

Re: Objective C++ from Objective C

2009-02-02 Thread James Trankelson
Ah. I've been compiling with LLVM GCC 4.2. Compiling with GCC 4.0 works fine. I wonder if it should work with LLVM. jim On Tue, Feb 3, 2009 at 2:39 AM, Wayne Packard wpack...@mac.com wrote: This code works for me. Can you see any fundamental difference between it and what you have? It

Re: Objective C++ from Objective C

2009-02-02 Thread Peter N Lewis
At 2:08 +0100 3/2/09, James Trankelson wrote: For the majority of my OS X programming life, I've been using Objective C exclusively. However, I now have a reason to want to use some C++ standard template libraries, and have started looking into Objective C++. I've found the documentation on

Re: Read lines from very large text file

2009-02-02 Thread Joar Wingfors
On Feb 2, 2009, at 1:49 PM, Seth Willits wrote: I am wondering what the best way to read a text file, line by line, when the file size is much larger than available memory. Use mmap. Scan through the bytes to find line ranges, and create strings from there. Make sure it's deallocated when

Any Cocoa folks in Arizona?

2009-02-02 Thread M Pulis
Looking to start a cocoa group here in Arizona. Phoenix and metro area. Anyone? Gary ___ 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

Re: becomeFirstResponder override issue

2009-02-02 Thread Chris Anderson
Thanks Corbin. This oddity has led me down the path of why my awakeFromNib was being called twice so there was a flaw in my design. I have reworked becomeFirstResponder to use NSNotification instead and that seems to be working quite well. Chris On 2-Feb-09, at 1:12 PM, Corbin Dunn

Re: Thai Dictionary

2009-02-02 Thread Deborah Goldsmith
Does it work if you set your collation order to Thai in the International Pref pane (Languages tab)? If so, you need to use compare:options:locale: and always pass the th locale. Deborah Goldsmith Apple Inc. golds...@apple.com On Jan 30, 2009, at 4:58 AM, Gerriet M. Denkmann wrote: I

Re: Read lines from very large text file

2009-02-02 Thread Kenneth Bruno II
On Feb 2, 2009, at 9:29 PM, Peter Duniho wrote: On Feb 2, 2009, at 6:02 PM, Seth Willits wrote: Before opening the file, either determine, guess, or be told what the encoding is. With that encoding, convert your delimiter string into raw bytes, then do byte-for-byte comparison on the file

Re: Read lines from very large text file

2009-02-02 Thread Peter Duniho
On Feb 2, 2009, at 6:56 PM, Kenneth Bruno II wrote: On Feb 2, 2009, at 9:29 PM, Peter Duniho wrote: Is there not a Cocoa class that handles character encoding and line- based reading from files, streams, etc.? And an equivalent one for writing? That seems like an odd omission for a

Re: Read lines from very large text file

2009-02-02 Thread Joar Wingfors
On Feb 2, 2009, at 6:02 PM, Seth Willits wrote: Before opening the file, either determine, guess, or be told what the encoding is. With that encoding, convert your delimiter string into raw bytes, then do byte-for-byte comparison on the file to find occurrences of that delimiter. How

Re: Read lines from very large text file

2009-02-02 Thread Peter Duniho
On Feb 2, 2009, at 7:50 PM, Joar Wingfors wrote: How do you know what delimiter string to use? Another thing that you'd have to determine, guess or be told, right? In general I would guess that it in this case almost always would be impossible and / or inappropriate to attempt to determine

Re: maximum theoretical speedup with dual quad processors

2009-02-02 Thread Peter Duniho
On Feb 1, 2009, at 8:37 PM, Michael Ash wrote: Thanks to both you and Rob for repeating the experiment. Interesting that it's so variable. On my computer it would occasionally require several million to crash, but most of the time it explodes within the first few hundred thousand. I've been

Re: NSTextFieldCell+NSDateFormatter in NSTableView

2009-02-02 Thread Jerry Krinock
I discovered a workaruond for this. Although the 'Enabled' binding on the table column does not work, for some strange reason, the 'Editable' and also the 'Text Color' do work. So with these two I can get the desired effect. ___ Cocoa-dev

Re: Read lines from very large text file

2009-02-02 Thread Greg Parker
On Feb 2, 2009, at 7:50 PM, Joar Wingfors wrote: On Feb 2, 2009, at 6:02 PM, Seth Willits wrote: Before opening the file, either determine, guess, or be told what the encoding is. With that encoding, convert your delimiter string into raw bytes, then do byte-for-byte comparison on the file

Re: Read lines from very large text file

2009-02-02 Thread Michael Ash
On Mon, Feb 2, 2009 at 8:53 PM, Joar Wingfors j...@joar.com wrote: On Feb 2, 2009, at 1:49 PM, Seth Willits wrote: I am wondering what the best way to read a text file, line by line, when the file size is much larger than available memory. Use mmap. Scan through the bytes to find line