Skip to content

NumberBox has a precision floating point bug #3959

@crutkas

Description

@crutkas

Describe the bug

Steps to reproduce the bug

Steps to reproduce the behavior:
Use the following code:
<muxc:NumberBox Margin="0, 10, 0, 0" Header="Search weight:" Value="1" SpinButtonPlacementMode="Compact" SmallChange=".01" LargeChange=".1" Minimum="0" Maximum="5" />

Then do a small or large change,

Expected behavior

Get proper precision, to small / large snap. Seems like a floating point precision error

Screenshots

image

Version Info
UWP 6.2.10

NuGet package version:
Microsoft.UI.Xaml 2.5.0

Windows app type:

UWP Win32
Yes
Windows 10 version Saw the problem?
Insider Build (xxxxx)
May 2020 Update (19041)
November 2019 Update (18363)
May 2019 Update (18362)
October 2018 Update (17763)
April 2018 Update (17134)
Fall Creators Update (16299)
Creators Update (15063)
Device form factor Saw the problem?
Desktop Yes
Xbox
Surface Hub
IoT

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions