[fusion-users] Jx.Layout and CSS positioning best practice
Paul Spencer
pspencer at dmsolutions.ca
Thu Aug 14 21:52:40 EDT 2008
Hi Stuart,
You don't need to use Jx.Layout at all, you can remove the Jx.Layout
part and just set the size of your div using CSS.
Jx.Layout provides some logic for managing the size of elements
relative to a parent object and automatically handling the size of the
element. If you can achieve what you want using just CSS, great! Or
you can use your own javascript to handle your sizing logic if you
need to. There is nothing magic about Jx.Layout, we just find it
convenient to create full page layouts that resize with the browser
because it handles a lot of the measuring and sizing code auto-
magically.
Cheers
Paul
On 14-Aug-08, at 4:42 AM, gingerbbm wrote:
>
> Dear all
>
> I don't seem to be able to set the positioning of my Fusion widgets
> using
> CSS. Is my only option to do this in the JavaScript constructor?
> Rather than
> this...
>
> new Jx.Layout(
> 'Map',
> {width: 700, height: 400, left: 200, right: null, top: 70,
> bottom: null}
> );
>
> ...I was hoping I could do this instead:
>
> [JavaScript]
> new Jx.Layout('Map');
>
> [CSS]
> #Map {
> width: 700px; height: 400px;
> left: 200px; top: 70px;
> }
>
> Any advice/comments/wisdom?
>
> Thanks
> Stuart
> --
> View this message in context: http://www.nabble.com/Jx.Layout-and-CSS-positioning-best-practice-tp18977839p18977839.html
> Sent from the Fusion Users mailing list archive at Nabble.com.
>
> _______________________________________________
> fusion-users mailing list
> fusion-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fusion-users
__________________________________________
Paul Spencer
Chief Technology Officer
DM Solutions Group Inc
http://www.dmsolutions.ca/
More information about the fusion-users
mailing list