Răsfoiți Sursa

Merge pull request #185 from mbndr/master

Doc spelling fixes
Marco Bambini 8 ani în urmă
părinte
comite
6611e2b26d
8 a modificat fișierele cu 21 adăugiri și 21 ștergeri
  1. 2 2
      docs/api.html
  2. 3 3
      docs/classes.html
  3. 1 1
      docs/enum.html
  4. 4 4
      docs/lists.html
  5. 3 3
      docs/loops.html
  6. 3 3
      docs/syntax.html
  7. 1 1
      docs/system.html
  8. 4 4
      docs/types.html

+ 2 - 2
docs/api.html

@@ -79,7 +79,7 @@
          	<h1 class="section-header">API</h1><hr>
          	<h1 class="section-header">API</h1><hr>
          				
          				
 			<p class="section-content">
 			<p class="section-content">
-				Gravity can be extended at runtime using C API. The right step to proceed is usually to create a new class, then add methods and proporties to it and finally register that class inside the VM.
+				Gravity can be extended at runtime using C API. The right step to proceed is usually to create a new class, then add methods and properties to it and finally register that class inside the VM.
 			</p>
 			</p>
 			<pre><code class="cpp">
 			<pre><code class="cpp">
 	// report error callback function
 	// report error callback function
@@ -89,7 +89,7 @@
 		exit(0);
 		exit(0);
 	}
 	}
 	
 	
-	// function to be execute inside Gravity VM		
+	// function to be executed inside Gravity VM
 	bool my_function (gravity_vm *vm, gravity_value_t *args,
 	bool my_function (gravity_vm *vm, gravity_value_t *args,
 	                  uint16_t nargs, uint32_t rindex) {
 	                  uint16_t nargs, uint32_t rindex) {
 		// do something useful here
 		// do something useful here

+ 3 - 3
docs/classes.html

@@ -94,7 +94,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">Methods</h4>
 			<h4 class="section-h4">Methods</h4>
-			<p>Functions declared inside a class are called methods and are used to add behaviors to objects that belongs to a specific class:</p>
+			<p>Functions declared inside a class are called methods and are used to add behaviors to objects that belong to a specific class:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	class Italy {
 	class Italy {
 		func print() {
 		func print() {
@@ -104,7 +104,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">Properties</h4>
 			<h4 class="section-h4">Properties</h4>
-			<p>Variables declared inside a class are called properties and are used to add states to objects that belongs to a specific class:</p>
+			<p>Variables declared inside a class are called properties and are used to add states to objects that belong to a specific class:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	class Italy {
 	class Italy {
 		var population = 60656000;
 		var population = 60656000;
@@ -221,7 +221,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">Access specifiers</h4>
 			<h4 class="section-h4">Access specifiers</h4>
-			<p>The public and private keywords can be used to restrict access to specific part of code.</p>
+			<p>The public and private keywords can be used to restrict access to specific parts of code.</p>
 			
 			
          	</div>
          	</div>
        	</div> <!-- /row -->
        	</div> <!-- /row -->

+ 1 - 1
docs/enum.html

@@ -77,7 +77,7 @@
          	<h1 class="section-header">Enum</h1><hr>
          	<h1 class="section-header">Enum</h1><hr>
 			
 			
 			<p class="section-content">
 			<p class="section-content">
-			Enums defines a common type for a group of related values, if you are familiar with C, you will know that C enumerations assign related names to a set of integer values, enum in Gravity are much more flexible and enables you to assign even non integer values: 
+			Enums defines a common type for a group of related values. If you are familiar with C, you will know that C enumerations assign related names to a set of integer values. Enums in Gravity are much more flexible and enable you to assign even non integer values: 
 			</p>
 			</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	enum state {
 	enum state {

+ 4 - 4
docs/lists.html

@@ -77,7 +77,7 @@
          	<h1 class="section-header">List</h1><hr>
          	<h1 class="section-header">List</h1><hr>
 			
 			
 			<p class="section-content">
 			<p class="section-content">
-			Lists (or arrays) are simple sequence of objects, their size is dynamic and their index starts always from 0. They provide fast random access to their elements. You can create a list by placing a sequence of comma-separated expressions inside square brackets:
+			Lists (or arrays) are simple sequence of objects, their size is dynamic and their index starts always at 0. They provide fast random access to their elements. You can create a list by placing a sequence of comma-separated expressions inside square brackets:
 			</p>
 			</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var r = [1, 2, "Hello", 3.1415, true];
 	var r = [1, 2, "Hello", 3.1415, true];
@@ -87,7 +87,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">Accessing elements</h4>
 			<h4 class="section-h4">Accessing elements</h4>
-			<p>You can access an element from a list by calling the subscript operator [] on it with the index of the element you want. Like most languages, indices start at zero:
+			<p>You can access an element from a list by calling the subscript operator [] on it with the index of the element you want. Like most languages, indices start at 0:
 			</p>
 			</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var names = ["Mark", "Andrew", "Paul", "Ross", "Frank", "Max"];
 	var names = ["Mark", "Andrew", "Paul", "Ross", "Frank", "Max"];
@@ -95,7 +95,7 @@
 	names[2];	// "Paul"
 	names[2];	// "Paul"
 			</code></pre>
 			</code></pre>
 			
 			
-			<p>Negative indices counts backwards from the end:</p>
+			<p>Negative indices count backwards from the end:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var names = ["Mark", "Andrew", "Paul", "Ross", "Frank", "Max"];
 	var names = ["Mark", "Andrew", "Paul", "Ross", "Frank", "Max"];
 	names[-1];	// "Max"
 	names[-1];	// "Max"
@@ -128,7 +128,7 @@
 			</code></pre>
 			</code></pre>
 
 
 			<h4 class="section-h4">List Contains</h4>
 			<h4 class="section-h4">List Contains</h4>
-			<p>The List class implements the contains methods as a convenient way to check for the existance of a value in a list:</p>
+			<p>The List class implements the contains methods as a convenient way to check for the existence of a value in a list:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var list = [1, 2, "Hello", 3.1415, true];
 	var list = [1, 2, "Hello", 3.1415, true];
 	return list.contains(3.1415); // Returns: true
 	return list.contains(3.1415); // Returns: true

+ 3 - 3
docs/loops.html

@@ -79,7 +79,7 @@
 			<p class="section-content">
 			<p class="section-content">
 			
 			
 			<h4 class="section-h4">While loop</h4>
 			<h4 class="section-h4">While loop</h4>
-			<p>A while loop performs a set of statements until a condition becomes false. These kinds of loops are best used when the number of iterations is not known before the first iteration begins.</p>
+			<p>A while loop performs a set of statements until a condition becomes false. These kind of loops are best used when the number of iterations is not known before the first iteration begins.</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	func main() {
 	func main() {
 		var i = 0;
 		var i = 0;
@@ -108,7 +108,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">For loop</h4>
 			<h4 class="section-h4">For loop</h4>
-			<p>You can access an element from a list by calling the subscript operator [] on it with the index of the element you want. Like most languages, indices start at zero:</p>
+			<p>You can access an element from a list by calling the subscript operator [] on it with the index of the element you want. As in most languages, indices start at zero:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var count = 0;
 	var count = 0;
 	for (var i in 0...40) {
 	for (var i in 0...40) {
@@ -180,7 +180,7 @@
                 System.print(vowels)  // aeiou
                 System.print(vowels)  // aeiou
         }
         }
 			</code></pre>
 			</code></pre>
-			<p>Loop within a <a href="maps.html">Map</a> where key is passed as closure argument (please note that key order is not preserved):</p>
+			<p>Loop within a <a href="maps.html">Map</a> where the key is passed as closure argument (please note that key order is not preserved):</p>
          	<pre><code class="swift">
          	<pre><code class="swift">
 	func main() {
 	func main() {
 		var target = ["key1":10,"key2":20,"key3":30,"key4":40];
 		var target = ["key1":10,"key2":20,"key3":30,"key4":40];

+ 3 - 3
docs/syntax.html

@@ -125,8 +125,8 @@
 	*/</code></pre>
 	*/</code></pre>
 			<p>While Gravity uses C-Style comments, Gravity still supports the common
 			<p>While Gravity uses C-Style comments, Gravity still supports the common
 			"#!" shebang to tell your shell what program to execute the file with.
 			"#!" shebang to tell your shell what program to execute the file with.
-			The shebang must be on the first line of the file in order to use it in
-			this way however:</p>
+			However, the shebang must be on the first line of the file in order to use it in
+			this way:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	#!/path/to/gravity
 	#!/path/to/gravity
 
 
@@ -162,7 +162,7 @@
 			
 			
 			<!-- RESERVED KEYWORDS -->
 			<!-- RESERVED KEYWORDS -->
 			<h4 class="section-h4">Reserved Keywords</h4>
 			<h4 class="section-h4">Reserved Keywords</h4>
-			<p>Like many other programming languages Gravity has some reserved keywords that assumes a very specific meaning in the context of the source code:</p>
+			<p>Like many other programming languages Gravity has some reserved keywords that assume a very specific meaning in the context of the source code:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	if in or is for var and not func else true enum case null
 	if in or is for var and not func else true enum case null
 	file lazy super false break while class const event _func
 	file lazy super false break while class const event _func

+ 1 - 1
docs/system.html

@@ -92,7 +92,7 @@
 				</code></pre>
 				</code></pre>
 				
 				
 				<h4 class="section-h4">Garbage collector methods</h4>
 				<h4 class="section-h4">Garbage collector methods</h4>
-				<p>Gravity automatically manage memory for you using a tri-colour marking garbage collector, using the System class the user has the ability to change some of its settings and even disable it when certain performance critical tasks need to be performed:</p>
+				<p>Gravity automatically manages memory for you using a tri-colour marking garbage collector, using the System class the user has the ability to change some of its settings and even disable it when certain performance critical tasks need to be performed:</p>
 				<pre><code class="swift">
 				<pre><code class="swift">
 	func main() {
 	func main() {
 		// disable GC
 		// disable GC

+ 4 - 4
docs/types.html

@@ -84,7 +84,7 @@
 			<p>Object is the root class of every object inside Gravity. Through the Object class, objects inherit a basic interface to the runtime system and the ability to behave as Gravity objects.</p>
 			<p>Object is the root class of every object inside Gravity. Through the Object class, objects inherit a basic interface to the runtime system and the ability to behave as Gravity objects.</p>
 			
 			
 			<h4 class="section-h4">Int</h4>
 			<h4 class="section-h4">Int</h4>
-			<p>An Int represents a 64 bits (can optionally be compiled as 32bit) signed number:</p>
+			<p>An Int represents a 64 bit (can optionally be compiled as 32 bit) signed number:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var a = 123;		// decimal
 	var a = 123;		// decimal
 	var b = 0xFF;		// hexadecimal
 	var b = 0xFF;		// hexadecimal
@@ -98,7 +98,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">Float</h4>
 			<h4 class="section-h4">Float</h4>
-			<p>A float represents a 32 bits (or better) floating point number:</p>
+			<p>A float represents a 32 bit (or better) floating point number:</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var a = 3.1415;		// float
 	var a = 3.1415;		// float
 	var b = 1.25e2;		// scientific notation
 	var b = 1.25e2;		// scientific notation
@@ -108,7 +108,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">String</h4>
 			<h4 class="section-h4">String</h4>
-			<p>Strings are an immutable sequence of characters. String literals can be surrounded in double or single quotes.</p>
+			<p>Strings are an immutable sequence of characters. String literals can be surrounded with double or single quotes.</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var a = "Hello World";  // double quotes
 	var a = "Hello World";  // double quotes
 	var b = 'Hello World';  // single quotes
 	var b = 'Hello World';  // single quotes
@@ -152,7 +152,7 @@
 			</code></pre>
 			</code></pre>
 			
 			
 			<h4 class="section-h4">Bool</h4>
 			<h4 class="section-h4">Bool</h4>
-			<p>The bool data type can have only two values, they are the literals true and false. A Bool value expresses the validity of a condition (tells whether the condition is true or false).</p>
+			<p>The Bool data type can have only two values, they are the literals true and false. A Bool value expresses the validity of a condition (tells whether the condition is true or false).</p>
 			<pre><code class="swift">
 			<pre><code class="swift">
 	var a = true;
 	var a = true;
 	var b = false;
 	var b = false;