GithubHelp home page GithubHelp logo

p1exu5 / p1exu5.wpf.digitpanel Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 1.0 29 KB

Digit panel WPF custom control library

License: MIT License

C# 100.00%
library wfp custom-control-library digit-panel

p1exu5.wpf.digitpanel's Introduction

p1eXu5.Wpf.DigitPanel

Package Versions
p1eXu5.Wpf.DigitPanel NuGet

digit-panel

Usage:

<Application x:Class="YourApp"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:digitPanel="clr-namespace:p1eXu5.Wpf.DigitPanel;assembly=p1eXu5.Wpf.DigitPanel"
             StartupUri="MainWindow.xaml">
    <Application.Resources>
        <ResourceDictionary>
            <ResourceDictionary.MergedDictionaries>
                <digitPanel:DigitPanelTheme />
            </ResourceDictionary.MergedDictionaries>
        </ResourceDictionary>
    </Application.Resources>
</Application>
<Window ...
             xmlns:digitPanel="clr-namespace:p1eXu5.Wpf.DigitPanel;assembly=p1eXu5.Wpf.DigitPanel"
             ...
             Background="{DynamicResource {x:Static digitPanel:DigitPanelColors.DigitPanelBackgroundKey}}"
             >
             
  <digitPanel:Digit DockPanel.Dock="Left" Foreground="#FF0000" Background="#BBBBBB" IsDotOn="True" DotVisibility="Collapsed" Width="160" Mask="0"/>

  <digitPanel:DigitTable Grid.Column="0" 
                         DigitWidth="140"
                         Value="0"
                         Height="500" 
                         Width="800"
                         Format="##0.00"
                         />

  <digitPanel:TimerTable Grid.Column="0" 
                         DigitWidth="45"
                         Value="12:12:12"
                         Height="100" 
                         Width="300"/>

Digit Properties

Property Type Description
Mask string Determines which digit segments are lit. "0" - all digits are off, "1" - all digits are on. "0100101" - top-left, top-middle, top-right, middle, bottom-left, bottom-middle, bottom-right.
ActiveRadius double Booster-light. Active digit segment shaddow radius.
InactiveRadius double Booster-light. Inactive digit segment shaddow radius.
IsDotOn bool If true then dot is lit.
DotVisibility Visibility Dot visibility property.
IsColonOn bool If true then colon is lit.
ColonVisibility Visibility Colon visibility property.

DigitTableBase Properties

Property Type Description
Foreground Brush Active digit segments color.
DigitBackground Brush Inactive digit segments color.
Background Brush Digit table background.
DigitWidth double Size of digit.

DigitTable Properties (inherit DigitTableBase properties)

Property Type Description
Value double? Value showing on digit table.
Format string Value format. For example: "##0.00"

TimerTable Properties (inherit DigitTableBase properties)

Property Type Description
Value TimeSpan Value showing on digit table.

p1exu5.wpf.digitpanel's People

Contributors

p1exu5 avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.