Get Yahoo! Widgets 4: faster, organized, at-a-glance view of your information!
Categories
Widget Gallery
Konfabulator 4.5: Cool Developer Features

As you may or may not have seen by now, we’ve released the new Yahoo! Widgets/Konfabulator 4.5. This version was a major undertaking, and there are four particularly cool and important features in it for developers.

  • HTML
  • Flash
  • Full W3C DOM
  • Fine-grained Security

HTM… something or other

Yes, you can now embed HTML into your Widget, thanks to the magic of WebKit. If you wanted, you could pretty much write all of your Widget in HTML. You can also just grab some AJAX code off the web and with a few modifications get it running inside Konfabulator. Your HTML code has access to all the features of the Konfabulator engine if it’s all contained in your Widget bundle. If you are accessing remote sites or scripts, you are restricted to the typical web sandbox. Just add a attribute to your Widget and point it at an HTML file and you’re off! Not only can the HTML view see Konfabulator, but Konfabulator has access to the innards of the web view itself via the ‘base’ attribute of the web object.

Flash! Ahh-Ahhhhhhhhh!

After HTML, there’s Flash. Like HTML, you can deploy a Flash Widget in Konfabulator. If Flash is your favorite language, have at it. Unlike HTML though, Flash cannot access Konfabulator itself, but Flash does provide a number of its own useful functions to get things done. In theory you could write yourself a video-based-community-type Widget now :)

Both HTML and Flash run just as any other view inside your Widget. You can inter-mix them with other Konfabulator objects and control their opacity and rotation, as you’d expect.

Wait? What are you saying?

I’m sure many of you might be asking whether this means we are favoring HTML or Flash for writing Widgets. It does not. We are merely offering them as alternatives. Many developers want to deploy something in HTML to allow them to run a Widget on the Web. Now they can also get a desktop presence in Konfabulator without having to rewrite the code. The same thing applies to Flash. Would I recommend this way of writing Widgets for someone just starting to use HTML? Probably not. It’s way too heavy for most Widget needs - it will consume more resources for not a lot more bang on average. If you don’t require features specific to HTML, or you aren’t porting AJAX code, I still recommend you stick to the native language.

DOM, da-DOM DOM!

Another big change is the introduction of the full DOM. This means the entire structure of a Widget is now accessible via DOM APIs. You can even run an XPath expression across your Widget. Rob does this to find all elements with tooltips in one of his Widgets, for example. You can locate all your Windows simply by saying document.evaluate( “/widget/window” ). Simple. As you are developing, you can also look at your DOM by merely executing document.toXML() in the debug window to see if things are as you expect them to be.

Fine-Grained Security

The new release has an expanded Security Block. It’s enforced if your Widget has a minimum version of 4.5 or later. It lets you specify the things your Widget might want to have access to, such as the file system, http, etc. This information is shown to the user in the new security dialogs. The dialog can now be expanded to display the information in (hopefully) human-readable form.

If your Widget ventures beyond the contract of your security block, an alert is presented and your Widget is terminated with extreme prejudice.

Under The Hood

The DOM really caused us to change our entire infrastructure. This might cause some compatibility issues with some Widgets. For example, one of our own Widgets had a property of an object called tagName. This is unfortunately an official property of a DOMElement these days, and so there was a conflict and the Widget had to be fixed. So as you try your Widgets out on the new engine, be on the lookout for issues like that.

We also have a new JS engine in this release. It’s the first time we’ve upgraded SpiderMonkey since the original Konfabulator release, as far as I know. Like the DOM, this might also cause some subtle issues for your Widgets. One example we ran into with two Widgets in particular is that there’s a class called Block in the new JS, and these two Widgets tried to create their own variables called Block.

We ran about 1000 of the most popular and recently-added Widgets when we tested this version of the product. We fixed everything we found, and when we found something we couldn’t fix (like the issues mentioned above) we reached out to the developer of the Widget to tell them what needed to be changed so they could resubmit their Widget with the fix so that users could hopefully get uninterrupted service.

The good thing about this infrastructure change is that we now have an excellent, solid foundation on which to build. We can add features faster now than ever before. For example, our new Display object took me literally 20 minutes to add. Granted, it was a simple feature, but it would have taken hours previously. This is going to make a huge difference for us. It also means we can start to implement things we never could before.

With our infrastructure out of the way, the next releases are going to focus on features to allow developers to build some amazing Widgets faster and easier than you could in the past.

Bonus!

One other thing: there’s a rudimentary debugger accessible from the debug window now. It’s not 100%, but it’s a start. Eventually there’ll be a UI for it. /help should let you know what the commands are… it’s somewhat akin to gdb. I’ll likely post another entry explaining how to use it.

Until then, enjoy the new features!




The Newness is Here!

A lot’s happened in Widgetland since we first launched the widgets.yahoo.com site more than 2 years ago. Of course we’ve shipped a couple major versions of Yahoo! Widgets, and we’ve improved the site with additions like our Widget badges and the in-page installer. But in that same time, the catalog of Widgets in the Yahoo! Widget Gallery has more than doubled. And to be totally frank, our tools for finding Widgets haven’t quite kept up.

Today, we’re very proud to reveal the fruits of months of hard work and kick-off a new era for Yahoo! Widgets with the brand-spanking-new widgets.yahoo.com. Much of the work in this release went into rebuilding (almost) the entire site from the ground up on top of Yahoo!’s powerful search, community, and personalization platforms. What that means to you is this is just the beginning — we have laid a solid foundation on which we can more rapidly innovate and deliver new features to improve your Yahoo! Widgets experience. But, that doesn’t mean there aren’t plenty of cool things for you to start enjoying today. Far from it, we think the new site is packed with quite a bit of awesome. So, here’s a little primer to get you started.

  • The first thing you will likely notice is the new look. With the most recent update of the Yahoo! Weather Widget a few months back, we began exploring a visual refresh across our entire product suite. You’ll continue to see updated looks in other Yahoo! Widgets products with releases over the next few months.

  • The Widget Gallery is now the central point of focus for the site, and we’ve simplified the navigation into a section for those looking to “Find Widgets” and one for those looking to “Create Widgets.” The reason we’ve focussed on the Gallery is simple: the Yahoo! Widgets experience should be about connecting people with the 4,300+ Widgets in our Gallery and the authors who created them. With our Install-o-Matic technology first deployed in Yahoo! Widgets 4, people can focus on finding the Widget they want without having to worry about any required components.

  • The front page of the Gallery now makes it easy to check-out the top-rated, most-downloaded, and newest Widgets at a glance. You can also keep up to date on what’s happening in those categories or others by subscribing to our new RSS feeds on the front page and on all search results pages. And we have a new Widget Spotlight that now features 5 Widgets at a time and does cool slidey things. :-)

  • In order to be officially Web 2.0 (or are we up to 3.0 at this point?) compliant, we’ve migrated our old category system over to tags. The top tags can be browsed from the Gallery front page. And we surface related Widgets to you on the search results and Widget detail pages via common tags. Currently, tags are editorially assigned. But, we plan to open this up to tagging by Widget authors and consumers in the future.

  • For those of you who know exactly what you want, don’t worry, we didn’t forget about search (as evidenced by that big honkin’ search box on the Gallery front page). As part of the total overhaul of the site, we took advantage of the latest technology from our friends in Yahoo! Search to make Widget searches waaaaaaay faster and more relevant. We also added the ability to sort your search results by relevance, number of downloads, ratings, or date of last update.

  • Once you find the Widget you’re interested in, there’s now more information about it and more ways to show your love (or not). We’ve switched over to Yahoo!-standard ratings (5-stars, but don’t worry we made sure to map all the existing 4-star ratings to the new scale) and reviews, which, among other things, lets you sort reviews by how helpful other people have found them. And we also added our own little Widgety twist with the new “Beautiful,” “Useful,” “Fun” ratings — you can cast one vote in each category, and the one with the most votes shows up below the Widget’s star rating. It’s also now easier to share the Widgets you love by IM, email, or by adding a Widget badge to your own web page.

  • For Widget authors, the one page that was our “Widgets Workshop” has been expanded to become the “Create Widgets” section of the site. In this release, we’ve added more content to help Widget authors with submitting and promoting their Widgets. And we have exciting plans to expand this section into *the* destination for Widget authors to build and manage their Yahoo! Widgets.

    That covers some of the highlights for the initial release, and there’s more info on our What’s New page. There are also a couple of other notable changes:

  • Yes, there are now ads. In addition to the obvious reasons for adding advertisements in general, we actually believe the new graphical ad on the front page and the sponsored links on the search results pages will prove to be valuable tools for Widget authors and thus ultimately consumers as well. One of our top requests from Widget authors has been for a better way to promote their Widgets to the right audiences, and now we’re opening that up in a more systematic way. If you’re interested in learning more, check out the new Promote Widgets page. From a consumer standpoint, the advertising placements are clearly marked and our goal is to make them as relevant as possible. There’s a feedback link on the ad on the front page, so please let us know how you think we’re doing.

  • If you’re reading this (and not in an RSS reader), you will have likely noticed that nothing has actually changed on this page. This blog and the Forums were on separate systems than the rest of the site. And in the interest of focusing all of our effort on improving core functionality, we’ve decided to maintain that split for now. We do plan to eventually migrate both sections to new platforms, but not for a little while still.

  • As of today, Widget authors will need to link their existing Widget Gallery accounts with a valid Yahoo! ID in order to manage their existing Widgets or submit new ones. We apologize for any inconvenience this may cause, but it was truly a necessity. The primary benefit of Yahoo! ID based author identities is the ability to offer more robust author profiles going forward, which we believe will help build stronger connections between consumers and the authors of the Widgets they love. To be clear, there is no forced migration to Yahoo! ID author accounts if you don’t wish to modify your existing Widgets or submit new ones. But those authors who do link their existing Widgets to a Yahoo! ID will be able to customize how they show up in the Gallery, including adding a picture to their author identity. For more information on author accounts, please check out our Help section and join the conversation in the Forums.

    That should be more than enough to get you started, so what are you waiting for? Hop over to the new widgets.yahoo.com and start checking out the new hotness. We really put a lot into this, and sincerely hope you’re as excited about it as we are. And as I mentioned, this is only the beginning — keep checking back for more improvements in the weeks and months to come. We’re also very eager to hear what you think (the good *and* the bad) to help us make the new site even better, so please do make use of the Suggestions link at the bottom of every page.

    Thanks, and enjoy!
    - the entire Yahoo! Widgets team

    P.S. The launch required some DNS changes, so it may take a few days for everyone to see the new site. We apologize for any funky behavior between now and then.




  • Debugging Goodies

    It’s about time for some tips and tricks, and today’s post is all about using the debug window more effectively.

    Evaluate!

    In 4.0.3 and later, we’ve changed the debug window’s evaluate field to actually do what it says now: evaluate. Pretty clever (read: about time). So for example, where you used to type:

    print( x )

    You now type:

    x

    Think of all the saved keystrokes!

    Hidden Commands!

    During 4.0, I ended up adding some commands into the debug window for my own nefarious purposes. I just didn’t put it into the /help command. They are:

    /mem Reports the memory used by JavaScript itself. Note that this is not the memory used by the application as a whole. It’s generally fairly small.

    /gc Forces garbage collection to happen immediately, prints the final memory number. Again, this is the memory used by the JS engine, not by the entire application.

    /tracethrow [on|off] Allows you to see what the file and line number is as an exception happens.

    Secret Functions!

    One of the most useful functions you can use is _dumpViews. You use it as such:

    _dumpViews( windowVariable )

    You’ll end up with a nicely formatted list of views in the specified window. This is helpful if you don’t understand why things aren’t visible, etc. I use this all the time to help debug engine oddities.

    A sample output might look like:

    Window 010AEB30 d:0
    View (010AEE18): (0 0 100 200) d:0 z:-1 v:1 o:255
    Image (01091910): (0 0 140 140) d:0 z:1 v:1 o:255 image001 src: Sun.png
    Image (01091AB0): (0 0 140 140) d:0 z:2 v:1 o:255 clipped src: Sun.png

    In the output, there’s many abbreviated terms. ‘d’ means dirty, and is used internally for drawing. ‘z’ is the z-order of the view. ‘v’ means visible and should be 0 or 1. ‘o’ is the current opacity from 0 to 255.

    That’s all for this time around. Hopefully the above items will help you debug your Widgets more effectively.




    It's Here!

    Yes! Yahoo Widgets 4 is now available for download. This version has a lot of cool new features for users as well as developers of Widgets.

    For those that think we’ve been sitting around drinking tequila and not really focusing on Konfabulator/Yahoo Widgets, today’s the day we show you what we’ve really been up to for these past months. Well, we’ve been drinking some tequila too, but let’s stay focused, shall we? What?!

    Note, by the way, that our new release is called simply Yahoo! Widgets. No more ‘Engine’. It was too much of a pain to say, quite frankly. Not to mention users don’t care about engines, they care about Widgets. Developers might care about the engine, which is why as of this release we are once again calling the core engine Konfabulator! Why not? Everyone still calls it that both inside and outside of Yahoo!, anyway.

    And now, without any further ado, let’s get into all the awesomeness we’ve added in this release.

    Read the rest of this entry »




    All Aboard!

    The Widgets/Konfabulator team is upsizing!

    If you’d like to help us out, or know someone who can, feel free to point them our way. We need help on our engine, as well as a Widget builder to help us build some cool, fun Widgets. Here’s some links to the two positions:

    Widget Engine Engineer

    Widget Builder

    This is a great time to come on board and help out, as we’ve got some amazing plans for our future!