简体   繁体   English

RichTextBox不在鼠标滚轮上滚动

[英]RichTextBox doesn't scroll on mouse wheel

I have UserControl in SL4 project with a richtextbox with big amount of text in it. 我在SL4项目中有一个UserControl,其中带有大量文本的RichTextBox。 Problem that mouse scrolling doesn't work in it. 问题是不能在其中滚动鼠标。 While I dragging scroll bar - that works and when I press arrows on keyboard - scroll is working too, but when I am trying to use mouse wheel for scrolling - it doesnt work at all. 当我拖动滚动条时-可以正常工作,当我按键盘上的箭头时-滚动也可以工作,但是当我尝试使用鼠标滚轮进行滚动时-根本无法工作。 I've reduced this control to simplest: 我将此控件简化为最简单的:

<UserControl x:Class="CTermsOfUsePage"
    mc:Ignorable="d"
    d:DesignHeight="800" d:DesignWidth="900">
        <RichTextBox  Height="400">
            <Paragraph>
              Big amount of text with many LineBreaks here.
            </Paragraph>
        </RichTextBox>
</UserControl>

But the scroll still doesn't work. 但是滚动仍然不起作用。 I've tried to create a new SL application with such code - all is working fine there. 我试图用这样的代码创建一个新的SL应用程序-在那里一切正常。 I've also checked default styles - there is no style for RichTextBox. 我还检查了默认样式-RichTextBox没有样式。

Are there any suggestion - what can be a problem's source? 有什么建议-问题的根源是什么?

Update: problem occur in Chrome/FF/Opera in IE9 scroll is working fine. 更新:IE9滚动中的Chrome / FF / Opera中出现问题,可以正常工作。

We've found problem source. 我们找到了问题根源。 In project's .aspx file in <div id="silverlightControlHost"> section we have a setting <param name="windowless" value="true" /> . <div id="silverlightControlHost">部分的项目的.aspx文件中,我们有一个设置<param name="windowless" value="true" /> When this parameter has been set to false all worked fine. 当此参数设置为false一切正常。

As well as in IE "true" settings works fine it looks like SL bug. 在IE中,“ true”设置也可以正常工作,就像SL错误一样。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将Scroll事件添加到ListView,并通过鼠标滚轮将其移动,但滚动事件不起作用 - added Scroll event to ListView, and mouse wheel moves it, but scroll event doesn't file 如果您先滚动鼠标滚轮,则不会发生滚轮按钮的中键 MouseDown 事件 - Wheel-button's middle-button MouseDown event doesn't happen if you scroll the Mouse Wheel first 如何避免使用鼠标滚轮后 RichTextBox ScrollBar 自动滚动到最后选择的 position? - How to avoid RichTextBox ScrollBar auto scroll to last selected position after use mouse wheel? 鼠标滚轮事件不适用于选项卡页上的组合框吗? - Mouse wheel event doesn't work for combobox on tab page? 用于鼠标滚轮滚动的UI滚动条滚动灵敏度 - UI Scrollbar Scroll Sensitivity For Mouse Wheel Scroll 隐藏RichTextBox滚动条而不会丢失鼠标滚轮滚动 - Hide RichTextBox Scrollbars without losing Mouse Wheel scrolling 自定义 ScrollViewer 样式中断 RichTextBox 鼠标滚轮滚动 - Customizing ScrollViewer Style breaks RichTextBox Mouse Wheel Scrolling 鼠标滚轮输入未被统一识别 - Mouse scroll wheel input not being recognised in unity 使用鼠标滚轮滚动ListView有时会否定滚动 - Scrolling ListView with mouse wheel occasionally negates scroll 禁用DevExpress XtraScrollableControl的鼠标滚轮滚动 - Disable mouse wheel scroll for DevExpress XtraScrollableControl
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM