advertisement

Article:
  Introduction to Cocoa Graphics, Part 2
Subject:   tried with 10.1 PB/IB?
Date:   2001-11-22 13:12:19
From:   psheldon
Response to: tried with 10.1 PB/IB?

Something in an old project Mike Beam had written column on didn't work and I was sure happy he changed the subject. I don't remember what it was that didn't work any more, but it was written just be 10.1 emerged.
Once I canibalized a speech synthesis example from Apple to make it simpler to see how better to canibalize from it. I did this in the beta version of os x. On public release, it wouldn't recompile. The target program might have continued working with all its linked up stuff, but the frameworks had adjusted their positions subtly. I wound up changing imports or includes in headers on some guess and got my "toodles" speech synthesis for dummies program going again.
I got way lost trying to put together with toodles, the text editor you had with the saving stuff that's so fundamental in any programming learning . So, I realized I had only valued with some pain learning how to build from pieces but not actually yet learned how to build from pieces .
Though it hasn't quite taken root in me yet, more important that the text editor is to get some feel of the memory management stuff. I think this release and retain is a bizarre spin on scope and "name space" peculiar to objective c. Understand this stuff and you'll know powerful things that you best not speak of in a c++ crowd. Apple is supposed to do something with combining objective c and c++ less apologetically than the first example they showed. Scope conceptualization might be important to revisit in December.
When, in Beta os x, I first started reading the external references such as ObjC.pdf, I worried. I can force myself to sit down and read something, but, if no connections happen in my brain to raw painful experience, it probably is going to go down the bit bucket. So, I gave myself pain by canibalizing things, spending days with tutorials making simpler dumber things where I could see what was going on. I could sort of read the insides of Simon and know what was going on, but could I look up stuff to build Simon ex nihilo, maybe nobody can.
I did some stuff where I wet my feet in using the classes tab and hopping to helpviewer to search the class methods to get a feel what was going to go on in the next lesson, but not too long . I anticipated a bit of struggle to put from sketch something doable . Sketch looks like an enormous search space .
It seemed plausible that Mike was going to remind us of some of the things we learned, such as enumerations or mutable NSArrays of NSBezierpaths that you could build at run time and port into drawRect. Then I was satisfied that I had gone through just enough sweat to make me value stuff when he "did it for me" and sort of spoon fed.
I hope MIke and Oreilly notices the important thing that we noticed, that some of the old projects might not work and might need to be rewritten if a textbook ever comes out of this column or these threads.
I have noticed a pattern in a very wise man of modules sort of self contained stuff. The end of these modules heavily depends on the beginnings and the wise man thought and presented faster as he got on in the module, to rapidly rehearse or review the learned language, but learning something knew he started afresh and slow He, in fact, started himself personally much much slower, as he spent many hours preparing his class notes for presentation.
Mike, Oreilly and Apple probably don't want to lose new students either.
Here's a possibility. PB has a toolbar you might have gotten used to. There is also, however, a menu item that says run targets. Download his obsolete source and the targets won't also be obsolete, they'll work. Download his completed obsolete source code but don't clean the targets which recompiling will do maybe! Run the targets from the menu. I believe Apple defaulted to clean target and compile link and run as the default icon. As far as I could figure, you got to "clean the targets" to have the classes tab work. So move the target from the folder they had been in to see what the obsolete code does and, if you get braver than me, clean compile link and run to index appropriately to see how the frameworks and classes have shifted (if that's even what it is). The thing is seeing the way the code was supposed to work and reading through the code might get rid of any worries you weren't up to speed with the rest of us. A lot of us don't know how to debug obsolete code either.
Almost remember in your darkest hour that though some may say they have made debugging a predictable science, they only say that because they aren't having a darkest hour themselves at the time.
;-)
That's as close as I want to get to debugging what went wrong with the texteditor columns, going back and finding it doesn't work would scare me more than just hearing it didn't work from you.
;-)
I got burned with that speech editor saver marriage I was trying to do.
I still fantasize, every once in awhile to make an os x version of hearit, an Apple os 9 and older control panel that lets your computer read anything your mouse selects in any program. The speech synthesis example would highlight the words it was reading making it excellent for teaching reading phrases to kids in the summer reading program and to be able to do that in interapplication communication or something to any application from an os x hearit would be supercool to beat Apple to doing, sort of a Holy Grail to aspire to.
I don't think my writing is too sharp today, I hope I've lifted you.