Поделиться через


DrawingAttributes.IgnorePressure - свойство

Обновлен: Ноябрь 2007

Gets or sets the value that indicates whether ink gets wider with increased pressure of the pen tip on the tablet surface.

Пространство имен:  Microsoft.Ink
Сборка:  Microsoft.Ink (в Microsoft.Ink.dll)

Синтаксис

'Декларация
Public Property IgnorePressure As Boolean
'Применение
Dim instance As DrawingAttributes
Dim value As Boolean

value = instance.IgnorePressure

instance.IgnorePressure = value
public bool IgnorePressure { get; set; }
public:
property bool IgnorePressure {
    bool get ();
    void set (bool value);
}
/** @property */
public boolean get_IgnorePressure()
/** @property */
public  void set_IgnorePressure(boolean value)
public function get IgnorePressure () : boolean
public function set IgnorePressure (value : boolean)

Значение свойства

Тип: System.Boolean
The value that indicates whether ink gets wider with increased pressure of the pen tip on the tablet surface.

Value

Meaning

true

Ink remains a fixed width, regardless of increased pressure of the pen tip on the tablet surface.

false

Ink gets wider with increased pressure of the pen tip on the tablet surface.

Заметки

The greater the pressure on the pen tip, the more ink that is drawn. Set this property to true if you do not want this effect to occur.

The actual width of the ink varies depending on the amount of pressure applied to the drawing surface. When maximum pressure is applied, the width is 150% of the value of the Width property. When minimum pressure is applied, the width is 50% of the value of the Width property.

Примеры

This C# example shows an event handler for a menu item that toggles the IgnorePressure property on and off.

using Microsoft.Ink;
//...
    private System.Windows.Forms.MenuItem menuInkIgnorePressure;
    private InkCollector theInkCollector;
//...
    private void menuInkIgnorePressure_Click(
    object sender, System.EventArgs e)
    {
        menuInkIgnorePressure.Checked = ! menuInkIgnorePressure.Checked;
        theInkCollector.DefaultDrawingAttributes.IgnorePressure =
            menuInkIgnorePressure.Checked;
        Refresh();
    }

This Microsoft® Visual Basic® .NET example shows an event handler for a menu item that toggles the IgnorePressure property on and off.

Imports Microsoft.Ink
'...
    Dim MenuInkIgnorePressure As System.Windows.Forms.MenuItem
    Dim theInkCollector As InkCollector
'...
    Private Sub MenuInkIgnorePressure_Click( _
    ByVal sender As Object, ByVal e As System.EventArgs)
        MenuInkIgnorePressure.Checked = Not MenuInkIgnorePressure.Checked
        theInkCollector.DefaultDrawingAttributes.IgnorePressure = _
            MenuInkIgnorePressure.Checked
        Refresh()
    End Sub

Платформы

Windows Vista

Среды .NET Framework и .NET Compact Framework поддерживают не все версии каждой платформы. Поддерживаемые версии перечислены в разделе Требования к системе для .NET Framework.

Сведения о версии

.NET Framework

Поддерживается в версии: 3.0

См. также

Ссылки

DrawingAttributes Класс

DrawingAttributes - члены

Microsoft.Ink - пространство имен

DrawingAttributes.Width