Merge branch 'first-capital-letter-fix' of https://github.com/Tryibion/FlaxEngine into Tryibion-first-capital-letter-fix
This commit is contained in:
@@ -906,12 +906,21 @@ namespace FlaxEditor.Utilities
|
||||
if (name.StartsWith("g_") || name.StartsWith("m_"))
|
||||
startIndex = 2;
|
||||
|
||||
if (name.StartsWith("_"))
|
||||
startIndex = 1;
|
||||
|
||||
// Filter text
|
||||
var lastChar = '\0';
|
||||
for (int i = startIndex; i < length; i++)
|
||||
{
|
||||
var c = name[i];
|
||||
|
||||
if (i == startIndex)
|
||||
{
|
||||
sb.Append(char.ToUpper(c));
|
||||
continue;
|
||||
}
|
||||
|
||||
// Space before word starting with uppercase letter
|
||||
if (char.IsUpper(c) && i > 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user