Pages

Wednesday, November 24, 2010

ADT Plugin for Eclipse

Android Development Tools (ADT) is a plugin for the Eclipse IDE that is designed to give you a powerful, integrated environment in which to build Android applications.

ADT extends the capabilities of Eclipse to let you quickly set up new Android projects, create an application UI, add components based on the Android Framework API, debug your applications using the Android SDK tools, and even export signed (or unsigned) APKs in order to distribute your application.

Developing in Eclipse with ADT is highly recommended and is the fastest way to get started. With the guided project setup it provides, as well as tools integration, custom XML editors, and debug ouput pane, ADT gives you an incredible boost in developing Android applications.

This document provides step-by-step instructions on how to download the ADT plugin and install it into your Eclipse development environment. Note that before you can install or use ADT, you must have compatible versions of both the Eclipse IDE and the Android SDK installed. For details, make sure to read Installing the ADT Plugin, below.

If you are already using ADT, this document also provides instructions on how to update ADT to the latest version or how to uninstall it, if necessary.

Adding SDK Components

Adding and updating components in your Android SDK is fast and easy. To perform an update, use the Android SDK and AVD Manager to install or update the individual SDK components that you need. The Android SDK and AVD Manager tool is included in the Android SDK download.

It only takes a couple of clicks to install individual versions of the Android platform, new development tools, new documentation, and SDK add-ons. The new SDK components are automatically installed into your existing SDK directory, so you don't need to update your development environment to specify a new SDK location.

Because each version of the Android platform can be installed as an individual component of your SDK, you can customize your development environment to the Android platforms you are targetting. Testing your app on multiple versions of the platform is very important in order to successfully operate on as many devices as possible. Be sure to install each version of the Android platform with which your app is compatible, then test your apps on AVDs that run each platform.

Monday, November 22, 2010

CSS3 Rounded Image With jQuery

The other day I was trying to style CSS3 border-radius to image element and I realized that Firefox doesn’t display border-radius on images. Then I figured a way to work around it — wrap a span tag around with the original image as a background-image. Thanks to Darcy Clarke for the jQuery code which does the magic tag wrapping automatically.


Goal

My goal to use the CSS3 border-radius and box-shadow feature to make the image element look like the screenshot below.

sample image

Thursday, November 18, 2010

CSS Cheat Sheet

A quick reference guide for CSS, listing selector syntax, properties, units and other useful bits of information.

The CSS cheat sheet is designed to act as a reminder and reference sheet, listing all selectors (as of CSS 2.1) and properties. It includes a visual example of the box model, unit reference for CSS units and the various media types CSS makes allowance for. A description of what is on the cheat sheet follows, or if you are impatient, you can go straight to the full size CSS cheat sheet.

    Properties List

    Thumbnail highlighting properties list. The CSS specification includes a lot or properties, many of which are often forgotten or overlooked. Many of these are shorthand properties, defining many properties in one go. The outside columns of the cheat sheet list all available CSS properties.

    Tuesday, November 16, 2010

    Facebook Announces New Messaging System: “It’s Not E-mail”

    Facebook is set to launch a new “modern messaging system,” said CEO Mark Zuckerberg at a press event this morning in San Francisco.

    Zuckerberg says more than four billion messages are currently sent through Facebook each day. He also shared that Facebook believes that modern messaging is seamless, informal, immediate, personal, simple and minimal. “It’s not e-mail,” he said.

    Interestingly enough, Facebook is handing out facebook.com e-mail addresses to all users. The system, however, is really modeled after chat according to Andrew Bosworth. “People should share however they want to share,” he says.

    The new messaging system is composed of three parts: seamless messaging, cross-platform conversation history and the social inbox. The latter is an inbox for filtering the messages you want, organized by the people you care about. It’s designed to highlight conversations with your real friends and be spam free.

    Monday, November 15, 2010

    CSS Gradients for IE9

    This works with Desktop IE9, Desktop Firefox, Desktop Chrome, Desktop Safari, Desktop Opera, iOS, and Android.

    Attention! IE9 will not destroy the world, kill babies, or take away your home or job.

    Simply put, IE9 is the best browser Microsoft has ever released. Has it caught up to Chrome, Firefox and Safari? No. But that doesn’t matter. It’s still light years ahead of any other version of IE. All of us should be praying every day for IE users to upgrade to it as soon as possible.

    Shortly after the initial launch of the beta of IE9, I began testing to see what kind of support it had for all the rich and exciting features CSS3 offers for Web layout and interaction. The earlier beta’s didn’t have much, but with each release it has gotten better. If you’re already using advanced CSS3 for Web development and never bothered supporting IE before, you’ll want to know what it supports and what it doesn’t. Here’s what it supports at present right from the horse’s mouth. In particular, it supports real CSS opacity, multiple background images, box shadows, border radius, background-clip, background-size, background-position, WOFF for Web fonts, RGBA and HSLA color, box sizing, as well as the full suite of CSS3 selectors. The above post also talks about support for CSS3 2d transforms, however, even with the -ms- vender prefix I am unable to get it to work with the present beta (7).
    Update: Transforms are working in Platform Preview 6, which is different from the present public beta. Microsoft is taking a two track approach to releasing this: the public beta for general users to test and a platform preview where features are introduced but not necessary finalized.

    So what didn’t make it into IE9? First up, the flexible box model. Once you’ve used the flexible box model for layout, it’s as painful as eating glass to go back to using floats and positioning for layout. No text shadow, which is a strange omission considering they have box shadow. No border images. No CSS transitions. The single-threaded nature of JavaScript makes it inefficient for complex animations. Offloading style animations to the browser’s CSS rendering engine frees up JavaScript and allows the browser to use threads and hardware acceleration for better optimization. In my opinion, CSS3 transitions are more important than CSS3 transforms. Since Firefox, Opera and Webkit all support CSS3 transitions to some degree, it’s a odd omission for IE9. No 2d or 3d transforms. As I mentioned before, transforms do not appear to be implemented in the current beta. (Someone correct me if I’m wrong on this.) The thing I love about CSS3 transitions and transforms is that they allow you to create user interactions that make a Web application feel like a native one, blurring the difference between desktop and Web. No CSS3 keyframe animation. If you thought CSS3 transitions were awesome, you be blown away by CSS keyframe animations.

    When I look at IE9′s support for CSS3, it appears they decided to pick the low hanging fruit: border radius, drop shadow, multiple backgrounds, etc. But the flexible box model, gradients, transitions, transforms and keyframe animation are the things in CSS3 that really turn your head.

    I have no experience working with Adobe Flash. I do have extensive experience working with Microsoft’s Silverlight platform. I love how it enables you to create rich, interactive user interfaces where you can customize every aspect of a control’s look and feel. Chrome, Firefox and Safari’s support for CSS3 enables a similar high level of possibilities for the creation of Web user interfaces. IE9 is attempting to achieve feature parity with the other browsers and is making good progress. But if you want to use the CSS3 features that IE9 doesn’t support, you’ll need to find workarounds.

    Presently my main area of focus is the mobile Web on Android, Blackberry 6, iOS and WebOS. That’s a world ruled by Webkit. But I usually make efforts to ensure that my solutions can also work with modern desktop browsers: Chrome, Firefox and Safari. That involves a lot of vender prefixes: -moz, -webkit. And then you need to future proof it by supplying the same property without the vendor prefix. This technique allows browsers that understand the properties, like IE9, to also render them without any extra effort.

    I’m going to take one example of an HTML/CSS3 implementation of iOS’s popup dialog box which I originally created for use on iOS devices and show how I got it to render equally in Chrome, Firefox, IE9, Opera and Safari. At the end of this post you’ll find links to try it out online or download it. One thing, I’m not using any image pieces, just CSS3 properties. Here’s the initial state of the page with the popup in Safari and Firefox:

    popup Initial state

    Here’s the page with the popup in view in Safari and Firefox:

    Here’s the same markup in IE9. Notice how it understands border radius, box shadow and RGBA background color, but cannot render the flexible box model layout nor the CSS3 gradients.

    iPhotography: 10 Pro Tips for Snapping Perfect iPhone Photos

    We’ve brought you iPhotography galleries, resource websites, and now we’re expanding our scope to gather some top tips from our favorite iPhone photographers themselves.

    Besides hands-on experience, we think there’s no better way to improve your own iPhone camera skills than by taking some advice from experts in the field. These 10 pros really know their stuff, and they offered up their best insights. Hopefully their tips will inspire you to pick up your own phone/camera and start shooting, Apple-style.

    Have a read through these 10 interviews for hints, tips and tricks from top iPhotographers located all over the world. Please share any of your own advice in the comments below.


    1. Ted Anthony


    “Seek out fragments. iPhone photography just feels elemental. Because there’s no complicated camera equipment involved, it breaks down walls between the photographer and subject by being uncomplicated and direct.

    “For the first time, every step of the photographic process is self-contained in your pocket. That offers a compelling opportunity to react instantaneously and capture the world as we humans truly experience it — in fragments, pieces, little slivers that, assembled together, make up our reality.

    “I look for opportunities to offer pieces of the world in unusual configurations that make people notice the everyday landscape around them. A disembodied foot coming into the frame, an oddly shaped piece of a glowing neon sign, wine glasses reflected on a tablecloth, translucent packets of sauce in a Chinese restaurant.

    “By confronting people with familiar objects in unfamiliar — and incomplete — contexts, I try to make them think for a moment before the light bulb goes on. Then, in the best-case scenario, their brains will say: ‘Wow. I never thought of that.’ And the more we notice the world around us in all of its miniature geniuses, the better off we are.”


    Wednesday, November 10, 2010

    What Is Android?

    On November 5th, 2007 leading technology and wireless companies came together to announce the future development of a truly open platform for all kinds of mobile devices – Android. Leading this development are Google Inc, T-Mobile, Intel, HTC, Qualcomm, Motorola along with many other companies under the umbrella of the Open Handset Alliance – a global alliance between technology and mobile industry leaders.

    The Open Handset Alliance’s common goal is to foster and develop a new breed of innovation for mobile devices allowing a far better user experience than today’s current mobile platforms. The OHA will provide a far greater degree of openess that will enable developers to work and collaborate in ways never before seen, Android will greatly improve and speed up the process in which new and innovative mobile services are development and made available to the end user.google-android.gif

    Through the development of Android, developers, manufacturers and operators will be far better positioned to ship out new and innovative products far quicker and far cheaper than todays standards. The Android platform will consist of an operating system, middleware, a user-friendly interface and powerful applications. This fully integrated bundle of software will sgnificantly lower the current costs of developing mobile devices and services.

    The Android platform is licensed under one of the most progressive open-source licenses available giving operators and manufacturers unprecedented freedom to design, build and distribute their own products.

    Android SDK Installation Guide

    Here’s a quick start installation guide to get you up and running with the Google Android Software Development Kit (SDK). This guide will describe how to install the Android SDK and set up your chosen development environments. If you’ haven’t already done so you can download the Android SDK from the link below, then we can get started.

    First you’ll need to download the Android SDK source files:
    ( http://code.google.com/android/download.html )

    System Requirements

    In order to first use the Android SDK code and tools for development you will of course need a suitable environment develop from.

    Currently the following operating systems are supported:

    • Windows XP or Vista
    • Mac OS X 10.4.8 or later (x86 only)
    • Linux (tested on Linux Ubuntu Dapper Drake)

    You will also need to install a suitable development environment such as: