Beautiful image from FeaturePics

Blue sky mountain and golden grassland lake in morning.

13. July 2013 17:47 by Kal | Comments (0) | Permalink

FeaturePics Widget 1.0.0 Released

One of my colleagues, Orly, has completed the widgets that I recently discussed here: Daily Photo Fix Right On Your Desktop. You can see them in action at the FeaturePics web site.

FeaturePics Widgets -- It's a new innovation from

All of these gadgets/widgets do essentially the same thing; they bring a selection of FeaturePics images to your desktop in a sort of miniaturized slide show. The content of the slide show is different from day to day and possibly even from hour to hour, because the content comes from an RSS Feed. Some of the FeaturePics RSS Feeds are relatively static, these are the various Author RSS Feeds. These change only when the subject Author changes the selection of images at FeaturePics. But the default RSS Feed shows a selection from the newest images and these usually change every day. Once installed, the gadget requires no further attention -- it downloads the content it needs automatically.

You could conceivably install more than one copy of the Gadget and show more than one slide show. So if you wanted to follow two Authors and also see the latest images you could simply install the Gadget three times and set each to the appropriate URL. Details of how to do that are on the respective download pages.

There are links to download all four versions, Vista (works fine on Windows 7), Mac, XP, and Windows Hta, together with instructions for how to customize the RSS feed that will show up on your desktop.

Check it out, download the gadget of your choice, and brighten up your desktop -- for free.

7. January 2009 23:05 by Kal | Comments (0) | Permalink

Widgets, Gadgets and hta Files – Daily Photo Fix right on your desktop

By now most people have seen either MAC Widgets or Vista Sidebar Gadgets. There are also Yahoo Widgets and Google Desktop Gadgets. All told there  are a whole lot of these little applications out and available. On my Vista Sidebar I keep a CPU speedometer, a local weather Gadget (it is 2 degrees C here in Santa Cruz at this moment), and the Daily Dilbert. I did not pay much attention to them until a client asked for a special purpose version, and then began to look around at what is available and how to do our own.

Yahoo Widgets is where we started. They run on XP, Vista, and MAC, and there is a tutorial for getting started. Little did I know about how different the various platform’s apps are. Orly got the assignment to learn enough to build the first app. He quickly moved through the tutorial and needed a real project, so we decided that should be to capture the FeaturePics daily RSS feed and show the new images in the Yahoo Widget.

Orly goes to school all morning and helps his sister with her homework for part of the afternoon, but in a few days he had a functioning FeaturePics Yahoo Widget. The biggest challenge was learning how to tap into an RSS feed using JavaScript as the primary tool. As promised, the Yahoo Gadget works on XP, MAC, and Vista. But it only runs inside the Yahoo Konfabulator, which is a nice enough application, but Konfabulator uses a significant amount of memory, and on Vista and MAC it is not as nice as the native applications, so on to the MAC version.

Some days later there is a functioning MAC Widget and a week or so later one appeared for Vista. We have been running these in house for a few weeks now and every day or two a bug would get fixed and a new feature appear. In appearance all are very similar, but the functionality of each platform is slightly different, and the widget functionality is also slightly different across versions.

hta_widget The Yahoo Konfabulator is freely available and works well, but from the first I thought it might be possible to build an XP widget that would work without the necessity of first installing a container application. The idea was to make use of a .hta, a technology that Microsoft introduced with Internet Explorer 5.0. Here is the MS take on the subject. The short answer, it works fine. This widget has

very similar functionality to the other versions, every few seconds a fresh delight appears on your desktop. And of course, when you click on the widget the page at FeaturePics pops up in your browser of choice.

It turns out that FeaturePics has a whole series of RSS feeds, including separate feeds for each of the FeaturePics author’s collection of photos. So Orly added a widget variation that allows for a custom URL – you can insert the URL of the feed for whichever author you may choose to follow, and the widget will cycle thru that particular set of photos. There is nothing to keep you from having more than one of these open at a time, so you can easily follow your two or three favorite photographers. I have a few photos for sale there myself, many from my several trips to the Galapagos Islands. You can follow the RSS link without the widget, but I suspect you will be more likely to look at them if they appear one at a time on your desktop. Feel free to browse them here.

We will soon be posting a page on FeaturePics that lays out the various versions and their respective functionalities. You will be able to click a button to download the widget of your choice. Stay tuned.

18. December 2008 00:11 by Kal | Comments (0) | Permalink

FeaturePics API Demo

FeaturePics has released an api (application programming interface) that allows images on the FeaturePics web site to be used on your web site. There are various api options available that you can see described at I was aware of the api, but had not seen it in action. < /p>

I have also been hearing a lot about Microsoft Silverlight that is in the second beta release, but really knew nothing about it. Reports have  it that it will work on any browser and has only about a 4k download to install on the client computer, and the download only needs to be installed once,  the first time a Silverlight app is run. So when I found a small tutorial demonstrating how to use Silverlight in a client application, I decided to take the plunge. < /p>

The tutorial was pretty straightforward and the result was impressive. No problem at all until I tried to run the code and it did not work. It turned out to be a difference between beta 1 and beta 2. I wrote a blog post about how to resolve that issue. < /p> < /p>

While working out the Digg example in the tutorial I thought it might be modified a bit to show how the recently released FeaturePics api could be used in a web application. I made the changes and wrote a second blog post about doing so, including the source code I used to make the application. < /p> < /p>

If you are not a programmer and have little or no interest in this type of technology, you might still be interested to see the page as it turned out. It allows you to search all of the FeaturePics images by keyword, and returns a set of thirty image thumbnails that result. Please note that the set of thumbs in my demo can range from zero to thirty, while the actual number at FeaturPics may be much greater than thirty. When you click on one of them you get a brief summary of the image and a link back to FeaturePics. < /p>

You can see the completed demo application here: < /p>

1. September 2008 16:49 by Kal | Comments (0) | Permalink

Simple Silverlight 2 app - APIDemo - Part 2, Building the FeaturePics API Demo

This post is a continuation of Simple-Silverlight-2-app-APIDemo-Part-1-Building-the-DiggSample. You might want to start with that, as this part modifies it as necessary to extract data using the Developer's Search API. You can see a sample of the xml returned with Sample Query. So the task is to map the fields returned by the FeaturePics query into the display formerly used for the DiggSample.

First step was to copy all the files to a new directory and rename the project, including the namespace, to APIDemo. This could have been done without changing the namespace or copying the files, but I wanted to retain a working copy of the DiggSample while creating ApiDemo.

The Image Class

The DiggSample has the public class DiggStory where the data for each Digg Story is stored. I created a similar class:

namespace APIDemo
    public class FPImage
        public int ImageId { get; set; }
        public string ImageName { get; set; }
        public string Caption { get; set; }
        public Uri ImagePage { get; set; }
        public string ImageFile { get; set; }
        public int Width { get; set; }
        public int Height { get; set; }
        public string Author { get; set; }
        public Uri AuthorPage { get; set; }

The API Query

Now that I have a place to store individual image records, it was time to obtain the data to display. If you followed the DigSample tutorial, you know that the api query is in Page.xaml.cs and looks like this:
        string diggUrl = String.Format('{0}?count=20&', topic);

The FeaturePics API accepts one or more keywords, so I replace spaces, if any, with %20. The FeaturePics query version looks like this:

        string fpUrl = String.Format('{0}&NumberPerPage=30', topic.Replace(' ', '%20'));

This query should return a set of 30 images related to the contents of 'topic'. I should probably note there are other similar query possibilities returning data sets with somewhat different characteristics, but this is a good example.

Testing the Query

I assigned the FPImage fields to the expected query fields, compiled, and entered the first search term, cat. Nothing. Nothing at all was processed by my code. In the course of debugging the problem I noted these declarations:

  <?xml version='1.0' encoding='utf-8' ?>
- <ImageSet xmlns:xsi='' xmlns:xsd='' xmlns=''>

This is a standard .NET Web Service xml output format, but it was the first time I have coded the consumption of such a web service, and I wasted some time learning the necessary syntax. All of the field tags contain the "" string as well as the field name. One way to specify the tag name is:

ImageId = (int)image.Element("{}ImageId"),

Or, you can define the namespace once:

    // define the namespace declaration
    XNamespace nsFP = "";

and subsequently use that definition:

                ImageId = (int)image.Element(nsFP + "ImageId"),

This is how I ended up populating the FPImage class:

void DisplayImages(string xmlContent)
    XDocument xmlImages = XDocument.Parse(xmlContent);
    // define the namespace declaration
    XNamespace nsFP = "";
    var images = from image in xmlImages.Descendants(nsFP + "ImageExt")
             where image.Element(nsFP + "ImageFile").Value != null
             select new FPImage
                ImageId = (int)image.Element(nsFP + "ImageId"),
                ImageName = ((string)image.Element(nsFP + "ImageName")).Trim(),
                ImageFile = (string)image.Element(nsFP + "ImageFile"),
                ImagePage = new Uri((string)image.Element(nsFP + "ImagePage")),
                Caption = !String.IsNullOrEmpty((string)image.Element(nsFP + "Caption")) ? (string)image.Element(nsFP + "Caption") : "No caption found",
                Author = !String.IsNullOrEmpty((string)image.Element(nsFP + "Author")) ? (string)image.Element(nsFP + "Author") : "Artist attribution not found",
                AuthorPage = new Uri((string)image.Element(nsFP + "AuthorPage")),
                Width = (int)image.Element(nsFP + "Width"),
                Height = (int)image.Element(nsFP + "Height")
    ImagesList.SelectedIndex = -1;
    ImagesList.ItemsSource = images;

Some of the early FeaturePics images do not have the Caption or Author fields filled in, so I provide a replacement string.

Displaying the results

The main result page is Page.xaml. Not many changes were made here, text labels were changed to refer to FeaturePics rather than to Digg, and field names were changed to map those found in FPImage.

The image details are displayed in StoryDetailsView.xaml, and it too is very similar to the version in DiggSample. I added a row for the Artist's Images link, and changed the dimensions both of the page itself, and of the column widths. These changes were made in StoryDetailsView.xaml. And of course the field names were changed to match those in FPImage. There were also some CSS type changes made in App.xaml.

Using the control

The DiggSample uses an extremely simple html page to display the control. I wanted something that would show off the possibilities a bit better, so I set about creating APIDemo.html.

The biggest change here was setting height and width constraints on the #silverlightControlHost CSS definition. The page width was also limited and text added above and to the right of the control.

After these changes the control would not display in FireFox. After some trial and error, I found that deleting the CSS body "overflow: auto; " improved the IE display and fixed the FireFox problem.

The point of these changes is, of course, to demonstrate that the APIDemo control could be a part of any web page. It is one possible way to use the FeaturePics search API. And best of all, I learned a bit about Silverlight in the process.

Project files

You can download a copy of my project:

28. August 2008 11:32 by Kal | Comments (0) | Permalink

Simple Silverlight 2 app - APIDemo - Part 1, Building the DiggSample

Scott Guthrie published an eight step Silverlight 2 Beta 1 tutorial. The page that links to all eight parts and explains how to get started is Get Started Building Silverlight 2 Applications.

I did not even really understand what Silverlight is, so decided to get my feet wet with this very basic tutorial. I followed the first two or three tutorials religiously, typing in the code and experiencing a bit of how it works. Then I read the remainder pretty carefully and downloaded the complete demo application at the end.

Scott's demo application performs a search of the Digg api and displays selected parts of the xml returned. has a pretty cool set of Digg APIs that they publish over HTTP.  Because they have a Flash cross-domain policy file in place on their server, we can call them directly from our Silverlight Digg client application (and not require us to tunnel back through our web-server to reach their APIs). has recently published a Developers API, and I have not yet seen the code used in an application, so I hit on the idea of modifying Scott's demo app to provide a FeaturePics API demo. So that was what I set out to do.

Version Issues

When I tried to compile the downloaded Digg demo app there were a few changes necessary due to the Silverlight on my computer is Beta 2 and the code is for Beta 1. Probably the most difficult of these to resolve was the WatermarkedTextBox control could not be found. Google found Kathy Kam, Reflection on the CLF and .NET.

One breaking change you may have noticed between Silverlight 2 Beta 1 and Beta 2 is that WatermarkedTextBox is no longer available in the Silverlight SDK (System.Windows.Controls.Extended.dll). 

We decided to remove the control because in a future version of Silverlight, we will be adding a “Watermark” property to TextBox. Given this upcoming change, it does not make sense to have "WatermarkedTextBox" as a separate control, so we decided to remove the control from Silverlight 2.

Because the update to TextBox will not happen until a future version of Silverlight feel free download and use the WatermarkedTextBox source code and unit test in the mean time. By downloading the source and unit tests you accept the license.

Here is an example on how to use it:


So I downloaded the referenced project, built it, and referenced it in DiggSample, which produced an immediate error because I had previously referenced the System.Windows.Controls.Extended that is included in Beta 2. Possibly I could have just removed that previous reference, but instead I renamed the download project to Extended2. Then I added the following line to the controls definition, and the app compiled.


I happen to have available a couple of vacant domains and I used one of them DiggSample, Beta 2 Version. The search is for Digg Topics only, so try something like football or soccer. 

16. August 2008 12:53 by Kal | Comments (0) | Permalink

FeaturePics Developers API

I just saw a press release for a way to put quality images on your website or blog.

FeaturePics Web services provides programmatic access to the FeaturePics Image Collection.
You can enhance your web site by retrieving images from FeaturePics Image Collection by subject and showing them in layouts suitable for your site design.
FeaturePics supports the XML/HTTP Protocol. As a variant, the Response can be formed in JSON format.
Code examples (C# and Javascript) are at

1. August 2008 18:53 by Kal | Comments (0) | Permalink

FeaturePics rss feed

There is a new rss feed at FeaturePics. It will provide the 150 most recent photos, and typically there are more than that each day. If your RSS Reader supports finding feeds (most do) you can just click on this link: Or if you need the feed url: FeaturePics Daily Images will take you directly there.

1. August 2008 18:49 by Kal | Comments (0) | Permalink

Visual Studio Spell Checker

Elena at FeaturePics asked me to proof read a couple of .aspx pages that are heavy with JavaScript. I spotted a couple of spelling errors early on and decided to see if there is a spell checker.

I found a spell checker for Visual Studio that uses the MS Office Dictionary. At first it showed every 'FeaturePics' as a spelling error, along with 'img' and 'var' and a few more that are key words.  I typed these words into a word document and did the “Add to dictionary” routine. Then I closed VS and reopened it and those words no longer came up as errors. The spell checker can be found here.  At first it did not appear to work, but the 'Check Accessibility' in the next paragraph got both spelling and other errors to come rolling in.

In VS there is an item on the tools menu named 'Check Accessibility'. It compares your doc with what it claims to be. In Elena's case,, and flags all the items that do not conform to the standard.

Really a lot of them are things like enclosing font attributes in quotes. It might be possible to do most of those with a couple of search and replace calls. I put in a bunch of /> tags that way, but did not try to do the more elaborate changes.

20. July 2008 21:06 by Kal | Comments (0) | Permalink

Feature Pics

One of the sites I am involved with is, a full service image provider. There was a nice review at The Artisan’s Shout, a blog by, for, and about Artists. Check out both of these links, and while you are there, take advantage of the free blog image license at FeaturePics.

15. July 2008 10:02 by Kal | Comments (0) | Permalink


<<  February 2017  >>

View posts in large calendar

Month List