Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/jon2g/maui-justifylabel


https://github.com/jon2g/maui-justifylabel

Last synced: about 2 months ago
JSON representation

Awesome Lists containing this project

README

        

# MAUI-JustifyLabel

Justify label for MAUI

Provides the ability to justify the text in a Label via attached property or by using a custom control.

[![NuGet version (MAUI-JustifyLabel)](https://img.shields.io/nuget/v/JustifyLabel-MAUI.svg)](https://www.nuget.org/packages/JustifyLabel-MAUI/)

### Windows
![Sample](https://raw.githubusercontent.com/Jon2G/MAUI-JustifyLabel/main/screenshots/windows.PNG)

### Android
![Sample](https://raw.githubusercontent.com/Jon2G/MAUI-JustifyLabel/main/screenshots/android_1.PNG)
![Sample](https://raw.githubusercontent.com/Jon2G/MAUI-JustifyLabel/main/screenshots/android_2.PNG)

### iOS
![Sample](https://raw.githubusercontent.com/Jon2G/MAUI-JustifyLabel/main/screenshots/ios.jpeg)

### MacCatalysis
![Sample](https://raw.githubusercontent.com/Jon2G/MAUI-JustifyLabel/main/screenshots/mac.png)

### Usage:
### Attached property
```
xmlns:justifiedLabel="clr-namespace:JustifyLabel;assembly=JustifyLabel"
```

```

```

### Custom control

On MauiProgram.cs
```
var builder = MauiApp.CreateBuilder();
builder
.UseMauiApp()
.UseJustifiedLabel() //Add this line
.ConfigureFonts(fonts =>
{
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
});
```

```
xmlns:justifiedLabel="clr-namespace:JustifyLabel;assembly=JustifyLabel"
```

```

```