syncfusion-wpf-double-textbox

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Implementing DoubleTextBox

实现DoubleTextBox

This skill collects guidance and examples for the Syncfusion WPF
DoubleTextBox
control. Use this skill to find usage patterns, configuration options, and common gotchas when building WPF apps that accept double values.
本内容汇集了Syncfusion WPF
DoubleTextBox
控件的使用指南和示例。在构建接受双精度值的WPF应用时,可通过本内容了解使用模式、配置选项以及常见问题。

When to Use This Skill

何时使用本内容

  • When adding or configuring a WPF numeric input bound to doubles
  • When restricting values using
    MinValue
    /
    MaxValue
  • When formatting values for different cultures or customizing group/decimal separators
  • When enabling step/scroll intervals, spin buttons, or range adorner
  • When you need examples for XAML or C# usage patterns
  • 当添加或配置绑定双精度值的WPF数值输入控件时
  • 当使用
    MinValue
    /
    MaxValue
    限制值范围时
  • 当为不同区域设置值格式或自定义分组/小数分隔符时
  • 当启用步长/滚动间隔、微调按钮或范围装饰器时
  • 当需要XAML或C#使用模式的示例时

Navigation Guide

导航指南

Getting Started

入门指南

📄 Read: references/getting-started.md
  • Installing and adding the control via XAML/C#; basic properties and value binding
📄 阅读: references/getting-started.md
  • 通过XAML/C#安装和添加控件;基础属性和值绑定

Overview

概述

📄 Read: references/overview.md
  • Short feature list and control summary
📄 阅读: references/overview.md
  • 简短功能列表和控件摘要

Appearance & Styling

外观与样式

📄 Read: references/appearance-and-styling.md
  • Foreground for positive/negative/zero, background, corner radius, selection brush
📄 阅读: references/appearance-and-styling.md
  • 正/负/零值前景色、背景色、圆角、选择画笔

Validation & Restrictions

验证与限制

📄 Read: references/restriction-or-validation.md
  • Min/Max validation modes, decimal digit limits, read-only mode
📄 阅读: references/restriction-or-validation.md
  • 最小/最大值验证模式、小数位数限制、只读模式

Step Interval & Scrolling

步长间隔与滚动

📄 Read: references/step-interval.md
  • ScrollInterval
    , mouse wheel, click-and-drag, selection-on-focus
📄 阅读: references/step-interval.md
  • ScrollInterval
    、鼠标滚轮、点击拖动、获焦时选中

Culture & Number Formatting

区域与数字格式

📄 Read: references/culture-and-number-formats.md
  • Culture
    ,
    NumberFormat
    , dedicated formatting properties
📄 阅读: references/culture-and-number-formats.md
  • Culture
    NumberFormat
    、专用格式属性

Range Adorner

范围装饰器

📄 Read: references/range-adorner.md
  • Visual range indicator based on
    MinValue
    /
    MaxValue
📄 阅读: references/range-adorner.md
  • 基于
    MinValue
    /
    MaxValue
    的可视化范围指示器

Changing Value & Advanced Behavior

值修改与高级行为

📄 Read: references/changing-double-value.md
  • Paste behavior, spin buttons, null value handling, watermarks
📄 阅读: references/changing-double-value.md
  • 粘贴行为、微调按钮、空值处理、水印

Quick Start (XAML)

快速入门(XAML)

xaml
<syncfusion:DoubleTextBox x:Name="doubleTextBox" Width="150" Height="25"
                          MinValue="0" MaxValue="100" Value="10"
                          ScrollInterval="1" />
xaml
<syncfusion:DoubleTextBox x:Name="doubleTextBox" Width="150" Height="25"
                          MinValue="0" MaxValue="100" Value="10"
                          ScrollInterval="1" />

Common Patterns

常见模式

  • Bind
    Value
    to a
    ViewModel
    property and use
    UpdateSourceTrigger=PropertyChanged
    for immediate updates.
  • Use
    MinValidation
    /
    MaxValidation
    to choose between strict-on-keypress and permissive-on-lost-focus behaviors.
  • For globalization, set
    Culture
    or
    NumberFormat
    and prefer
    NumberFormat
    when exact control is required.
  • Value
    绑定到
    ViewModel
    属性,并使用
    UpdateSourceTrigger=PropertyChanged
    实现即时更新。
  • 使用
    MinValidation
    /
    MaxValidation
    选择严格按键验证或失去焦点时验证的行为。
  • 对于全球化场景,设置
    Culture
    NumberFormat
    ,当需要精确控制时优先使用
    NumberFormat