[geojquery] jQuery UI Themes

Volker Mische volker.mische at gmail.com
Mon Sep 20 07:04:58 EDT 2010


On 20.09.2010 08:52, Javier Carrasco wrote:
>
> I started to work on styling the map with the standard
> jQuery UI classes to provide support of jQuery UI themes.
>
> To do this I had to do 2 things:
>
> 1. Create the map using a custom css (with no colors or fonts)
>
> $.widget("geo.geoCore", {
> // default options
> options: {
> allOverlays: true,
> theme: 'jqui.css'
> },
>
> 2. Add jquery standard classes after the creation of the map
>
> $(".olControlLayerSwitcher")
> .addClass("ui-widget")
> .addClass("ui-corner-left")
> .addClass("ui-widget-content")
> ;
> ...
>
> I did a screenshot (work in progress), you can see it here[1]
>
> I think doing this is a bit dirty but I did this way
> because I didn't want to edit jQuery's code.
>
> The questions are:
>
> - Do you know a better way to do that?
> - Do you think it is useful or everybody will use external
> components like here [2]?
>
> [1]
> http://gitorious.org/~jacarma/geojquery/jacarmas-geojquery/blobs/master/img/mintchoc-redmond.png
> [2] http://demo.mapfish.org/mapfishsample/trunk/examples/map/toolbar.html

Hi Javier,

I think it is fine for now. Though in the feature we have our own 
widgets/buttons so you don't need to add the styles manually but have it 
directly coded into the widget itself.

Cheers,
  Volker



More information about the Mapquery mailing list