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

Centering Issues

3 Answers 400 Views
Window
This is a migrated thread and some comments may be shown as answers.
Hondilla
Top achievements
Rank 1
Hondilla asked on 20 Feb 2013, 04:49 AM
Hello,

I am trying to center a Kendo UI Window on screen, but I just cant.

I tried with dynamic content, static content, and always the same result, the window dont get centered.

http://jsfiddle.net/X7qxs/

¿What I am doing wrong?

Thanks

3 Answers, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 20 Feb 2013, 05:03 PM
Hello Hondilla,

The provided jsFiddle demo works as expected and the Window is centered both horizontally and vertically in all browsers. You may have noticed that when the Window height is similar to the browser viewport height, it becomes evident that there is a little more space above the Window widget than below. This is normal and caused by the current Window styling, which uses top padding and negative margin for its titlebar. Is this the issue you are referring to?

Regards,
Dimo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Hondilla
Top achievements
Rank 1
answered on 20 Feb 2013, 05:16 PM
Hello Dimo,

Yes, that's the issue. There is any method to solve this? When I try to center it on big resolution that "little more space" looks bigger.

0
Dimo
Telerik team
answered on 20 Feb 2013, 05:27 PM
Hi Hondilla,

You can use

.k-window
{
    padding-top: 0 !important;
}
 
.k-window-titlebar
{
    margin-top: 0 !important;
}


http://jsfiddle.net/qSBdu/3/show/


Greetings,
Dimo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
Window
Asked by
Hondilla
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Hondilla
Top achievements
Rank 1
Share this question
or