FROM : Jean-Daniel Dupas
DATE : Sun May 04 11:55:35 2008
Le 4 mai 08 à 05:18, Jens Alfke a écrit :
>
> On 3 May '08, at 8:13 PM, Bruce Sherwood wrote:
>
>> Thanks! I'm really glad to hear that this is a known problem, and
>> that there are solutions, even if it is "pretty tricky stuff". Can
>> you or someone else point me to a sample piece of code that could
>> get me started?
>
> I'm not sure, actually. Check the last few weeks of list archives; I
> remember a thread whose subject was something relevant about
> promoting a command-line process.
>
>> Indeed, the nib file (if there is one) would be right next to the
>> Visual module (in site-packages/visual). But initial reading of
>> documentation, or at least of examples, made it look like you say
>> something like "LoadNib", with no option to say where to get it,
>> because the assumption is that the nib file is in a standard place
>> in the app's bundle. Is there some kind of nib-loading procedure
>> that takes a file location as an argument? I don't have anything
>> against nib files in principle; I just don't know how to find them
>> when my software isn't an app.
>
> I can't speak for the Carbon nib APIs, but look at the NSBundle method
> + (BOOL)loadNibFile:(NSString *)fileName externalNameTable:
> (NSDictionary *)contextwithZone:(NSZone *)zone
>
> The fileName parameter is an absolute path.
Yes, and NSNib do this too, if you ask it (and if you don't want to
have to deal with the externalNameTable).
- [NSNib initWithContentsOfURL:];
- [NSNib instantiateNibWithOwner:topLevelObjects:];
DATE : Sun May 04 11:55:35 2008
Le 4 mai 08 à 05:18, Jens Alfke a écrit :
>
> On 3 May '08, at 8:13 PM, Bruce Sherwood wrote:
>
>> Thanks! I'm really glad to hear that this is a known problem, and
>> that there are solutions, even if it is "pretty tricky stuff". Can
>> you or someone else point me to a sample piece of code that could
>> get me started?
>
> I'm not sure, actually. Check the last few weeks of list archives; I
> remember a thread whose subject was something relevant about
> promoting a command-line process.
>
>> Indeed, the nib file (if there is one) would be right next to the
>> Visual module (in site-packages/visual). But initial reading of
>> documentation, or at least of examples, made it look like you say
>> something like "LoadNib", with no option to say where to get it,
>> because the assumption is that the nib file is in a standard place
>> in the app's bundle. Is there some kind of nib-loading procedure
>> that takes a file location as an argument? I don't have anything
>> against nib files in principle; I just don't know how to find them
>> when my software isn't an app.
>
> I can't speak for the Carbon nib APIs, but look at the NSBundle method
> + (BOOL)loadNibFile:(NSString *)fileName externalNameTable:
> (NSDictionary *)contextwithZone:(NSZone *)zone
>
> The fileName parameter is an absolute path.
Yes, and NSNib do this too, if you ask it (and if you don't want to
have to deal with the externalNameTable).
- [NSNib initWithContentsOfURL:];
- [NSNib instantiateNibWithOwner:topLevelObjects:];
| Related mails | Author | Date |
|---|---|---|
| Bruce Sherwood | May 4, 01:35 | |
| John C. Randolph | May 4, 03:55 | |
| B.J. Buchalter | May 4, 04:51 | |
| Bruce Sherwood | May 4, 04:52 | |
| Jens Alfke | May 4, 05:04 | |
| Bruce Sherwood | May 4, 05:13 | |
| Jens Alfke | May 4, 05:18 | |
| Kyle Sluder | May 4, 05:18 | |
| Jean-Daniel Dupas | May 4, 11:55 | |
| Ken Thomases | May 4, 21:47 |






Cocoa mail archive

