我在div中有一个span,虽然我可以垂直滚动,但是没有滚动指示器显示,就像滚动时我常常在UIWebView中看到的那样。有什么线索吗?
这是用javascript制定的
$(".contentArea").append('<div style="width=300px; height:520px;
overflow-x:visible; overflow-y: scroll; position: relative; top: 0px;
left: 15px;"><span class="description">' + $(this).find("Description").text()
+ '</span></div>');
CSS:
#contentArea{
position:relative;
width:600px;
height:768px;
font-size: 13px;
line-height:20px;
}
span.description {
line-height:17px;
}
答案 0 :(得分:0)
您可以在UIWebView中查找滚动视图并将其设置为显示条:
UIScrollView *scrollView = nil;
for (UIView *subview in webview.subviews)
if ([subview isKindOfClass:[UIScrollView class]])
scrollView = (UIScrollView *)scrollView;
scrollView.showsVerticalScrollIndicator = YES;