1
0
Fork 0
mirror of https://github.com/Nioux/AideDeJeu.git synced 2025-10-29 22:45:44 +00:00

Capitalize

This commit is contained in:
Yan Maniez 2018-05-28 12:57:15 +02:00
parent d7e355aa76
commit f3c97521ab
2 changed files with 7 additions and 2 deletions

View file

@ -124,7 +124,7 @@ namespace AideDeJeuCmd
{
if (spell.NamePHB == null)
{
spell.NamePHB = line;
spell.NamePHB = Capitalize(line);
}
else if (spell.LevelType == null)
{
@ -187,6 +187,11 @@ namespace AideDeJeuCmd
Console.WriteLine("Hello World!");
}
public static string Capitalize(string text)
{
return string.Concat(text.Take(1)).ToUpper() + string.Concat(text.Skip(1)).ToString().ToLower();
}
public static string RemoveDiacritics(string text)
{
if (string.IsNullOrWhiteSpace(text))

File diff suppressed because one or more lines are too long