windowsxp — 2013-03-30T22:48:58-04:00 — #1
I have a <td>
I want to set a width to this td.
I am not sure how big width I should set . so I want to measure width and set .
problem is ....how do I measure width ?
(basically I am confused whether I should set width=50 or width = 80 ....but I am not sure how big they would appear in browser.)
Is there any lightweight tool to measure width ?
ralphm — 2013-03-30T23:03:35-04:00 — #2
There are some nice screen measuring tools, like xScope. (I use this all the time.)
But in a browser like Chrome, you can right click Inspect Element, and as you hove over the element in the inspector, it tells you the current dimensions, which is handy too.
Neither. Set widths via CSS.
windowsxp — 2013-03-30T23:21:17-04:00 — #3
I have installed firefox measureIT plugin.
I don't find this tool in pop up window ...how to find plugin in a pop up window ?
I have a td in pop up window and I want to set width there .
windowsxp — 2013-03-30T23:23:14-04:00 — #4
ok...but I need to measure by a ruler ...then only I may get the exact width value.
ralphm — 2013-03-30T23:27:02-04:00 — #5
I don't have that tool, so you'll have to experiment. Anyhow, just set some CSS values randomly and you'll quickly find one that is right.
windowsxp — 2013-03-30T23:34:04-04:00 — #6
I have firebug also.... I can open firebug on a pop up window.
Now I want to set style="width:50" in a TD element in pop up window... .....but firebug is not allowing adding TD attributes on live ..... Is there any workaround here ?
Is it possible adding style="width:50" on live to check ?
ralphm — 2013-03-30T23:42:41-04:00 — #7
Try right clicking on the popup and see if Firebug opens for that window. Otherwise, just put it straight into your style sheet. Anyhow, you need "width: 50px"—you need to set a unit value of some kind.
windowsxp — 2013-03-30T23:52:01-04:00 — #8
yes...it opens....I can inspect element....but how do I add CSS here ? does firebug allow adding styles on the live ? if so ...how ? I'm stuck right here.
ralphm — 2013-03-31T00:25:33-04:00 — #9
Yes. If you double click the styles on the right, you can edit them. But really, you need to put these styles in the style sheet eventually anyway, so I would do it from the start.
windowsxp — 2013-03-31T00:59:56-04:00 — #10
my issue is resolved.... thanks.
one more thing ...instead of 50px ....I'd prefer the style in % ....How do I convert this into % ?
Is there any easy work around for this ?
ralphm — 2013-03-31T01:48:09-04:00 — #11
Change "px" to "%".
Obviously, 50% is not likely to equal 50px, so you'll have to recalculate the value as well. 50% means half the width of the element's container.
sageshark — 2013-04-03T06:09:53-04:00 — #12
I use Web Developer Toolbar by chrispederick for Firefox for screen measurement. It has a very good ruler option under 'Miscellaneous' tab. Alternatively you can download and install a tool called 'MB-Ruler - the triangular screen ruler'. Please make search in Google to find it. Thanks.
umairsaleem229 — 2013-04-09T03:21:49-04:00 — #13
i like in px i not like % because in % i always mistake
webcosmo — 2013-04-15T18:59:40-04:00 — #14
If you want to set the width in percents, you can do it just by trial and error. Or knowing the total width of the parent element (table) - you can calculate how much % of that width represents 50px.