Replace XML codeblock spaces with tabs

This commit is contained in:
kobewi
2025-05-17 20:00:17 +02:00
committed by Rémi Verschelde
parent 5dd76968d8
commit 13f642d959
122 changed files with 2407 additions and 2432 deletions

View File

@ -196,29 +196,29 @@
[gdscript]
var arguments = {}
for argument in OS.get_cmdline_args():
if argument.contains("="):
var key_value = argument.split("=")
arguments[key_value[0].trim_prefix("--")] = key_value[1]
else:
# Options without an argument will be present in the dictionary,
# with the value set to an empty string.
arguments[argument.trim_prefix("--")] = ""
if argument.contains("="):
var key_value = argument.split("=")
arguments[key_value[0].trim_prefix("--")] = key_value[1]
else:
# Options without an argument will be present in the dictionary,
# with the value set to an empty string.
arguments[argument.trim_prefix("--")] = ""
[/gdscript]
[csharp]
var arguments = new Dictionary<string, string>();
foreach (var argument in OS.GetCmdlineArgs())
{
if (argument.Contains('='))
{
string[] keyValue = argument.Split("=");
arguments[keyValue[0].TrimPrefix("--")] = keyValue[1];
}
else
{
// Options without an argument will be present in the dictionary,
// with the value set to an empty string.
arguments[argument.TrimPrefix("--")] = "";
}
if (argument.Contains('='))
{
string[] keyValue = argument.Split("=");
arguments[keyValue[0].TrimPrefix("--")] = keyValue[1];
}
else
{
// Options without an argument will be present in the dictionary,
// with the value set to an empty string.
arguments[argument.TrimPrefix("--")] = "";
}
}
[/csharp]
[/codeblocks]
@ -383,44 +383,44 @@
[codeblocks]
[gdscript]
match OS.get_name():
"Windows":
print("Welcome to Windows!")
"macOS":
print("Welcome to macOS!")
"Linux", "FreeBSD", "NetBSD", "OpenBSD", "BSD":
print("Welcome to Linux/BSD!")
"Android":
print("Welcome to Android!")
"iOS":
print("Welcome to iOS!")
"Web":
print("Welcome to the Web!")
"Windows":
print("Welcome to Windows!")
"macOS":
print("Welcome to macOS!")
"Linux", "FreeBSD", "NetBSD", "OpenBSD", "BSD":
print("Welcome to Linux/BSD!")
"Android":
print("Welcome to Android!")
"iOS":
print("Welcome to iOS!")
"Web":
print("Welcome to the Web!")
[/gdscript]
[csharp]
switch (OS.GetName())
{
case "Windows":
GD.Print("Welcome to Windows");
break;
case "macOS":
GD.Print("Welcome to macOS!");
break;
case "Linux":
case "FreeBSD":
case "NetBSD":
case "OpenBSD":
case "BSD":
GD.Print("Welcome to Linux/BSD!");
break;
case "Android":
GD.Print("Welcome to Android!");
break;
case "iOS":
GD.Print("Welcome to iOS!");
break;
case "Web":
GD.Print("Welcome to the Web!");
break;
case "Windows":
GD.Print("Welcome to Windows");
break;
case "macOS":
GD.Print("Welcome to macOS!");
break;
case "Linux":
case "FreeBSD":
case "NetBSD":
case "OpenBSD":
case "BSD":
GD.Print("Welcome to Linux/BSD!");
break;
case "Android":
GD.Print("Welcome to Android!");
break;
case "iOS":
GD.Print("Welcome to iOS!");
break;
case "Web":
GD.Print("Welcome to the Web!");
break;
}
[/csharp]
[/codeblocks]