height

<li> will not take 100% height of the parent <ul>

こ雲淡風輕ζ 提交于 2019-12-06 19:29:52
问题 I have a <ul> with several <li> items in it all in a single row. The <li> has a nested <span> and an <img> . The <img> height is all the same across all items. But the <span> items contain text which can span on a single line or two lines (depends on text). I have tried appying display:block , float:left , height:100% , and few other suggestions I found, but the shorter <li> items will not take the same height as the taller <li> items. So I am left with a space below the shorter <li> items.

android: How to force TableRows to have the same height?

本秂侑毒 提交于 2019-12-06 16:16:52
问题 I have searched google and stackoverflow thoroughly, but the only answer I get is: set each Tablerow with layout weight = "1" . This doesnt work. Now I have eight rows in a TableLayout , and each contains 5 LinearLayouts . Each of the LinearLayouts contains 2 TextViews , and the FontSizes vary from TextView to TextView . It turns out that the TableRows vary in height, depending on the Fontsizes of the contained TextViews . Strangely enough, it doesnt have any impact on the layout whether I

Jquery accordion not removingClass and not swapping its Expand text for Collapse

自作多情 提交于 2019-12-06 15:00:27
问题 Thanks to @ifaour for a lot of his help! This script includes: Jquery accordion using unordered lists. Active and Inactive states with toggling bullet arrow images Expand All / Collapse All that swaps its text. Equal height columns that expand and collapse when the accordion expands and collapses You can view a demo here http://jsbin.com/ucobo3/24/ (function($) { $.fn.equalHeights = function(minHeight, maxHeight) { tallest = (minHeight) ? minHeight : 0; this.each(function() { if($(this)

UILabel height?

若如初见. 提交于 2019-12-06 14:57:40
问题 I have an uilabel setup with IB and with this code: // setup label sv.text = @"When in the Course of human events, it becomes necessary for one people to dissolve the political bands which have connected them with another, and to assume among the powers of the earth, the separate and equal station to which the Laws of Nature and of Nature's God entitle them, a decent respect to the opinions of mankind requires that they should declare the causes which impel them to the separation.When in the

Why won't my 100% height div stretch to 100% of parent? Not a float

若如初见. 提交于 2019-12-06 12:44:27
http://thestleonardsacademy.org/stlan/extracurricular.php The body and html are 100%, the #content container is 100%, but the child #newstiles won't match the 100% height that I set. I can set a fixed height, which increases it beyond the auto height that it currently seems to use, but 100% does nothing. I must be going mad, or missing something very obvious! Try to add height: 100%; to your #content style. You only defined max-height and min-height. Try to set the position to "absolute" on #newstiles. Then the height is 100%, but then you get some the ugly scrollbar as the total page height

Cross-browser method for getting width and height of a DIV?

前提是你 提交于 2019-12-06 12:31:23
This is my first post, so please go easy on me. I'm sure I'm doing everything wrong. However, I couldn't find any posts that answered the question above. I use jQuery. I'm trying to find a way to get the current width and height of a DIV element, even if they're set to "auto". I've found many ways to do this, but no method returns the same width in IE. It is important that this method is cross-browser, as it will break the layout of the page if different numbers are returned in different browsers. .width() and .height() do not work because in IE, padding is subtracted (e.g. width() returns 25

CSS - div height calculation without “calc”

久未见 提交于 2019-12-06 12:23:20
问题 In my website, I am using two divs that should have their height like in this picture. So, there is a div with height:90px; that is aligned to the bottom of the window, now what can I do if I want the 2nd div (red) to "fill" the rest of the window? Red div should have the height of the window minus the height of the blue div but something like calc(100vh - 90px) wouldn't work, right? Thanks! 回答1: Actually height: calc(100vh - 90px); does work html, body { min-height: 100%; } * { margin: 0;

DOMPDF How to make PDFs height automatic

人盡茶涼 提交于 2019-12-06 12:16:30
问题 I'm afraid that this question does not have an answer, but here it goes. What I am trying to do is get people to fill in various information about them selves in my website, and echo all of it in a HTML template file (which gets converted into PDF later). Since all users have variable amounts of entries and entry lengths, it's impossible to predict the end result height of the document. In other words: the more info a user gives about them selves, the higher in size the document gets. And

Script analysing DIV height non function

江枫思渺然 提交于 2019-12-06 12:06:22
I have the following script that is not appearing to work. var height = $('#sidebar1').height(); var pageHeight = $(window).height(); if ((height) > 600) { alert('haha'); } The ineveitable conlcusion to this script is to have it analayse against pageHeight rather than 600, but I cannot get this to work even with 600. I can only conclude it is something to do with this div: #sidebar1 being a floaty stick element. Here is its CSS. .sidebar { float: right; width: 190px; padding-top:8px; } The script is part of a load whereby the div: #sidebar1 's height expands as content is loaded in based on

Setting a WPF control to expand to fill available space, and no more

醉酒当歌 提交于 2019-12-06 11:15:49
问题 How can I set up a WPF control to fill the available space in its parent's container, but not expand the parent? The following snippet describes the layout I am attempting. I would like the Grid to stretch to accommodate the Expander , and I would like the ListBox only to fill the Grid . I want the ListBox 's scroll bar to appear when the Grid is too small to show all the ListBoxItem s. <ScrollViewer> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="Auto" /> <ColumnDefinition /> <