TweetFollow Us on Twitter

May 94 - A Hack on the Wild Slide

A Hack on the Wild Slide

Tom Becker

Yes, I was there. The Wednesday Night Hack-Off. They filled the room, munching brownies and quaffing caffeine-laced beverages. No, I can't give you any names. They're OOF hackers. Object Oriented Frameworks. Plenty of class, but no hierarchy. They were there, trying out the latest tools. Cranking code until sunrise. Hacking digital data structures into analog engines of computation: the original GUI calculator. Slide rule with a Daystar accelerator.

The spec. It was hand drawn. Just one sheet hot off the copier. It was crude. It was vague. It was factually incorrect. Yes, I wrote it. You got a problem? We didn't want anything to impede the hacker's raw creativity. Besides, this exercise was supposed to be realistic.

I walked in about 8 or so, after the Alger Memorial Pizza Feed. The hacker's den was already hopping. I already knew what I wanted to try: Get started with AppMaker to draw the GUI and generate TCL code. Finish with the fast turnaround times of THINK C.

Started working in a whirlwind of effort. Wait a minute. Things were missing. We're not in AppMaker any more, Toto. Was this alpha code or what? Ran out into the hallway and grabbed Spec Bowers. (At the Frameworks Conference, support is never far away.) He wanted to know how I liked the prototype. It was great, but there was a slide rule waiting for me.

Quickly dropping down a level of abstraction, I copied the starter project from the TCL demos. Renamed the files. Now I had a working app with a window. Time to draw some things. The copy of THINK Reference installed on the machine didn't include the toolbox reference or TCL. Fortunately, most of the toolbox functions I needed were in QuickDraw.h, and there was a printed TCL reference. Created a pane class for each part of the slide rule. Became very familiar with the TCL reference. Created a mouse task subclass to drag the slide. Found a disabled superview that was keeping clicks from getting to the slider. Enabled it. Dragging the slide worked. Undo worked. Added a mouse task to drag the indicator. Tried to remember how to draw logarithmic scales. At this point, I was half done; ready to work on cosmetic issues. Got smooth dragging of the indicator using XOR. Biggest problem was how to control TCL view focus/clipping. Couldn't drag the slide from within a mouse task without flickering. Got it working sort of OK by 6 AM. It was time. Slapped an icon on and shipped it.

Never used TCL before, but no problemo. Anyone with several years of MacApp experience can get up to speed right away. Another big advantage: the quick turnaround times with THINK C. I could make mistakes a lot faster. Experiment and let the compiler check it. Real interactive programming.

Back home, I dug up my copy of An Easy Introduction to the Slide Rule. Isaac Asimov, 1965. "A slide rule," he says, "doesn't seem as impressive as a giant electronic computer, but it has many advantages. It is small enough to put in your pocket, it need not cost more than a couple of dollars, it can't go out of order, and, best of all, it can solve almost any numerical problem that you meet up with under ordinary circumstances. To add to all that, it is simple to operate." Right on.

 
AAPL
$561.28
Apple Inc.
+0.00
GOOG
$614.11
Google Inc.
+0.00
MSFT
$29.75
Microsoft Corpora
+0.00
MacNews Search:
Community Search:
view counter

view counter
view counter
view counter
dockXtender
view counter
view counter
view counter
view counter
view counter

Domino! Review
Domino! Review By Jason Wadsworth on May 21st, 2012 Our Rating: :: CLASSIC WITH FRIENDSiPhone App - Designed for the iPhone, compatible with the iPad Play dominoes with friends online in this social gaming title.   Developer: Flyclops | Read more »
Juggernaut: Revenge of Sovering Review
Juggernaut: Revenge of Sovering Review By Kevin Stout on May 21st, 2012 Our Rating: :: MINI-GAME-FULUniversal App - Designed for iPhone and iPad Juggernaut: Revenge of Sovering is an RPG with great graphics and Infinity Blade-like combat.   | Read more »
Sheep Up! Review
Sheep Up! Review By Rob Rich on May 21st, 2012 Our Rating: :: BAA-BAA-BOUNCEUniversal App - Designed for iPhone and iPad Who knew something as simple as a change in perspective could make such a big difference?   | Read more »
Uncover the Lost Levels in Where’s My Wa...
Fans of Disney Mobile’s hit game Where’s My Water - both the free and paid version – have a lot to be happy about. Disney just added iCloud support for cross-device game synching, and lots of new levels. | Read more »
Scotland Yard Review
Scotland Yard Review By Rob Rich on May 21st, 2012 Our Rating: :: A RELENTLESS PURSUITUniversal App - Designed for iPhone and iPad Whether avoiding detectives or tracking a master criminal, Scotland Yard makes for a good time.   | Read more »
iHeartRadio Hits Major Subscriber Milest...
It seems like just yesterday that radio giant Clear Channel announced the launch of their new music streaming app iHeartRadio.  A few months later the company announced the first annual iHeartRadio Music Festival, bringing in big name acts like Jay-Z, Coldplay and Lady Gaga to perform.  Talk about a way to get your app out there! | Read more »
Bug Assault Review
Bug Assault Review By Lisa Caplan on May 21st, 2012 Our Rating: :: GREAT FOR KIDSUniversal App - Designed for iPhone and iPad Bug Assault brings a fun new control mechanic to this Bug Zapper sequel.   | Read more »
King Pong Takes Crowdsourcing To The Nex...
It seems like every developer nowadays is using Kickstarter as an excuse to work on that pet project they have been kicking around for the last decade.  However, every once in a while someone wants to try something very different, to work towards the betterment of the medium.  Developer App-Different is looking to do just that with the launch of... | Read more »
Jake Escapes HD Review
Jake Escapes HD Review By Kevin Stout on May 21st, 2012 Our Rating: :: SHORT GAMEiPad Only App - Designed for the iPad Jake Escapes HD is a window-jumping action game with humorous thief, Jake.   | Read more »
Put Your Child In The Story With It’s Me...
Parents know that the iPad is a fantastic resource of storybook style apps, ideal for young children. They’ve probably already read the tale of Peter Pan to their kids, either through an app or through a traditonal book. So what makes It’s Me! Peter Pan stand out? It allows kids to get right inside the action. Parents are able to customize the app... | Read more »
All contents are Copyright 1984-2010 by Xplain Corporation. All rights reserved. Theme designed by Icreon.