Skip to content

Commit 31bda96

Browse files
committed
Consistent encoding name...
1 parent dce957d commit 31bda96

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

FlashDevelop/Managers/ButtonManager.cs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -334,21 +334,21 @@ public static String GetActiveEncodingName()
334334
Boolean hasBOM = document.SciControl.SaveBOM;
335335
if (codepage == Encoding.UTF8.CodePage)
336336
{
337-
return GetLabelAsPlainText("Label.UTF8", hasBOM);
337+
return GetLabelAsPlainText("Label.UTF8", true, hasBOM);
338338
}
339339
else if (codepage == Encoding.UTF7.CodePage)
340340
{
341-
return GetLabelAsPlainText("Label.UTF7", hasBOM);
341+
return GetLabelAsPlainText("Label.UTF7", true, hasBOM);
342342
}
343343
else if (codepage == Encoding.BigEndianUnicode.CodePage)
344344
{
345-
return GetLabelAsPlainText("Label.BigEndian", hasBOM);
345+
return GetLabelAsPlainText("Label.BigEndian", true, hasBOM);
346346
}
347347
else if (codepage == Encoding.Unicode.CodePage)
348348
{
349-
return GetLabelAsPlainText("Label.LittleEndian", hasBOM);
349+
return GetLabelAsPlainText("Label.LittleEndian", true, hasBOM);
350350
}
351-
else return GetLabelAsPlainText("Label.8Bits", false);
351+
else return GetLabelAsPlainText("Label.8Bits", false, false);
352352
}
353353
}
354354
else return TextHelper.GetString("Info.Unknown");
@@ -357,9 +357,10 @@ public static String GetActiveEncodingName()
357357
/// <summary>
358358
/// Gets a label as plain text by removing the accelerator key
359359
/// </summary>
360-
public static String GetLabelAsPlainText(String name, Boolean hasBOM)
360+
public static String GetLabelAsPlainText(String name, Boolean unicode, Boolean hasBOM)
361361
{
362362
String label = TextHelper.GetString(name).Replace("&", "");
363+
if (unicode) label = "Unicode (" + label.ToLower() + ")";
363364
return hasBOM ? label + " (BOM)" : label;
364365
}
365366

0 commit comments

Comments
 (0)