SDL: Fix various typos (docs/build scripts/tests)

From 65e1d568efe6b4a3ce660956cf4e5cf9b7fe8c6f Mon Sep 17 00:00:00 2001
From: luzpaz <[EMAIL REDACTED]>
Date: Mon, 3 Jul 2023 15:29:42 +0000
Subject: [PATCH] Fix various typos (docs/build scripts/tests)

---
 build-scripts/SDL_migration.cocci     | 4 ++--
 build-scripts/rename_headers.py       | 2 +-
 build-scripts/rename_symbols.py       | 2 +-
 cmake/GetGitRevisionDescription.cmake | 2 +-
 docs/README-android.md                | 2 +-
 docs/README-ps2.md                    | 4 ++--
 test/testautomation_rect.c            | 6 +++---
 test/testautomation_surface.c         | 2 +-
 test/testautomation_video.c           | 2 +-
 test/testfile.c                       | 2 +-
 test/testhotplug.c                    | 2 +-
 test/testime.c                        | 4 ++--
 test/testplatform.c                   | 2 +-
 13 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/build-scripts/SDL_migration.cocci b/build-scripts/SDL_migration.cocci
index bb4fd6a3985d..441112b8e2db 100644
--- a/build-scripts/SDL_migration.cocci
+++ b/build-scripts/SDL_migration.cocci
@@ -14,7 +14,7 @@
 //
 // A few options:
 //   --c++=11            to parse cpp file
-//   --max-width 200     to increase line witdth of generated source
+//   --max-width 200     to increase line width of generated source
 //
 // Apply the patch to your project:
 //	patch -p1 <patch.txt
@@ -28,7 +28,7 @@
 // @@
 // rule / transformation
 //
-// So this file is a set of many semantic patches, mostly independant.
+// So this file is a set of many semantic patches, mostly independent.
 
 
 @ rule_audio_open @
diff --git a/build-scripts/rename_headers.py b/build-scripts/rename_headers.py
index def94fce8193..e09d8dade688 100755
--- a/build-scripts/rename_headers.py
+++ b/build-scripts/rename_headers.py
@@ -1,6 +1,6 @@
 #!/usr/bin/env python3
 #
-# This script renames SDL headers in the specfied paths
+# This script renames SDL headers in the specified paths
 
 import argparse
 import pathlib
diff --git a/build-scripts/rename_symbols.py b/build-scripts/rename_symbols.py
index ec6f705b9b1f..d6cf879e17f2 100755
--- a/build-scripts/rename_symbols.py
+++ b/build-scripts/rename_symbols.py
@@ -1,6 +1,6 @@
 #!/usr/bin/env python3
 #
-# This script renames symbols in the specfied paths
+# This script renames symbols in the specified paths
 
 import argparse
 import os
diff --git a/cmake/GetGitRevisionDescription.cmake b/cmake/GetGitRevisionDescription.cmake
index 4fbd90db7942..a08895c648d1 100644
--- a/cmake/GetGitRevisionDescription.cmake
+++ b/cmake/GetGitRevisionDescription.cmake
@@ -59,7 +59,7 @@ get_filename_component(_gitdescmoddir ${CMAKE_CURRENT_LIST_FILE} PATH)
 # function returns an empty string via _git_dir_var.
 #
 # Example: Given a path C:/bla/foo/bar and assuming C:/bla/.git exists and
-# neither foo nor bar contain a file/directory .git. This wil return
+# neither foo nor bar contain a file/directory .git. This will return
 # C:/bla/.git
 #
 function(_git_find_closest_git_dir _start_dir _git_dir_var)
diff --git a/docs/README-android.md b/docs/README-android.md
index 0c21ce8f14c9..6839e68e62e0 100644
--- a/docs/README-android.md
+++ b/docs/README-android.md
@@ -218,7 +218,7 @@ You should not use the SDL renderer API while the app going in background:
    GL context is restored, and the SDL renderer API is available (unless you
    receive SDL_EVENT_RENDER_DEVICE_RESET).
 
-Activity lifecyle
+Activity lifecycle
 ================================================================================
 
 You can control activity re-creation (eg. onCreate()) behaviour. This allows to keep
diff --git a/docs/README-ps2.md b/docs/README-ps2.md
index 6283b9f5f093..579ad9860209 100644
--- a/docs/README-ps2.md
+++ b/docs/README-ps2.md
@@ -18,10 +18,10 @@ cmake --install build
 
 ## Hints
 The PS2 port has a special Hint for having a dynamic VSYNC. The Hint is `SDL_HINT_PS2_DYNAMIC_VSYNC`.
-If you enabled the dynamic vsync having as well `SDL_RENDERER_PRESENTVSYNC` enabled, then if the app is not able to run at 60 FPS, automatically the `vsync` will be disabled having a better performance, instead of droping FPS to 30.
+If you enabled the dynamic vsync having as well `SDL_RENDERER_PRESENTVSYNC` enabled, then if the app is not able to run at 60 FPS, automatically the `vsync` will be disabled having a better performance, instead of dropping FPS to 30.
 
 ## Notes
-If you trying to debug a SDL app through [ps2client](https://github.com/ps2dev/ps2client) you need to avoid the IOP reset, otherwise you will lose the conection with your computer.
+If you trying to debug a SDL app through [ps2client](https://github.com/ps2dev/ps2client) you need to avoid the IOP reset, otherwise you will lose the connection with your computer.
 So to avoid the reset of the IOP CPU, you need to call to the macro `SDL_PS2_SKIP_IOP_RESET();`.
 It could be something similar as:
 ```c
diff --git a/test/testautomation_rect.c b/test/testautomation_rect.c
index ea4a2a526f9e..ba6ac4720687 100644
--- a/test/testautomation_rect.c
+++ b/test/testautomation_rect.c
@@ -697,9 +697,9 @@ static int rect_testIntersectRectParam(void *arg)
     intersection = SDL_GetRectIntersection((SDL_Rect *)NULL, &rectB, &result);
     SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 1st parameter is NULL");
     intersection = SDL_GetRectIntersection(&rectA, (SDL_Rect *)NULL, &result);
-    SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 2st parameter is NULL");
+    SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 2nd parameter is NULL");
     intersection = SDL_GetRectIntersection(&rectA, &rectB, (SDL_Rect *)NULL);
-    SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 3st parameter is NULL");
+    SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 3rd parameter is NULL");
     intersection = SDL_GetRectIntersection((SDL_Rect *)NULL, (SDL_Rect *)NULL, &result);
     SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 1st and 2nd parameters are NULL");
     intersection = SDL_GetRectIntersection((SDL_Rect *)NULL, &rectB, (SDL_Rect *)NULL);
@@ -945,7 +945,7 @@ static int rect_testHasIntersectionParam(void *arg)
     intersection = SDL_HasRectIntersection((SDL_Rect *)NULL, &rectB);
     SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 1st parameter is NULL");
     intersection = SDL_HasRectIntersection(&rectA, (SDL_Rect *)NULL);
-    SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 2st parameter is NULL");
+    SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when 2nd parameter is NULL");
     intersection = SDL_HasRectIntersection((SDL_Rect *)NULL, (SDL_Rect *)NULL);
     SDLTest_AssertCheck(intersection == SDL_FALSE, "Check that function returns SDL_FALSE when all parameters are NULL");
 
diff --git a/test/testautomation_surface.c b/test/testautomation_surface.c
index c2c4dd924d01..acde6396c561 100644
--- a/test/testautomation_surface.c
+++ b/test/testautomation_surface.c
@@ -3,7 +3,7 @@
  * Adapted/rewritten for test lib by Andreas Schiffler
  */
 
-/* Supress C4996 VS compiler warnings for unlink() */
+/* Suppress C4996 VS compiler warnings for unlink() */
 #if defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
 #define _CRT_SECURE_NO_DEPRECATE
 #endif
diff --git a/test/testautomation_video.c b/test/testautomation_video.c
index 8907893260e3..ff31e93dcf86 100644
--- a/test/testautomation_video.c
+++ b/test/testautomation_video.c
@@ -1625,7 +1625,7 @@ static int video_getSetWindowData(void *arg)
 /**
  * \brief Tests the functionality of the SDL_WINDOWPOS_CENTERED_DISPLAY along with SDL_WINDOW_FULLSCREEN.
  *
- * Espeically useful when run on a multi-monitor system with different DPI scales per monitor,
+ * Especially useful when run on a multi-monitor system with different DPI scales per monitor,
  * to test that the window size is maintained when moving between monitors.
  */
 static int video_setWindowCenteredOnDisplay(void *arg)
diff --git a/test/testfile.c b/test/testfile.c
index 3d255cca7bb9..99ef3a01f55d 100644
--- a/test/testfile.c
+++ b/test/testfile.c
@@ -10,7 +10,7 @@
   freely.
 */
 
-/* sanity tests on SDL_rwops.c (usefull for alternative implementations of stdio rwops) */
+/* sanity tests on SDL_rwops.c (useful for alternative implementations of stdio rwops) */
 
 /* quiet windows compiler warnings */
 #if defined(_MSC_VER) && !defined(_CRT_NONSTDC_NO_WARNINGS)
diff --git a/test/testhotplug.c b/test/testhotplug.c
index b98ff982785e..24ec6f481072 100644
--- a/test/testhotplug.c
+++ b/test/testhotplug.c
@@ -128,7 +128,7 @@ int main(int argc, char *argv[])
                     SDL_CloseJoystick(joystick);
                     joystick = NULL;
                 } else {
-                    SDL_Log("Unknown joystick diconnected\n");
+                    SDL_Log("Unknown joystick disconnected\n");
                 }
                 break;
             case SDL_EVENT_JOYSTICK_AXIS_MOTION:
diff --git a/test/testime.c b/test/testime.c
index b4f5abd78375..acd286eb8b0f 100644
--- a/test/testime.c
+++ b/test/testime.c
@@ -771,9 +771,9 @@ int main(int argc, char *argv[])
                     SDL_strlcat(text, event.text.text, sizeof(text));
                 }
 
-                SDL_Log("text inputed: %s\n", text);
+                SDL_Log("text inputted: %s\n", text);
 
-                /* After text inputed, we can clear up markedText because it */
+                /* After text inputted, we can clear up markedText because it */
                 /* is committed */
                 markedText[0] = 0;
                 Redraw();
diff --git a/test/testplatform.c b/test/testplatform.c
index 03691a0e8598..d310fca252d6 100644
--- a/test/testplatform.c
+++ b/test/testplatform.c
@@ -381,7 +381,7 @@ static int Test64Bit(SDL_bool verbose)
         }
     }
     if (verbose && (failed == 0)) {
-        SDL_Log("All 64bit instrinsic tests passed\n");
+        SDL_Log("All 64bit intrinsic tests passed\n");
     }
     return failed ? 1 : 0;
 }