Html – What are the advantages of using an imageless button

csshtmlimage

The discussion on this answer to the question "How can I use Google's new imageless button?" Has prompted this question.

Google seems to think that going imageless is good for some reason, but from the comments cited, I fail to see the advantage. Is it worth it to send dozens of lines of HTML and who knows how much CSS to render these imageless buttons, rather than simply load another image, especially when techniques like CSS sprites are available?

When would this technique be preferred? The other question asks how it can be done, but I want to know why it should be done.

Best Answer

  1. Localization (it's easier to translate text than images)
  2. Skinning/themeing (it's easier to change the look and feel with single CSS than recreate multiple images)
  3. Accessibility (screen readers can read properly, text scaling works properly)
  4. Performance (the CSS is shared and so is loaded once from the server)
  5. Functionality (it's easier to expand the button with new UX elements like dropdown arrow when you don't have to change the whole picture)

Btw, the "imageless" button might as well contain an image inside the visual template. This approach is quite similar to XAML's approach to templating and styling the visual tree.