O'Reilly logo

OpenLayers Cookbook by Antonio Santiago Perez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating a new OpenLayers theme

There can be situations where we desire a completely different look for the OpenLayers theme.

As we mentioned in the chapter's introduction and other recipes (Understanding how themes work using the img folder and Understanding how themes work using the theme folder), OpenLayers theming is based on images and CSS files:

Creating a new OpenLayers theme

In this recipe we are going to see how we can create a new OpenLayers theme based on the default theme we can find in the theme/default folder. We are going to change some aspects of the most common controls, such as scale or scale line, overview map, or layer switcher.

Getting ready

To create a new ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required