如何在RichEditControl中隐藏标尺

时间:2013-01-23 01:29:16

标签: wpf xaml

我想知道是否有办法在RichEditControl中隐藏标尺,如下所示:

<dxre:RichEditControl x:Name="richEditControl"
                      Grid.Row="1"
                      Margin="10"
                      Height="150"
                      VerticalScrollBarVisibility="Visible"
                      HorizontalScrollBarVisibility="Collapsed"
                      BarManager="{Binding ElementName=barManager1,
                                   Mode=OneTime}" />

1 个答案:

答案 0 :(得分:1)

目前,我创建了一个没有标尺的控件:

using DevExpress.Xpf.RichEdit;
(...)
    public class RulerlessRichEditControl : RichEditControl
(...)
            Options.HorizontalRuler.Visibility = DevExpress.XtraRichEdit.RichEditRulerVisibility.Hidden;
            Options.VerticalRuler.Visibility = DevExpress.XtraRichEdit.RichEditRulerVisibility.Hidden;