[jQuery] Why do i need a delay in $(document).ready when using the center plugin ?

[jQuery] Why do i need a delay in $(document).ready when using the center plugin ?

Hello again,
i'm using the center plugin to center images inside a div. But i have to
call it with a timeout like this:
$(document).ready(function(){
setTimeout("doCenter()",1000);
});
function doCenter(){
$(".jqcenter").each(){
$(this).center();
}
}
I do not really understand why i need a timeout here because DOM should
allready be ready inside of $(document).ready().
The Problem with this is that it fails for some reason in certain cases,
so that the image is misplaced. To me it looks like that in these cases
the function is called to early because if i refresh the page it look fine.
If i replace setTimeOut and call the function direct with doCenter() it
does not work at all.
Do i have a general understanding problem or what am i doing wrong ?
best regards,
Truppe Steven
_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/