Jump to content

  • Log In with Google      Sign In   
  • Create Account


Anthracis

Member Since 22 Jan 2008
Online Last Active Today, 01:51 AM
-----

Posts I've Made

In Topic: Help appreciated with CSS/HTML layout issue

07 November 2012 - 06:57 AM

Yes you are absolutely right.
I did not pay attention to the background color, else I should have seen that.

I forgot to set the right coordinate of the content div to 0px.
so the complete version should be :

<!DOCTYPE html>
    <head>
	    <meta charset='UTF-8' />	 
	    <title>Test</title>
	    <style type="text/css">
	    html, body {
		    margin: 0;
		    padding: 0;
		    height: 100%;
		    width: 100%;
	    }
	    #navbar {
		    width: 100%;
		    height: 30px;
		    background-color: yellow;
		    display: inline;
		    top: 0;
		    left: 0;
		    position: absolute;
	    }
	    #wrapper {
		    background-color: red;
		    width: 100%;
		    height: 100%;
	    }
	    #main-wrapper {
		    background-color: blue;
		    width: 100%;
		    height: 100%;
	    }
	    #sidebar {
		    background-color: orange;
		    width: 32px;
		    left:0px;
		    display:inline;
		    position:absolute;
		    top:30px;
		    bottom:0px;
	    }
	    #content {
		    background-color: green;
		    left: 32px;
		    position:absolute;
		    top:30px;
		    bottom:0px;
	 right:0px;
	    }
	    .clear { clear: both;}
	    </style>
    </head>
	
    <body>
	    <div id="wrapper">
		    <div id="navbar"></div>
		    <div class="clear"></div>
		    <div id="sidebar"></div>
		    <div id="content"></div>
	    </div>
    </body>
</html>

at least that works for me now.

In Topic: Help appreciated with CSS/HTML layout issue

25 October 2012 - 11:19 AM

okay, that is different thing. I can reproduce that effect.
I tried positioning the divs all absolute and came up with the following:

[source lang="xml"]<!DOCTYPE html> <head> <meta charset='UTF-8' /> <title>Test</title> <style type="text/css"> html, body { margin: 0; padding: 0; height: 100%; width: 100%; } #navbar { width: 100%; height: 30px; background-color: yellow; display: inline; top: 0; left: 0; position: absolute; } #wrapper { background-color: red; width: 100%; height: 100%; } #main-wrapper { background-color: blue; width: 100%; height: 100%; } #sidebar { background-color: orange; width: 32px; left:0px; display:inline; position:absolute; top:30px; bottom:0px; } #content { background-color: green; left: 32px; position:absolute; top:30px; bottom:0px; } .clear { clear: both;} </style> </head> <body> <div id="wrapper"> <div id="navbar"></div> <div class="clear"></div> <div id="sidebar"></div> <div id="content"></div> </div> </body></html>[/source]

It seems to produce the right result in IE, FF and Chrome.

Hope that helps

In Topic: Help appreciated with CSS/HTML layout issue

25 October 2012 - 04:53 AM

Ok thanks. I don't have access to IE8 but I'll see if I can find someone who uses it. It doesn't work in Chrome either.



that is strange, I tried it in Chrome and for me it worked the way you described it should work.

As I wrote in my previous post I was not able to reproduce your issue.

By the way I am using Chrome 22.0.1229.94 m

In Topic: Help appreciated with CSS/HTML layout issue

25 October 2012 - 03:31 AM

Hallo,
I have just tried the HTML code you posted in IE 8 and in Chrome and was not able to reproduce your issue.
both bars just end with the end of the window. Not exceeding the height in any of those browsers.
So that seems to be a firefox (as I guess from you using firebug) specific formatting issue.

Unfortunately I have no firefox installed on my working machine to take a look at the effect there.

In Topic: Return class and method of a delegate

11 October 2012 - 06:33 AM

Hi,

the delegate type provides you with all the necessary information. Especially the "Method"-property is helpful for your need.
Its "DeclaringType" gives you the type where your delegate function is defined and with the "Name"-Property you receive the name of the actual method.

So your two methods could look like this:

[source lang="csharp"] public static EaseCategory GetEaseCategory(EaseDelegate easeFunction) { if (easeFunction.Method.DeclaringType == typeof(Linear)) return EaseCategory.Linear; else if (easeFunction.Method.DeclaringType == typeof(Quadratic)) return EaseCategory.Quadratic; return EaseCategory.Sine; } public static EaseType GetEaseType(EaseDelegate easeFunction) { if (easeFunction.Method.Name == "EaseIn") return EaseType.EaseIn; else if (easeFunction.Method.Name == "EaseOut") return EaseType.EaseOut; return EaseType.EaseNone; } [/source]

Hope this helps with your problem.

PARTNERS