Le 19 juil. 2011 à 07:21, Gideon King a écrit :
> But I told it to pre-fetch the view relationship. Any ideas why it wouldn't
> work?
Maybe a silly answer, but isn’it a side effect of lazy loading?
V.
>
___
Cocoa-dev mailing list (Cocoa-dev@lists
On 19 Jul 2011, at 02:41, Trygve Inda wrote:
>> [myArrayController bind:@"content" toObject:myClassObject
>> withKeyPath:@"places" options:NULL];
>
> Hmm... Seems like it should be bind:@"contentArray"
Please use the NSContentArrayBinding constant as that's what's it exists for,
despite being
I have an NSMutableArray that contains a MPMediaItem and song title as it's
key.
I then take a search string and loop through the entire NSMutableArray
looking for a fuzzy match. It works very well, the problem is that the array
contains 1,777 items (could contain more) and the search takes about
Is your topic node self-referential? Maybe CoreData doesn't prefetch
circular references.
-Heath Borders
heath.bord...@gmail.com
Twitter: heathborders
http://heath-tech.blogspot.com
On Tue, Jul 19, 2011 at 12:21 AM, Gideon King wrote:
> Hi, I'm doing a fetch of some objects like this:
>
> enti
> I have an NSMutableArray that contains a MPMediaItem and song title as it's
> key.
>
> I then take a search string and loop through the entire NSMutableArray
> looking for a fuzzy match. It works very well, the problem is that the array
> contains 1,777 items (could contain more) and the search
Oops - I meant to say it's an NSMutableDictionary!
What might a quick stubbed example of that be? Not sure I am following. How
much speed would it generally gain?
Google Voice: (508) 656-0622
Twitter: eric_dolecki XBoxLive: edolecki PSN: eric_dolecki
http://blog.ericd.net
On
> Oops - I meant to say it's an NSMutableDictionary!
>
> What might a quick stubbed example of that be? Not sure I am following. How
> much speed would it generally gain?
Simple example. Init a NSMutableDictionary. For each string, compute a hash key
as the sum of all chars composing it (in a s
Someone told me to look into -enumerateKeysAndObjectsWithOptions:usingBlock:
(using NSEnumerationConcurrent) Would that be a better way? If so, I haven't
seen this used before - how could I apply it?
- Eric
>
> Simple example. Init a NSMutableDictionary. For each string, compute a hash
> key as t
> Someone told me to look into -enumerateKeysAndObjectsWithOptions:usingBlock:
> (using NSEnumerationConcurrent) Would that be a better way? If so, I haven't
> seen this used before - how could I apply it?
You can try to use that, but, basically, it is the same problem: you enumerate
all entrie
Thanks. The distance is computed because the entry string is dynamic and
it's providing a distance between the title of the song and what was entered
as text. So I can't pre-compute that data and stuff into a dictionary. Each
time the method is called, the *stringValue* will be different.
On Tue,
> Thanks. The distance is computed because the entry string is dynamic and it's
> providing a distance between the title of the song and what was entered as
> text. So I can't pre-compute that data and stuff into a dictionary. Each time
> the method is called, the stringValue will be different.
I think I see what you're onto here now. So I might only have about 30 or so
keys to search through instead of all 1,777 items, and then just grab an
array (or probably a dictionary) of stuff out of that to search on...
resulting in a lot less searching to hopefully get to a potential match.
a son
Interesting idea. The structure is that I have a grandparent with just a single
attribute, a parent which has parent and children (self referential)
relationships, and a couple of one way to-one self referential relationships on
the topic node object itself, so there are a few things going on th
On Jul 19, 2011, at 6:22 AM, Vincent Habchi wrote:
> It's not easy, but I would recommend using a hash table instead. You can
> compute a hash code that depends more or less on the spelling of your
> strings, then use that hash key to access a set of candidate for your fuzzy
> search.
I take
Graham; Scott,
I have a follow-up question on this topic, if you don't mind. Do either of you
have a recommendation on the idea of adding a layer-hosting view as a subview
of a layer-backed view? I'm thinking of adding a virtual keyboard to an
existing app that is layer-backed. I would like
Eric E. Dolecki wrote:
//Get the very best match there is to be found for
song.
if(match < currentFoundValue){
currentFoundValue = match;
test = [songsDictionary objectForKey:thisSong];
dis = [NSArray a
Related to a previous posting of mine regarding floats and CGFloats when
decoding older 32 bit serializations in a 64 bit runtime, I am now also in the
process of modernizing some old code that used int values encapsulated by
NSNumber in keyed archives.
The current serializations were performed
Hi!
I'm facing a little dilemma: in a modal dialog, I'd like to create a new core
data entity with -[aNSArrayControllerInEntityMode insert:] and initialize some
attributes of this new entity.
However, the creation and insertion of the new entity is delayed one run loop
iteration; but, in a mod
I’m working on a fairly simple iOS app with some other folks, and it works fine
for me on a real iOS device, but whenever I run it in the 4.3 simulator it
crashes as soon as I type a few characters into a text field. The crash is
always inside the system method -[AppleSpell init]. The other deve
On Jul 19, 2011, at 11:31 AM, Vincent wrote:
> I'm facing a little dilemma: in a modal dialog, I'd like to create a new core
> data entity with -[aNSArrayControllerInEntityMode insert:] and initialize
> some attributes of this new entity.
I know it’s considered rude to answer a coding question
On Jul 19, 2011, at 11:46 AM, I wrote:
> I’m working on a fairly simple iOS app with some other folks, and it works
> fine for me on a real iOS device, but whenever I run it in the 4.3 simulator
> it crashes as soon as I type a few characters into a text field. The crash is
> always inside the
Hi Jens,
> I know it’s considered rude to answer a coding question with a UI critique,
> but the best solution would really be to avoid using a modal dialog at all.
> They’re a poor user experience compared to a sheet or some other kind of
> in-window display, and as you’ve seen, they can cause
Hi,
I've read everything that says printing is easy...but I'm struggling
with it!
I have googled, but nothing quite seems to fit my situation, I just
want a single page.
In my app I have customer orders, and I just want to print out a copy.
I can't work out what the best option would be
On Jul 19, 2011, at 12:24 PM, Philip Dow wrote:
> Related to a previous posting of mine regarding floats and CGFloats when
> decoding older 32 bit serializations in a 64 bit runtime, I am now also in
> the process of modernizing some old code that used int values encapsulated by
> NSNumber in
On Jul 19, 2011, at 12:32, Nick Zitzmann wrote:
> The only problem I ever had with unarchiving 32-bit app archives in a 64-bit
> app was with longs in non-keyed archives that were encoded using
> @encode(long)*, and that doesn't apply to your scenario.
The other issue that might rear its head i
Thanks for the tips Quincey and Nick. I'll keep an eye out for the use of
NSNotFound.
~Phil
On Jul 19, 2011, at 2:46 PM, Quincey Morris wrote:
> On Jul 19, 2011, at 12:32, Nick Zitzmann wrote:
>
>> The only problem I ever had with unarchiving 32-bit app archives in a 64-bit
>> app was with lo
>
> On 19 Jul 2011, at 02:41, Trygve Inda wrote:
>
>>> [myArrayController bind:@"content" toObject:myClassObject
>>> withKeyPath:@"places" options:NULL];
>>
>> Hmm... Seems like it should be bind:@"contentArray"
>
> Please use the NSContentArrayBinding constant as that's what's it exists for,
>
What's the proper way to detect if the "Enter" key on the virtual (on-screen)
keyboard in iOS is touched?
Is this part of the UITextField delegate protocol? Or is it supposed to be
the "Editing Did End" event you see when you right-click on the UITextField in
question (in IB, of course)?
I
I've got a Mac/Cocoa static library project. It links against
IOKit.framework. It builds fine.
I take the .a and header and import them into a Mac/Cocoa project.
I get the following linker errors:
Undefined symbols:
"_IORegistryEntryCreateCFProperty", referenced from:
+[MyLibrary getT
Oops, should have stipulated: iOS 4 dev on Xcode 3.2.whatever.
On Jul 19, 2011, at 6:57 PM, William Squires wrote:
> What's the proper way to detect if the "Enter" key on the virtual
> (on-screen) keyboard in iOS is touched?
> Is this part of the UITextField delegate protocol? Or is it suppose
On 19 Jul 2011, at 6:57 PM, William Squires wrote:
> What's the proper way to detect if the "Enter" key on the virtual
> (on-screen) keyboard in iOS is touched?
> Is this part of the UITextField delegate protocol?
Like textFieldShouldReturn:?
Or do you mean something else?
— F
_
On Jul 19, 2011, at 5:11 PM, Glen Haderman wrote:
> I've got a Mac/Cocoa static library project. It links against
> IOKit.framework. It builds fine.
>
> I take the .a and header and import them into a Mac/Cocoa project.
>
> I get the following linker errors:
>
> Undefined symbols:
> "_IOR
I'm using +[NSData dataWithContentsOfMappedFile:] to access a file. Is it
possible to ensure this opens read-only? I see there's a version that takes
options, but none of these options seem to open it read-only.
--Graham
___
Cocoa-dev mailing list (
On Jul 19, 2011, at 6:29 PM, Graham Cox wrote:
> I'm using +[NSData dataWithContentsOfMappedFile:] to access a file. Is it
> possible to ensure this opens read-only? I see there's a version that takes
> options, but none of these options seem to open it read-only.
I believe it already opens the
On 20/07/2011, at 11:43 AM, Greg Parker wrote:
> On Jul 19, 2011, at 6:29 PM, Graham Cox wrote:
>> I'm using +[NSData dataWithContentsOfMappedFile:] to access a file. Is it
>> possible to ensure this opens read-only? I see there's a version that takes
>> options, but none of these options seem
On Jul 19, 2011, at 12:27 PM, Michael Crawford wrote:
> Graham; Scott,
>
> I have a follow-up question on this topic, if you don't mind. Do either of
> you have a recommendation on the idea of adding a layer-hosting view as a
> subview of a layer-backed view?
Yes. You shouldn’t.
When you tu
I've had a few users complain that if my app calls NSBeep() many times in
quick succession the program blocks until each of the beeps has played
sequentially. I can't reproduce this: on my system, NSBeep() returns
immediately and a subsequent call to NSBeep() will cause the sound to stop
and restar
When computing the string distance depending on the chosen algorithm you can
exit the function earlier if the distance is becoming too high.
An other possible way is to do some fuzzy string search:
http://en.wikipedia.org/wiki/Fuzzy_string_searching
HTH
--
mathk
- Message d'origine
Hi,
Is there a way to read "Double-click a main window's title bar to
minimize" setting in Appearance tab in the system preferences?
I want to read the setting in my code to make a custom window work
with the setting.
Regards,
Satoshi
___
Cocoa-dev ma
Hello
Could anyone describe me a way to customize the NSScroller look inside
NSScrollView?
I know that NSScrollView and NSScroller have to be subclassed but I'm stuck
with that.
Could anyone tell me how to exchange slider bitmaps and implement the new
slider into NSScrollView?
Thanks in advanc
I am drawing an NSAttributedString into a bitmap image and uploading to OpenGL
as a texture. The strings origin is animated to mimic a scroll view, so speed
is of the essence. Considering my need for animation I have migrated to
NSLayoutManager / NSTextContainer and NSTextStorage, as opposed si
I am drawing an NSAttributedString into a bitmap image and uploading to OpenGL
as a texture. The strings origin is animated to mimic a scroll view, so speed
is of the essence. Considering my need for animation I have migrated to
NSLayoutManager / NSTextContainer and NSTextStorage, as opposed si
Well, I suppose I could make sure the window's contentView is not layer backed
and then put all of the content that used to be in that view into a new
layer-backed view and then add the new layer-backed view as a subview of the
contentView.
Next, I create my layer-hosting view and add it to th
Exactly. That’s an excellent example and should work fine.
Great solution.
On Jul 19, 2011, at 11:59 PM, Michael Crawford wrote:
> Well, I suppose I could make sure the window's contentView is not layer
> backed and then put all of the content that used to be in that view into a
> new layer-b
Hi again,
I’m puzzled by what I think is a very basic Cocoa feature that still escapes my
knowledge (and I found nothing really meaningful about it).
More specifically, I have a NSPanel, with some NSTextField inside, and would
like the editing to begin immediately in the first text field when th
45 matches
Mail list logo