dotless_i 0.1.1

dotless_i #

Turkish String upper-lower case converter and comparator functions for Dart. This library is necessary because currently Dart only supports default unicode mappings for casing and default rules does not work for Turkish i->İ and I->i conversions.

Name of the library is "dotless i" because the notorious "ı" character (together with İ) caused countless trouble in computing for Turkish. Case methods can be used for some other Turkic alphabets as well (such as Azerbaijani). Current implementation does not handle two code unit variations yet. Complete special casing rules are defined here : (

Usage Example:

import 'package:dotless_i/dotless_i.dart';
var inputL = "kısa şiir"; 
print("UpperCase for [$inputL]");
print("Default= ${inputL.toUpperCase()}, Turkish=${toUpperCaseTr(inputL)}\n");

var inputU = "KISA ŞİİR";	 
print("LowerCase for [$inputU]");
print("Default= ${inputU.toLowerCase()}, Turkish=${toLowerCaseTr(inputU)}\n");  
var list = ["ağ","aç","ad"];
print("Input= $list");
print("Default Sort= ${list..sort()}");
list = ["ağ","aç","ad"];  
print("Turkish Sort= ${list..sort(TURKISH_STRING_COMPARATOR)}"); 

UpperCase for [kısa şiir]
Default= KISA ŞIIR, Turkish=KISA ŞİİR

LowerCase for [KISA ŞİİR]
Default= kisa şiir, Turkish=kısa şiir

Input= [ağ, aç, ad]
Default Sort= [ad, aç, ağ]
Turkish Sort= [aç, ad, ağ]

Change List #

0.1.1 Remove unnecessary checks that are already handled by default case conversion. Documentation changes after G+ discussion.
0.1.0 Initial Release.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  dotless_i: ^0.1.1

2. Install it

You can install packages from the command line:

with pub:

$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:dotless_i/dotless_i.dart';
Awaiting analysis to complete.