Skip to main content

Unlable to set height for dcontainer

9 replies [Last post]
hmistry
Offline
Joined: 2008-08-04
Points: 0

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
gmurray71
Offline
Joined: 2003-07-31
Points: 0

Try

As with all jMaki widgets the dContainer widget sizes to fit the container (html element) that you place it in.

So the best way to set is size is to put it inside a sized element:

<div style="height:400px">

</div>

hmistry
Offline
Joined: 2008-08-04
Points: 0

Hi Greg

I tried using startHeight as argument but it does not work..
Secondly i tried using the second option as well by putting the dContainer in a div but in this case i am getting 2 vertical scroll bars. one for the container and the other for the div which is not required.
i also tried to use overflow = 'hidden' but in that case i am not able to show the full content.

All what i want is to show the full content with one horizontal scroll bar and one vertical scroll bar. and the height to be 375 and width to be 625

See code attached just remove the comments part
<%--





${version.portletVersion}

--%>

hmistry
Offline
Joined: 2008-08-04
Points: 0

Unfortuanlly when i attach the code in the window it screws but the stuff so i am not able to sow u the code

hmistry
Offline
Joined: 2008-08-04
Points: 0

Sample code is attahed

Please replace the word giv with div.
















${version.portletVersion}




gmurray71
Offline
Joined: 2003-07-31
Points: 0

Hi,

What version of jmaki.js / dContainer are you using?

You can see it by doing using alert("jmaki version is " + jmaki.version);

The dcontainer version will be in the :

/jmaki/dcontainer/widget.json file.

This might help us find the problem but I still suspect it is an issue with the surrounding div.

Can you set the background color of the surrounding div to a different color and verify that it is getting the right size? Firebug can also help verify.

-Greg

hmistry
Offline
Joined: 2008-08-04
Points: 0

i am using a version

Jmaki - 1.8.0-beta2

In jmaki/dcontainer/widget.json file.

"version" : "1.1",

"jmakiVersion" : "1.1",

"author" : "Greg Murray",

I am not getting the size of the div correctly with the code that i have gven before. bit when i give overflow:auto in the div i get the size correct but then the problem is i get 2 vertical scroll bars

see attached code
















${version.portletVersion}




gmurray71
Offline
Joined: 2003-07-31
Points: 0

I don't think the overflow:auto will not work right with a dcontainer though it might if you use startHeight.. The size is meant to be static though you can call resize on them.

Any chance I could get you to verify this with the latest jMaki:

https://ajax.dev.java.net/servlets/ProjectDocumentList?folderID=7943&exp...

The file is:

jmaki-java-1.8.0.zip

It will contain the dContainer two in the lib/jmaki-widgets-1.8.0.zip file

If this doesn't help I'm going to need to see the rendered source of the page you hare having trouble with.

-Greg

hmistry
Offline
Joined: 2008-08-04
Points: 0

I am using Inernet explorer 7.0.6 as my browser is that waht u mean by rendering source

gmurray71
Offline
Joined: 2003-07-31
Points: 0

Can you show me the CSS / HTML you are using?

-Greg