Documente Academic
Documente Profesional
Documente Cultură
95 USD
Dashboard
DANNY GOODMAN
SpiderWorks
For more great books, order online at
http://www.spiderworks.com
Copyright 2005 SpiderWorks, LLC. All rights reserved. Unauthorized distribution, duplication, or resale of all or any portion of this book is strictly prohibited.
Table of Contents
3
Table of Contents
Chapter 9: Widget Data Persistence 103 Chapter 14: Interacting with Web Services 168
The Dashboard Preference Mechanism 104 Web Services for Newbies 168
Shell and AppleScript Alternatives 110 The Power of XML 170
The XMLHttpRequest Object 171
Chapter 10: Calling Shell Scripts from Widgets 114 A REST Web Service Widget 174
Shell Commands for Newbies 115 SOAP Queries 189
Accessing Shell Commands from Widgets 118 Other XML Sources 191
Further Shell Command Controls 122
Working With Shell Command Results 123 Chapter 15: "Scraping" HTML Page Content 192
When "Scraping" Makes Sense 192
Chapter 11: Calling AppleScripts from Widgets 130 Technical Issues 193
AppleScript for Newbies 130 A Web Scraping Widget 195
About osascript 131
Controlling Applications Via AppleScript 133 Chapter 16: Widget Troubleshooting 206
Running Saved AppleScript Scripts 138 The Case of the Disappearing Widget 206
Passing Parameters to Saved Scripts 142 Pre-Testing in Safari 207
Dashboard Error Messages 210
Chapter 12: Drag-and-Drop to Widgets 144 Use The Evaluator Lab 210
Not Intuitive, But Useful 144 Debugging widget.system() Usage 211
Dragging for Free 145 Web Service Caching 214
Drag-Related Events 145 Miscellaneous Authoring Tips 215
Handling Dragged Text Data 151
Handling Dragged Finder Items 154 Appendix A: widget Object Quick Reference 216
4
How to Use this eBook
5
About the Author
Publisher Credits
Cover Design: Mark Dame and Dave Wooldridge
Cover Illustration: Mark Frost (iStockphoto.com)
Interior Page Design: Robin Williams
PDF Production: Dave Wooldridge
6
Acknowledgements
7
�
Introduction
ince its earliest days, Apple Computer has excelled at author Douglas Adams built a HyperCard application
putting powerful creative technologies into the hands to help him track data during his foray into ecological
of those who have better things to do with their lives studies. In another case, one of the most popular video
than climb a steep learning curve. Back in the mid- games of the time, Myst, started its development life as
970s, when only a precious elite could ever hope to a HyperCard application.
control a computer, Apple’s co-founders packaged The keys to HyperCard’s success were at least threefold.
a microprocessor and supporting electronics into First, the full development environment was bundled
an attractive plastic case that could be connected to with every Macintosh for the first few years of its life.
a video monitor. Suddenly thousands of computer Second, the development environment used an easy-
novices got the courage to try computing on a personal to-grasp metaphor, where each screen was treated as a
level without an engineering degree or having to build “card” in a “stack” of cards. Third, HyperCard provided
their own machines from scratch. a full-fledged programming language, called HyperTalk,
Jump ahead to the heady, Macintosh-filled days which was, as programming languages go, easy enough
of August of 987, and the company unleashed a for motivated Mac users to pick up with just a little
revolutionary software building kit targeted at non- practice.
programmers. HyperCard became an instant hit with For a variety of reasons, however, HyperCard did not
an enormous following, particularly among Macintosh receive sufficient internal support within Apple to keep
users who had dreamed of special-purpose software pace with other Macintosh technologies, especially
programs whose markets were too small to attract during the transition to Mac OS X. HyperCard, and
commercial developers. Mac enthusiasts from all walks what you could do with it, dropped further behind the
of life had a blast creating HyperCard applications for cool stuff developers were doing with the Mac OS X
themselves and others. For instance, world-renowned modern graphics engine. Except for a few third-party
8
authoring tools, Macintosh application development fell Dashboard, and is officially available as part of Mac OS
back into the hands of dedicated programmers. X version 0.4 (Tiger). As you will see throughout this
book, Dashboard applications—called widgets—consist
In the meantime, the Internet had become a major
Introduction primarily of HTML pages, laid out with the help of CSS,
delivery vehicle not only for information, but
and given life with the help of JavaScript.
applications, as well. Expansion and acceptance of
global standards for representing and delivering content Dashboard may well usher in a new generation of
in the form of World Wide Web pages had taken the excitement among developers of all kinds. I expect we’ll
world by storm. The baton of easy development had see widgets that will be popular among broad swaths of
passed to the Web browser through standards such as Macintosh users, as well as extremely narrowly focused
Hypertext Markup Language (HTML), the JavaScript widgets that only a handful of users would find helpful.
programming language, and Cascading Style Sheets But that’s exactly the point: motivated authors with a
(CSS). Combined, these three tools became commonly little bit of the same experience building scripted Web
known as Dynamic HTML because the scripting pages can blend their authoring and discipline-specific
facilities (and support for them built into the most expertise to create applications for themselves, their
popular browsers) allowed Web pages to “come alive.” families, their colleagues, or the world.
Instead of a flat, unexciting electronic representation
of the printed page, a Web page could be an interactive
experience, allowing for dragging stuff around the
browser window and modifying content or content
styles on the fly if the designer wished. As HyperCard
had done a decade earlier, DHTML empowered
countless individuals—both experienced programmers
and complete newbies—to author smart applications,
including many for specialized audiences that would
not otherwise ever see such applications become reality.
Fast-forward to 2004, when Apple first released
information to the world about a new development
platform designed for Mac OS X that could attract not
only experienced programmers, but also those with
experience in developing the equivalent of Dynamic
HTML pages for the Web. That platform is called
9
What You Should Know What You Can Expect to Learn
To get you digging into Dashboard widgets as quickly I want to help you uncover the great Dashboard widget
as possible, this book assumes that you have some author inside you. To that end, this book gives you the
Introduction familiarity with the main widget building blocks: fundamental tools and knowledge to help you translate
HTML, CSS, and at least the basics of using JavaScript your dreams into widgets. The learning process is a
for programming Web pages (client-side JavaScript). gradual one, starting with guidelines for thinking about
If these technologies are new to you, you can search widgets and their designs. I’ll show you an effective
the Web for tutorials that will help get you started. development sequence that will help speed your
You’ll also pick up a lot from the copious source code acquaintance with the Dashboard environment and get
examples and descriptions throughout this book. you past that “Where do I start?” hurdle for any widget
project.
You should also be familiar with Mac OS X from a
user’s point of view. You should know the location of You’ll receive a pair of templates that jump-start your
both the user and System Library directories. Even if widget development, including pre-written code that
you don’t have this information committed to memory, handles neat effects like flipping a widget from front to
you should be able to scan your way around the Finder back and the gradual fade-in of a widget’s Info button.
to locate these important directories. You’ll then meet an authoring tool called The Evaluator,
which will give you x-ray vision into your widgets
To help you locate various directories, this book uses while under construction, and will provide a living
the convention of displaying path names starting with a workbench for experimenting with JavaScript and the
forward slash (/) as meaning a path beginning from your Document Object Model (DOM).
startup disk volume; path names starting with a tilde (~)
mean the path begins from your user (home) directory. Each of the remaining chapters focuses on a specific
aspect of widget development, such as saving
Creating Dashboard widgets will likely bring you into preferences, making widgets resizable, and connecting
contact with several Macintosh and Web standards widgets to the Macintosh system or the Internet. Each
technologies, many of which are discussed in later of these chapters tries to anticipate the questions and
chapters of this book. Even if you aren’t well-versed in concerns you will have in implementing these features
subjects such as Unix shell commands, AppleScript, or into your own widgets. You’ll see lots of code from
extracting information from XML documents, you’ll complete widgets that demonstrate these features in
find that the source code examples here go a long way action—code you’ll be able to use as a foundation for
to demonstrate how you can use these techniques to your own designs.
make your widgets do amazing things.
10
The final chapter provides practical tips on Download the Companion Files
troubleshooting widgets while you’re working on them. This book has a lot of programming code associated
Here, again, The Evaluator tool will save you loads of with it. Fortunately you won’t have to type any of it. The
Introduction time in understanding what’s going on inside your companion files for this book can be downloaded from
widget. the Spiderworks Customer Download Center at:
By the end of the book, you will have seen how to apply http://www.spiderworks.com/extras/
widely known Web authoring technologies to create To login, you will need your Customer Username and
truly cool widgets. You may be inspired to explore Password that was e-mailed to you upon completing
additional Macintosh programming topics (to create your online purchase. Once you have downloaded and
widget plugins, for example), but the opportunities expanded the .sit file (using Stuffit Expander) place the
open to you with the subjects covered in this book are resulting folder in a convenient location on your hard
virtually unlimited. disk. Inside the folder are subfolders for most of the
chapters (not all chapters have companion files). You’ll
find the ready-to-run widgets and other files mentioned
in the chapter.
In later chapters, you may find the more complex code
examples easier to read in their original form in a text
editor. Without the space constraints imposed by the
printed page, the flow and organization of these listings
will be clearer.
11
I
Chapter 1 Getting Started with Dashboard
want you to have fun getting to know Dashboard and Thoroughly Modern Desk Accessories
also appreciate its context in the Macintosh universe. In One of the benefits of having been a Mac user since its
this chapter, you’ll learn about precursors to Dashboard, earliest days (even a month before its first 984 release,
where Dashboard pieces live on your Mac, the software I’m proud to say) is that I’ve witnessed every stage of
tools you need to develop Dashboard widgets, and how evolution of both the hardware and the Macintosh
to set up a productive development area on your hard operating system. That also means that I can bore
disk. modern readers to tears with tales of the “old days.” I’ll
try to keep the reminiscences to a minimum.
Behind the Dashboard Here are a two non-intuitive, but seriously helpful
Most of the plumbing for Dashboard is out of view. Dashboard shortcuts:
Although a Dashboard icon appears in the Mac OS 4 Quickly closing a widget. Instead of clicking the
X Applications directory (see Figure .), Dashboard Open button to reveal all widgets’ close buttons, simply
is not a program that you start and stop like other press the Option key while rolling the cursor atop a
applications—it runs as a background service as part widget. The close button appears for that widget.
of the Dock application (the icon represents a service 4 Reloading a widget. While viewing a widget in
launcher). The service controls the shared aspects of Dashboard, click on the widget to make it active. Then
Dashboard you see on the screen, such as the widget press Command-R. Watch the reload swirl show!
close icons and the Widget Bar. If you intentionally or
accidentally remove the Dashboard icon from the Dock, One of the benefits of having each widget operate as
you can restore it by dragging the Dashboard icon from its own process is that if one should crash, it shouldn’t
15
have any affect on other running widgets or the the startup disk and/or the Library directory of the
Dashboard server. And, in another example of the Mac current user. All widgets whose files are located in
OS working behind the scenes in your behalf, if a widget either of these directories automatically appear as icons
Chapter 1: crashes, the Dashboard server automatically restarts in the Dashboard Widget Bar. Authors are strongly
Getting the widget. Only if the widget fails three times in a encouraged to include a customized icon with your
Started row within approximately 60 seconds does Dashboard widget that represents the widget in the Widget Bar.
with remove the widget from the list of active widgets.
Dashboard You may launch a Dashboard widget by double-clicking
on the widget file in the Finder, even if the file is not
The Role of WebKit located inside one of the special Widgets directories.
Part of Apple’s decision to adopt the KHTML browser A widget launched this way does not appear in the
engine as the basis for the Safari browser was the plan Widget Bar even while it runs.
to develop a general-purpose engine that third-party
One other directory holds some shared resources
developers of Macintosh software could call upon
that both Apple’s own widgets and widgets you create
with ease. Therefore, a programmer who wants to
may use. Inside the /System/Library/WidgetResources
build some Web browsing or rendering facility into a
directory are some generic pieces of art for things like a
program does not have to build a new rendering engine
standard graphical button and the small Info (“i”) icons
from scratch. Instead, by incorporating what is called
you see in many widgets. You should treat this special
WebKit, the new program has instant access to the
directory as an Apple resource, whose contents may
identical rendering engine that Mac users experience
change over time. Don’t put your own resources in this
with Safari.
directory, even if you intend to share them across your
Because the foundation of a Dashboard widget is an own widgets.
HTML page, it made sense for Apple to incorporate the
powers of WebKit into Dashboard (or was it the other
way around?). As you will see later in the next chapter,
the harmony between the Safari and Dashboard
HTML rendering engines assists you during the widget
authoring process.
19
N
Chapter 2 Anatomy of a Widget
23
Your First Widget
It’s now time to create our first widget. The purpose
of this exercise is to help you get the feel for the basic
Chapter 2: components and work flow (although I’ll have more to
Anatomy of say about the development cycle in Chapter 5).
a Widget
Our widget will be a one-sided temperature converter,
which converts Fahrenheit to Celsius or vice versa.
While I normally like first-timers to do all of the typing
to get a hands-on feel for the work involved, there is Figure 2.3. The Temp Converter widget upon completion.
a bit more code here than I’d force on newcomers.
Therefore, you can find the readymade folder (named Built into the scripting for this widget is one safeguard
Temp Converter) in the Chapter02 directory of the to assure that only one conversion is performed at a
companion files for this book. You should, however, time: Whenever the user types in one field, the other
examine the contents of these files as I discuss them in field is cleared of any previous content. Additionally,
the remaining sections of this chapter. to keep the interface and calculations simple for this
example, only whole numbers in the range of -99
through 999 are accepted; results are also limited to
Overview that range.
To help you visualize what this widget looks like and
how it operates, Figure 2.3 shows the final widget. It When the widget bundle is completed, its contents will
consists of a background image (a simple light blue look like those shown in Figure 2.4. Again, for the sake
rounded rectangle) with some text, two text input fields, of simplicity, all of the HTML, CSS, and JavaScript code
and an action button. A user enters a temperature in for this example will be held within a single .html file.
one field and clicks the button to find the result in the
other text box.
24
Chapter 2:
Anatomy of
a Widget
<body>
<div id="title">Temperature Converter<hr />
</div>
<div id="form">
Figure 2.5. The blank background image (.png). <label id="F" class="field">°F<br />
25
<input type="text" id="inputF" size="3" (the onkeydown event handlers) and each click of
maxlength="3" onkeydown="checkInput(event)" />
the button (the onclick event handler). The event
</label>
<button id="convertButton" handlers invoke functions described later in this
Chapter 2: onclick="convertIt()">« » chapter.
Anatomy of </button>
<label id="C" class="field">°C<br /> Without the help of CSS specifications, the HTML
a Widget
<input type="text" id="inputC" size="3" elements in the code above render in Safari as shown in
maxlength="3" onkeydown="checkInput(event)" /> Figure 2.6. It’s a mess, but it provides the fundamental
</label>
pieces that you can use to begin “laying out” the
</div>
</body> elements with the help of CSS positioning and other
</html> style properties.
<style type="text/css">
body {
background: url(Default.png) no-repeat;
margin: 0px;
font: 12px Helvetica;
}
#title {
position: absolute;
top: 14px;
Figure 2.7. The background image is in place, as are basic
left: 0px;
font settings. width: 165px;
text-align: center;
font-weight: bold;
font-size: 13px;
27 }
hr { JavaScript Interactivity
width: 80%;
All the scripting for this widget is contained within
}
two JavaScript functions. The first, checkInput(),
Chapter 2: #form { executes each time the user presses a key while
Anatomy of position: absolute; typing into either of the two text boxes. Relying on
a Widget top: 45px;
information embedded in the event object passed as
left: 17px;
} an argument, the function first determines in which
field the user is typing, and empties the contents of
.field { the other field. Next, the function blocks the default
position: absolute;
keyboard action for all characters except the numbers
text-align: center;
} 0 through 9, the minus sign, Delete, and Tab. Because
widgets cannot display JavaScript alert dialog boxes
#F { to provide traditional data entry validation warnings,
left: 14px;
the widget instead quietly and gracefully refuses to act
}
except on keys that it allows.
#C {
The other function, convertIt(), is invoked by
left: 85px;
} the click of the button between the two text fields. To
permit one button to act as a bi-directional calculation
#convertButton { button, the function uses the empty status of the
position: absolute;
text boxes to determine which way the calculation
left: 51px;
top: 11px; should progress (and therefore which formula to use
height: 20px; in the process). Once the result is calculated, it is
background-color: orange; checked against the acceptable range of values (up to
color: darkblue;
three characters in length). If the result is outside the
font-size: 14px;
} acceptable range, the result field is filled with three
</style> asterisks. The entire script section of the head for the
widget’s .html page is shown on the next page.
28
<script type="text/javascript"> outFld = fFld;
// Process each keystroke in a field }
function checkInput(evt) { // verify that outVal is a number
// empty the other field if (!isNaN(parseInt(outVal))) {
Chapter 2: if (evt.target.id == "inputF") { // and limit result to three characters
Anatomy of document.getElementById("inputC").value = ""; if (outVal < -99 || outVal > 999) {
a Widget } else { outVal = "***";
document.getElementById("inputF").value = ""; }
} outFld.value = outVal;
// block keys that aren’t numbers, -, }
// Tab, and Backspace }
if ((evt.charCode < 48 || evt.charCode > 57) && </script>
evt.charCode != 45 && evt.charCode != 8 &&
evt.charCode != 9) { All of the scripting in this widget runs inside Safari
evt.preventDefault(); // discard keystroke
(i.e., it does not contain any coding that refers to the
evt.stopPropagation();
} widget object, as discussed in Chapter 3). Therefore,
} you can test the scripting and operation of this widget
entirely within Safari.
// Perform conversion from filled field
// to empty field
function convertIt() { Specifying the Property List
// initialize global variables If you have not had experience creating property list
var inpFld, outFld, inpVal, outVal = "";
(.plist) files with Property List Editor, you can start out
var cFld = document.getElementById("inputC");
var fFld = document.getElementById("inputF"); by opening an existing widget’s Info.plist file (from
any example widget or the ones provided among the
if (cFld.value == "") { companion files for this book). Click the triangle next
// handle F to C (not when both fields are empty)
to the Root node to expand the list of properties for
if (fFld.value != "") {
inpFld = fFld; the current list. Alter the necessary fields and save the
inpVal = inpFld.value; file as Info.plist inside the folder you’re using for the
outVal = Math.round((inpVal-32)/1.8); current widget development.
outFld = cFld;
} The important fields that need to be customized for
} else { each widget are the ones involving naming of the bundle
// handle C to F
and HTML file. Figure 2.8 shows the Info.plist for the
inpFld = cFld;
inpVal = inpFld.value; Temp Converter widget. To edit any of the text values,
29
outVal = Math.round((inpVal*1.8)+32); double-click on the value in the rightmost column. This
action turns the value into an editable text field.
Chapter 2:
Anatomy of
a Widget
31
License Agreement
This is a legal agreement between you and SpiderWorks, LLC, a Virginia the Book. If you violate any part of this agreement, your right to use this
Limited Liability Corporation, covering your use of this electronic book Book terminates automatically and you must then destroy all copies of the
and related materials (the “Book”). Be sure to read the following agreement Book in your possession.
before using the Book. BY USING THE BOOK, YOU ARE AGREEING
The Book and any related materials are provided “AS IS” and without
TO BE BOUND BY THE TERMS OF THIS AGREEMENT. IF YOU DO
warranty of any kind and SpiderWorks expressly disclaims all other
NOT AGREE TO THE TERMS OF THIS AGREEMENT, DO NOT USE
warranties, expressed or implied, including, but not limited to, the implied
THE BOOK AND DESTROY ALL COPIES IN YOUR POSSESSION.
warranties of merchantability and fitness for a particular purpose. Under
Unauthorized distribution, duplication, or resale of all or any portion of no circumstances shall SpiderWorks be liable for any incidental, special,
this Book is strictly prohibited. No part of this Book may be reproduced, or consequential damages that result from the use or inablility to use
stored in a retrieval system, shared or transmitted in any form or by any the Book or related materials, even if SpiderWorks has been advised of
means, without the prior written permission of the publisher, except in the the possibility of such damages. In no event shall SpiderWorks’s liability
case of brief quotations embodied in critical articles or reviews. exceed the license fee paid, if any.
By using the Book, you acknowledge that the Book and all related Copyright 2005 SpiderWorks, LLC. “SpiderWorks” is a trademark of
products constitute valuable property of SpiderWorks and that all title SpiderWorks, LLC. Macintosh is a trademark of Apple Computer, Inc.
and ownership rights to the Book and related materials remain exclusively Microsoft Windows is a trademark of Microsoft Corporation. All other
with SpiderWorks. SpiderWorks reserves all rights with respect to the third-party names, products and logos referenced within this Book are the
Book and all related products under all applicable laws for the protection trademarks of their respective owners. All rights reserved.
of proprietary information, including, but not limited to, intellectual
properties, trade secrets, copyrights, trademarks and patents.
A synchronous 160
Apple Developer Central 70
accessibility 33, 70 Apple Developer Connection 18, 40
Activity Monitor 15, 212 Apple Human Interface Guidelines 70
Adams, Douglas 8 Apple menu 13
Address Book 130 Apple widgets
Ajax 39 Calculator 98
alert() 93 Dictionary 46, 166
AllowFileAccessOutsideOfWidget key 83, 217 Stock Quotes 168
AllowFullAccess key 83, 129 iTunes Controller 50, 133
AllowInternetPlugins key 83 Phone Book 46
AllowJava key 84 Unit Converter 49
AllowNetworkAccess key 84 Weather 39
AllowSystem key 84, 111, 129, 135, 211 World Clock 39, 49
Amazon Ranker widget 174-88 applications
.css File 179 Using AppleScript to access 130
.html File 177 Aqua 49, 71, 177
amazonranker.js File 180 array
flip.js File 179 converting to string 188
objectsArraysStrings.js File 179 array sorting 185
objectsArraysStrings.js file 188 associative array 181
Amazon Web Services 174, 180, 181, 185 Asynchronous JavaScript and XML (AJAX) 39
animation authoring tools 17
flip 66, 217
Info icon 61, 65 B
resizing 158, 163
anonymous functions 171 background-image CSS property 25
-apple-dashboard-region CSS property 41 banner ads 50
AppleScript 10, 33, 38, 52, 84, 102, 110, 113, 144, 155, 161, 209 bash shell 116
dictionaries 131 BBEdit 17
invoking asynchronously 161 Berkeley UNIX C shell 116
passing parameters to 156 black_i.png 48
reading and writing files with 113 blur event 97
running saved scripts 138 book widgets, See also individual widgets
scripting additions 113 Amazon Ranker 174-88
221 script file 161 Countdown Timer 99-101, 107-9
Index
Hypertext Markup Language (HTML) 9 init() function 56, 60, 61, 62, 109, 180
Hypertext Transfer Protocol (http) 169 innerText property 202
Inside Macintosh 13
I Internet Explorer 41, 87, 145
iTunes 15, 39, 130, 133, 158, 161
Icon.png 21, 78 iTunes Remote widget 133-37, 158-61
iframe element 193, 196, 201 .css File 134, 159
problems writing to 194 .html File 133, 158
Illustrator 37, 71, 72, 175 .js File 135, 160
image Info.plist File 135
determining size 27
Info.plist file 22, 29, 31, 52, 79-86, 110, 207, 211 J
editing by hand 81
editing in Property List Editor 81 Java 39
keys JavaScript 9, 10, 13, 14, 19, 21, 28, 33, 36
AllowFileAccessOutsideOfWidget key 83, 217 quick reference 37
AllowFullAccess key 83, 129 JavaScript Console 18, 87, 207, 210
AllowInternetPlugins key 83 Java applets 84
AllowJava key 84 join() method 142
AllowNetworkAccess key 84 .js files 21
AllowSystem key 84, 111, 129, 135, 211 importing 36
CFBundleDisplayName key 31, 78, 84
CFBundleIdentifier key 31, 78, 84, 104 K
CFBundleName key 31, 78, 85
CFBundleShortVersionString key 85 KHTML 16
CFBundleVersion key 85 Konfabulator 13-14
CloseBoxInsetX key 85
CloseBoxInsetY key 85 L
Fonts key 85 label element 26
Height key 86, 135, 152, 157 Library/Widgets directory 78
MainHTML key 31, 57, 78, 86, 206 Library directory 16
Plugin key 86 localhost 155
Width key 86, 135, 152, 157 localizing widgets 20, 84
Security-related keys 83
Info button 16, 48, 58, 60, 61, 65, 66, 68, 77, 175, 179, 188
224 fade effect 64
Index
U finding 174
Web Services Description Language (WSDL) 174
United States Geological Survey (USGS) 195 Web standards 33
Universal Access 70 which command 126
Unix 38, 114 white_i.png 48
uptime command 117, 123 widget
Uptime widget 123-29 authoring cycle 11, 54, 69
.css File 124 backgrounds 48, 70
.html file 124 background image 21, 25, 26, 98, 175
.js file 125 background processing 51
URI close button 15, 22, 102
vs. URL 155 closing 15
URL crash 15, 206
relative 83 creating a bundle 22, 31, 78
user directory 10 debugging 17-18, 19, 77, 87-88, 206-15
user interface design 33 disappearing 206
flipping 48, 59-68
V flipping animation 66
HTML file 21
viewport icon 21, 78
widget window as 157 initial size 21, 86, 95, 152, 157
Volume Info widget 138-41, 154-56 launching 16, 82
.css File 139 localization 20, 84
.html File 138 multiple instances 106
.js File 140 naming 22
.scpt File 139 online help 50
performance 99
W preferences 103-13, 195
W3C 14, 33, 36 reloading 15, 23, 78, 82
W3C DOM 150, 173 resizable 47, 157-67, 195
.wdgt extension 22, 23, 31 screen size 46
Web Kit 16, 17, 21, 34, 37, 40, 71, 93, 146, 154, 206 size 21, 86
Web pages, scraping 192 templates 54-68
Web Services 46, 37, 103, 192 testing 78, 101, 207
caching 214 using outside of Dashboard 19
227 viewing bundle content 23, 78
Index
SpiderWorks