This is a migrated thread and some comments may be shown as answers.

AutoSize 4px off height when Lightweight

1 Answer 28 Views
Window
This is a migrated thread and some comments may be shown as answers.
Andreas
Top achievements
Rank 1
Andreas asked on 29 Nov 2013, 09:21 AM
Hi,

When using autosize and Lightweight, the height of the window is always 4px to large!

Sample:
<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="window.aspx.vb" Inherits="TestaTredjepartWeb.window" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <asp:ScriptManager ID="s" runat="server">
    </asp:ScriptManager>
    <div>
        <telerik:RadWindowManager ID="RadWindowManager1" runat="server">
            <Windows>
                <telerik:RadWindow ID="RadWindow1" runat="server" VisibleOnPageLoad="true" AutoSize="true" RenderMode="Lightweight" Title="Hello" NavigateUrl="windowcontent.aspx" VisibleStatusbar="false" >
                </telerik:RadWindow>
            </Windows>
        </telerik:RadWindowManager>
    </div>
    </form>
</body>
</html>

Contentwindow:
<%@ Page Language="vb" AutoEventWireup="false" CodeBehind="windowcontent.aspx.vb" Inherits="TestaTredjepartWeb.windowcontent" %>
 
<!DOCTYPE html>
 
<head runat="server">
    <title>This is the title</title>
    <style>
        html, body, form
        {
            padding: 0px;
            margin: 0px;
            overflow: hidden;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
        <div style="background-color: red; height: 300px; width: 300px">
            test
        </div>
    </form>
</body>
</html>

As you can see the red color of the inner content doesn't fill all the way down...

Regards
Andreas

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 02 Dec 2013, 03:04 PM
Hi Andreas,

The several pixels that I was able to observe were caused by the height of the html element. Once I set all main elements' height to 100%
html, body, form
{
    padding: 0;
    margin: 0;
    height: 100%;
    overflow: hidden;
}

things seem fine on my end. This is explained here: http://www.telerik.com/help/aspnet-ajax/radwindow-troubleshooting-autosize-not-correct.html. You can also find attached the pages I tested with along with several screenshots.


Regards,
Marin Bratanov
Telerik
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to the blog feed now.
Tags
Window
Asked by
Andreas
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or