[Seaside] JQSelectMenu>>bgImage:

Paul DeBruicker pdebruic at gmail.com
Wed Jan 30 20:33:17 UTC 2013


Hi Sabine,

I haven't looked at that since shortly after I uploaded it.  I decided
to stick to the native elements for my project.  The JS code in
Squeaksource may be outdated or just not work with whichever version of
jQuery you're using so check that the version the SelectMenu expects
works with your version of jQuery.

>From looking at the docs for the plugin it looks like they're adding it
to jQuery UI (https://github.com/fnagel/jquery-ui/issues/140) so it
should become easier to use and better documented once that is released
and the seaside packages are updated.


My best guesses for the version on Squeaksource you probably need:

for icons:

	make an array of Dictionaries. Each dictionary has a 'find' key and
value that is a jQuery selector. (e.g. '$("#myId")' ) and a 'icon' key
with value that is a icon name from those shown here:
http://jqueryui.com/themeroller/#!icons=undefined . e.g.
'.ui-icon-carat-1-n'  Then pass that array of dictionaries to the
#icons: method


for bgImage:

	 it needs to be a function that generates a valid css string so
something that returns something like:
'#CCC
url(http://old.jqueryui.com/themeroller/images/?new=cccccc&w=1&h=100&f=png&q=100&fltr%5B%5D=over%7Ctextures%2F03_highlight_soft.png%7C0%7C0%7C75)
50% 50% repeat-x'

so if that was your desired css for the background image was and you
didn't want to do any computation to determine what the css was going to
be you could just:

bgIcons:(JSStream on: 'return "#CCC
url(http://old.jqueryui.com/themeroller/images/?new=cccccc&w=1&h=100&f=png&q=100&fltr%5B%5D=over%7Ctextures%2F03_highlight_soft.png%7C0%7C0%7C75)
50% 50% repeat-x"') asFunction;






Good luck and if it were me I'd just muddle along with native stuff
until jQuery-UI includes SelectMenu as a fully supported UI element.









On 01/30/2013 12:50 AM, Sabine Knöfel wrote:
> Hi,
> 
> I need an example how to use
> 
> JQSelectMenu>>bgImage: and
> JQSelectMenu>>icons:
> 
> The JQSelectMenu is part of JQWidgetBox.
> 
> It works fine but I did not succeed in adding Icons/bg images.
> 
> A code example from someone who is using it would help me
> 
> Sabine
> 
> 
> 
> --
> View this message in context: http://forum.world.st/JQSelectMenu-bgImage-tp4666503.html
> Sent from the Seaside General mailing list archive at Nabble.com.
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
> 



More information about the seaside mailing list