Monday, September 23, 2013

Re: getting access to min-width of an element

Thanks,

I found it as well. But it would be nice if GWT would hide these browser specific things.

David


On Mon, Sep 23, 2013 at 5:17 PM, Paul <paul.french@kirona.com> wrote:
A quick google of "gwt getcomputedstyle" gives quite a few solutions, this one looks fine to me:


cheers

On Monday, 23 September 2013 14:04:26 UTC+1, stuckagain wrote:
Hi,

I am trying to get access to the min-width style property on some widget to be able to properly implement a layout.

When I use:
widget.getElement().getStyle().getProperty("minWidth") I always get "" as a result.

The min-width style is set like this:
.myclass {
  min-width: 200px;
}

<div class='myclass'>...</div>

I noticed that when I define the min-width as a style attribute then it works.
<div style='min-width:200px;'>...</div>

What I really need is a way to know what the computed value should be... and this should work on IE8+ and other browsers as well.

Anybody has a solution for this ?

David

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/groups/opt_out.

No comments:

Post a Comment