Managing Inspiration

Inspiration – an unconscious burst of creativity that we all require during our busy, creative and deadline-looming days. Typically I would start a new project and gain my inspiration from research based on the project or searching my list of bookmarks looking at the same old inspiration galleries. Something needed to change…. I needed my own resource.

I spent some time researching the best solution to organise, categorise and tag imagery and documents – I tried programs such as Evernote, web based solutions, CMS solutions, OSX tagging software and many more combinations of tools and tagging methodologies. The more I thought about it, the more I read, the more I got confused about what I really needed.

My lack of inspiration was holding me back from actually having an inspiration gallery! In the end my temporary solution has become my permanent solution – DropBox (www.dropbox.com).

How does it work for me?

Any image or file I see whilst browsing the web I simply save to my DropBox ‘photo gallery’ folder. If it’s not an image (such as a log-in form) then I use OSX’s grab software to take a screenshot. My Dropbox folder is divided up into sub folders such as Annual reports, Illustration, Infographics, Type, Photography etc.

The beauty of Dropbox is all files are automatically synchronised across my computers, can be viewed online as a slideshow via the web interface or can be viewed on my phone with the DropBox App – viewing my gallery on the iPhone can be really useful when you want to show someone a quick idea.

DropBox Screenshot

No Tagging?

Nope, none. Tagging is great when you have time and can apply a systematic and logical approach. Often when I want to be inspired I’m not looking to browse by tags – I just need lots of imagery to flash before my brain, absorb, process and be inspired by.

The price of an Apple

Over the years many people have said to me that they would love a Mac but could never justify the price tag…

“too expensive for something that looks pretty and has a nice user interface, but is essentially just a posh PC”

Only last week a friend mentioned if he had lots of money he could maybe justify the purchase. This got me thinking… is the cost of a Mac overly expensive – have I wasted my money over the years?

I originally purchased my iMac back in November 2007 for £1183. That makes it approximately 46 months old and still going strong. I’m not sure of the current market value but Apple offer a recycling scheme whereby they buy back old computers. Going by their current price my iMac is worth £230. I’m pretty sure I could get more from this via Ebay, social networks or standing on the street corner waving a sign but for the sake of this example I’ll take the rock bottom price.

Apple Logo

So What has it cost me?

£1183 (original cost) – £230 (resale price) = £953/ 46 months = £20.71 per month

Not bad! £20.71 a month to own an iMac which has provided more than enough computing power for the last four years – and that figure will drop for every month it continues to last. Is £20.71 a month a lot of money? I emailed my friend with the figures and asked him to put it in context with how much he spent on his mobile phone contract, his satellite channels or gym membership he doesn’t use.

Is it worth it?

I’m not suggesting Apple computers are cheap – they aren’t. I’m not suggesting you should go out and buy one – don’t. This is just a simple calculation to see what owning a Mac has cost me. If you factor in re-sale value and keep it for four years it suddenly doesn’t look such an expensive purchase as some people would lead you to believe.

I spend a lot of time on my computer, it’s pretty much always on streaming iTunes content, running inDesign, Photoshop, Skype, iOS Simulator etc so for me £20 a month is an excellent price for a brilliant piece of technology.

Responsive Images

Support for CSS3 media queries in browsers has led to much excitement and debtate with regards to delivering alternate web site layouts depending on the screen width – just check out this web site by resizing your browser window from full-width down to a very narrow view.

The main problem when designing for different screen sizes (large desktops and small screen mobile devices) is managing image size and scaling. Whilst browsers that support media queries can use max-width:100%; to scale images to the width of the container (see Ethan Marcotte’s article Responsive Web Design) it doesn’t solve the problem of small screen devices still downloading a large image designed primarily for desktops – you can’t really say your web site is ‘mobile friendly’ if it weighs in with some hefty image file sizes.

An interesting solution – jQuery and HTML5

I thought about this for a while and enlisted the help of my colleague and ColdFusion master John Whish. After much discussion and research John jumped in and helped code a very quick HTML5 and jQuery example.

Check out the demo

So how does it work?

  1. Firstly we need to make the content of the page expand and contract depending on the width of the browser using CSS3 Media Queries. If you don’t know much about Media Queries I would recommend checking out the excellent Less Framework which has been of great inspiration to me. Using the same defaults of Less Framework we have four layouts:
    • 992px – default for desktops and large screens
    • 768px – for tablets
    • 480px – for landscape mobiles and small tablets
    • 320px – for mobile and small screen devices

The following CSS3 will deliver different style declarations (width and padding) for a div called wrapper:

/* Default Layout: Other layouts inherit #wrapper declarations */
#wrapper {margin:0 auto; width:896px; text-align:left; padding:17px 48px 50px;}

/* Tablet Layout: 768px */
@media only screen and (min-width: 768px) and (max-width: 991px) {
  #wrapper {width: 712px; padding:17px 28px 60px;}
}

/* Wide Mobile Layout: 480px */
@media only screen and (min-width: 480px) and (max-width: 767px) {
  #wrapper {width:436px; padding:17px 22px 48px;}
}

/* Mobile Layout: 320px. */
@media only screen and (max-width: 480px) {
  #wrapper {width: 252px; padding:17px 34px 60px;}
}
  1. We have four layout sizes so we need to create 4 images. Create the largest image first then scale or optimise depending on your requirements. I append either -m, -mw, -t or -d to the end of each image for mobile, mobile wide, tablet and desktop. The width of the images depend on your layouts and the width of the parent container. For the purpose of my demo I have used images with widths of 896px, 712px, 436px and 252px.

  1. Once you have four images add them to your HTML5 page using the example code below. The reason we use HTML5 is so we can use the ‘data’ attribute which validates correctly. The data attribute can be called whatever you like providing it is prefixed with data-. For more information about the data attribute the following article on HTML5 5 doctor is very good.
<img src="imagename-m.ext"
data-src-mobile="imagename-m.ext"
data-src-mobile-wide="imagename-mw.ext"
data-src-tablet="imagename-t.ext"
data-src-big="imagename-d.ext"/>
  1. Make sure you link your HTML5 document to the jQuery library.
  2. Add the following jQuery code to your HTML5 document. I’m not going to break it down line by line – essentially jQuery will load each image and replace the default ‘mobile image’ when the browser window hits a specific width.
<script type=text/javascript>
jQuery(function($){
      loadOptimisedImages = function() {
      // get the document width
      var documentWidth = $(document).width();
      var screenType = 'mobile';

      if (documentWidth >= 991) {
       // big screen
      screenType = 'big';
       }

      else if (documentWidth >= 768) {
      // big screen
      screenType = 'tablet';
      }

      else if (documentWidth >= 480) {
      // medium device, for example a tablet
      screenType = 'mobile-wide';
      }

      $('img[data-src-' + screenType + ']').each(function(){
      $this = $(this);
      $this.attr('src',$this.attr('data-src-' + screenType));
       });
  }
      $(window).bind('load resize', loadOptimisedImages);
});
</script>

Benefits

  • Mobile and small screen devices will only load the smallest image. This could reduce the page weight considerably.
  • You can serve different images, for example if you have a detailed image that works well at large sizes you may decide to zoom in or focus on part of the image for your small screen version.
  • Remove Images from small screen layout – It’s a common technique to use display:none in the stylesheet to remove images from small screen layouts. Visually this works but the image is still downloaded in the background. Using this method you have the choice not to display any image for a small screen and thus no download will occur.
  • And the not so good…

    • Image creation – producing four versions of the same image might be seen by many as a nightmare scenario, especially when it comes to making quick edits to a web site. I agree. The fastest solution is to have a template set-up when you can quickly save out four different versions. You don’t need to produce 4 images though, you could just have one for small screens and a large one for the others. Whatever suits your needs.
    • Double Download– we need to specify a default image so those people who do not use Javascript will get a ‘fallback’ image (in this case the small mobile version) rather than nothing at all. This means that the small image is downloaded as well as the correct version hence a double download. There is a way to avoid this by specifying src=”about:blank” however, if a user doesn’t have Javascript they won’t see any images.
    • Image load delay– the small image loads first followed by a brief pause before the desktop version loads.
    • So… is is worth using?

      I don’t think this solution is perfect, far from it. However, its a fairly straightforward and is easy to implement and in certain cases will work quite well. If you have a simple site with large images such as a portfolio or photo page you can quite easily reduce the page weight.

      The whole area of responsive/adaptive design is fascinating to me. As new devices and thus screen sizes appear on the market the goal of delivering fast viewing experiences will promote new ways of delivering the correct imagery to suit.

Actionscript 3 Simple click EventListener

If like me you are making the transition from Actionscript 2 to 3 you may well find that creating simple onPress functions don’t use the same syntax. I checked the Adobe help files but got confused by the overly complex details.

If you want a simple clickable movieClip use the following code. The first line means that the movie clip will act like a button and the cursor will change when the mouse is hovering over.

    movieclip_name.buttonMode = true;
    movieclip_name.addEventListener(MouseEvent.CLICK, onClick);

    function onClick(event:MouseEvent):void{
        trace("Yes, this works!")
    }

Flex 3 default background colour

If you would like to change the default ‘blue’ of your Flex movie as it preloads:

Select Project > Properties > Flex Compiler and under the Additional compiler arguments add ‘-default-background-color #yourcolour’. So if you want a plain white background it would look like:

-locale en_US -default-background-color #FFFFFF

Flex bandwidth profiler

I have just started learning Flex and realised there is no way to test the download speed of your movie and whether your preloader is working as it should – like you can with the bandwidth profiler in Flash.

After a quick search I decided that Charles met my requirements. I have had a quick play with it and the interface is well designed, it has a Firefox extension and most importantly I can test my Flex preloaders are working! It also works on OSX which means I can use it on my home machine as well. Its seems to be a great bit of software and well worth testing.

Update – I couldn’t figure out how to get it to throttle my bin-bug folder which resides on my local drive. To get around this I created a new workspace on my local server (http://localhost/flex/….) which solved the problem. This probably isn’t the correct way to set-up your Flex development environment….. any advice appreciated.

Slide:ology Book Review

I have just had the pleasure of reading slide:ology, The Art and Science of Creating Great Presentations by Nancy Duarte, President and CEO of Duarte Design, the firm that created the presentation for Al Gore’s Oscar-winning film, An Inconvenient Truth.

The book is beautifully designed and illustrated and leads the reader through the process and concepts of creating a visually compelling presentation. Easy to read sections with insightful case studies from some of the world’s leading brands (Adobe, Hewlett-Packard, Mozilla) help convey the message that you need to create a meaningful relationship between you, your slides and your audience rather than a barrage of slides full of nested bullet lists.

Key areas of the book include:

  • Why is a good presentation important and where do you begin
  • Planning, research and brainstorming
  • Displaying data – diagrams and infographics
  • Thinking like a designer – color, grid systems, typeography, layout, templates
  • Movement and animation
  • Interacting with slides
  • Manifesto – The five theses of the Power of a Presentation

The book isn’t about Powerpoint, Keynote or Google Docs, its about concept, storytelling and engaging your audience. It should be read and re-read by anyone responsible for brainstorming, creating, designing and presenting in any organisation who truely cares about their brand.