# How'd they do that?

**URL:** <https://www.ruby-forum.com/t/howd-they-do-that/108039>\
**Category:** Rails\
**Created:** [June 28, 2007, 5:02pm UTC](https://www.ruby-forum.com/t/howd-they-do-that/108039 "2007-06-28T17:02:42Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeffpritchard](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/43a26b/32.png) [@jeffpritchard](https://www.ruby-forum.com/u/jeffpritchard)\
**Post date:** [June 28, 2007, 5:02pm UTC](https://www.ruby-forum.com/t/howd-they-do-that/108039/1 "2007-06-28T17:02:42Z")

</div>

You’ve seen the new widget builder in the Leopard demos where Steve goes  
to “any” website and chooses a section of it by drawing a rectangle  
around the area of interest, and then hits a magic button, and Voila, a  
new widget is born that tracks the content of that area of that website  
page.

I would like to do something similar for something I’m working on, but I  
have no slightest clue how they are doing that.

Anybody think they have successfully reverse engineered that in their  
head?

thanks,  
jp

---

<div class="post-metadata">

**Author:** ![jeffpritchard](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/j/43a26b/32.png) [@jeffpritchard](https://www.ruby-forum.com/u/jeffpritchard)\
**Post date:** [June 28, 2007, 5:29pm UTC](https://www.ruby-forum.com/t/howd-they-do-that/108039/2 "2007-06-28T17:29:49Z")

</div>

Pretty clever trick isn’t it? The magic is really in the Dashboard  
widgets. Apple has this framework called WebKit. WebKit is the fully  
HTML engine sitting behind Safari web browser, Dashboard Widgets, or  
any Mac OS X application the chooses to include a WebKit view.

The WebClip Dashboard widget is basically a WebKit view with a  
designated visible rectangle. The rocket science is in WebKit and not  
necessarily in the Dashboard widget itself.

On Jun 28, 11:02 am, Jeff P. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)
