Explorar el Código

Tweak GDScript and C# Style guides

Rename code structure -> formatting
Add a heading Encoding and special characters for the corresponding section
Add missing Indentation heading that was gone
Nathan Lovato hace 5 años
padre
commit
dcb9cb43e8

+ 6 - 4
getting_started/scripting/c_sharp/c_sharp_style_guide.rst

@@ -27,8 +27,11 @@ later.
 For detailed information on C# features in different versions, please see
 `What's New in C# <https://docs.microsoft.com/en-us/dotnet/csharp/whats-new/>`_.
 
-Formatting conventions
-----------------------
+Formatting
+----------
+
+General guidelines
+~~~~~~~~~~~~~~~~~~
 
 * Use line feed (**LF**) characters to break lines, not CRLF or CR.
 * Use one line feed character at the end of each file, except for `csproj` files.
@@ -36,8 +39,6 @@ Formatting conventions
 * Use **4 spaces** instead of tabs for indentation (which is referred to as "soft tabs").
 * Consider breaking a line into several if it's longer than 100 characters.
 
-Code structure
---------------
 
 Line breaks and blank lines
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -136,6 +137,7 @@ Avoid inserting a blank line:
         }
     }
 
+
 Using spaces
 ~~~~~~~~~~~~
 

+ 8 - 5
getting_started/scripting/gdscript/gdscript_styleguide.rst

@@ -18,18 +18,21 @@ styleguide.
 .. note:: Godot's built-in script editor uses a lot of these conventions
           by default. Let it help you.
 
-Formatting conventions
-----------------------
+Formatting
+----------
+
+Encoding and special characters
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 
 * Use line feed (**LF**) characters to break lines, not CRLF or CR. *(editor default)*
 * Use one line feed character at the end of each file. *(editor default)*
 * Use **UTF-8** encoding without a `byte order mark <https://en.wikipedia.org/wiki/Byte_order_mark>`_. *(editor default)*
 * Use **Tabs** instead of spaces for indentation. *(editor default)*
 
-Each indent level should be one greater than the block containing it.
+Indentation
+~~~~~~~~~~~
 
-Code structure
---------------
+Each indent level should be one greater than the block containing it.
 
 **Good**: