JamSoft.AvaloniaUI.Lcd 1.2.1

dotnet add package JamSoft.AvaloniaUI.Lcd --version 1.2.1                
NuGet\Install-Package JamSoft.AvaloniaUI.Lcd -Version 1.2.1                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="JamSoft.AvaloniaUI.Lcd" Version="1.2.1" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add JamSoft.AvaloniaUI.Lcd --version 1.2.1                
#r "nuget: JamSoft.AvaloniaUI.Lcd, 1.2.1"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install JamSoft.AvaloniaUI.Lcd as a Cake Addin
#addin nuget:?package=JamSoft.AvaloniaUI.Lcd&version=1.2.1

// Install JamSoft.AvaloniaUI.Lcd as a Cake Tool
#tool nuget:?package=JamSoft.AvaloniaUI.Lcd&version=1.2.1                

Introduction

This is a control providing a form of digital LCD segment display for use within a .NET AvaloniaUI applications.

How To Use The Control

Installation

dotnet add package JamSoft.AvaloniaUI.Lcd --version 1.2.1
Install-Package JamSoft.AvaloniaUI.Lcd -Version 1.2.1
<PackageReference Include="JamSoft.AvaloniaUI.Lcd" Version="1.2.1" />
paket add JamSoft.AvaloniaUI.Lcd --version 1.2.1

Import Styles

<Application.Styles>
    <FluentTheme />
    <StyleInclude Source="avares://JamSoft.AvaloniaUI.Lcd/Themes/Default.axaml"/>
</Application.Styles>

The default style provided is very simple and be easily replaced.

<Style Selector="lcd|LcdLabel">
    <Setter Property="Template">
        <Setter.Value>
            <ControlTemplate TargetType="{x:Type lcd:LcdLabel}">
                <Border Background="{TemplateBinding Background}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}">
                </Border>
            </ControlTemplate>
        </Setter.Value>
    </Setter>
</Style>

Usage

<lcd:LcdLabel Text="Default" />

We're defining a basic default LCD label, nothing fancy.

Predefined Color Themes

<lcd:LcdLabel Text="Default Purple" 
              NumberOfCharactersPerLine="14" 
              ColorScheme="Green"/>

Here we define a few of the available properties, We're increasing the number of characters from 10 (the default) to 14 and we have also specified the Purple color scheme.

Multi Line

<lcd:LcdLabel Text="Multi-line" NumberOfTextLines="2" NumberOfCharactersPerLine="5" />

Here we have configured the LCD control to have two lines of text, each with 5 characters.

Alternate Sizes

<lcd:LcdLabel Text="{Binding Greeting}"
              DotMatrix="Dos5X7"
              NumberOfCharactersPerLine="24"
              LineSpacing="10"
              BorderSpace="10"
              PixelSize="Pix4X4" />

Here we have a large LCD display.

  • Text is data-bound to the view models Greeting property
  • DotMatrix is set to Dos5X7 (default Mat5X7)
  • NumberOfCharactersPerLine is set to 24 (default 10)
  • LineSpacing is set to 10 (default 2)
  • BorderSpace is set to 10 (default 3)
  • PixelSize is set to Pix4X4 (default Pix2X2)

Custom Pixel Size

<lcd:LcdLabel Text="Custom Pixels" NumberOfCharactersPerLine="13" PixelSize="PixCustom" PixelHeight="2" PixelWidth="8" />

Animations

You can animate the LCD contents by setting the IsAnimated property to True and using the animation properties to control various aspects of the animation behaviour.

<lcd:LcdLabel Text="{Binding Greeting}"
              NumberOfCharactersPerLine="24"
              ColorScheme="Green"
              IsAnimated="True"
              AnimationSpeed="10"
              AnimationStyle="Loop"/>

The AnimationSpeed property controls the speed in FPS. The value used here is divided by 1000. The AnimationStyle property controls the overall behaviour of the animation. The two options are Loop and Contiguous. Looped content will cycle to completion whereas Contiguous content cycles the string in a continuous stream of characters.

Properties

ColorScheme PixelSize DotMatrix PixelSpacing CharacterSpacing LineSpacing BorderSpace NumberOfTextLines NumberOfCharactersPerLine PixelOnColor PixelOffColor LcdBackgroundColor PixelWidth PixelHeight Text HalfIntensity IsAnimated AnimationStyle AnimationSpeed

ColorScheme Options

Default Red Green Blue Purple LightBlue Yellow

DotMatrix Options

Mat5X7 Mat5X8 Mat7X9 Mat9X12 Hitachi Hitachi2 Dos5X7

PixelSize Options

Pix1X1 Pix2X2 Pix3X3 Pix4X4 Pix5X5 Pix6X6 Pix7X7 Pix8X8 Pix9X9 Pix10X10 Pix11X11 Pix12X12 Pix13X13 Pix14X14 Pix15X15 Pix16X16 Custom

AnimationStyle Options

Loop Contiguous

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETStandard 2.0

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.2.1 147 6/8/2024
1.2.0 138 3/22/2024
1.1.0 252 2/18/2023
1.0.2 243 2/15/2023
1.0.1 247 2/13/2023
1.0.0 257 2/12/2023