Mark Sibly 7 years ago
parent
commit
41e76e40ac

+ 6 - 6
modules/mojo/app/app.monkey2

@@ -83,17 +83,17 @@ Class AppInstance
 	
 	The following environment variables can be set prior to constructing a new AppInstance:
 	
-	MOJO_OPENGL_PROFILE : Should be set to one of "es", "compatibility" or "core". Defaults to "compatibility" on macos and linux, "es" on all other targets. Uses 'Angle' for es support on windows.
+	MOJO\_OPENGL\_PROFILE : Should be set to one of "es", "compatibility" or "core". Defaults to "compatibility" on macos and linux, "es" on all other targets. Uses 'Angle' for es support on windows.
 
-	MOJO_OPENGL_VERSION_MAJOR : defaults to "2".
+	MOJO\_OPENGL\_VERSION\_MAJOR : defaults to "2".
 
-	MOJO_OPENGL_VERSION_MINOR : defaults to "1".
+	MOJO\_OPENGL\_VERSION\_MINOR : defaults to "1".
 
-	MOJO_COLOR_BUFFER_BITS : Minimum depth buffer bit depth. defaults to "8".
+	MOJO\_COLOR\_BUFFER\_BITS : Minimum depth buffer bit depth. defaults to "8".
 	
-	MOJO_DEPTH_BUFFER_BITS : Minimum depth buffer bit depth. defaults to "0".
+	MOJO\_DEPTH\_BUFFER\_BITS : Minimum depth buffer bit depth. defaults to "0".
 
-	MOJO_STENCIL_BUFFER_BITS : Minimum stencil buffer bit depth. defaults to "0".
+	MOJO\_STENCIL\_BUFFER\_BITS : Minimum stencil buffer bit depth. defaults to "0".
 	
 	Environment variables may be set using the [[std::std.filesystem.SetEnv|SetEnv]] function.
 	

+ 1 - 1
modules/mojo/graphics/texture.monkey2

@@ -106,7 +106,7 @@ Class Texture Extends Resource
 	
 	#rem monkeydoc Creates a new texture.
 	
-	The config setting "MOJO_TEXTURE_MAX_ANISOTROPY" can be used to set the new texture's max anisotropy value.
+	The config setting "MOJO\_TEXTURE\_MAX\_ANISOTROPY" can be used to set the new texture's max anisotropy value.
 
 	If this config setting does not exist, the texture's max anisotropy is set to the max level.
 		

+ 1 - 1
modules/mojo3d/render/forwardrenderer.monkey2

@@ -21,7 +21,7 @@ Class ForwardRenderer Extends Renderer
 
 	#rem monkeydoc Creates a forward renderer.
 	
-	If the config setting "MOJO3D_FORWARD_RENDERER_DIRECT" is set to "1", the renderer will render directly to the render target when [[Render]] is invoked.
+	If the config setting "MOJO3D\_FORWARD\_RENDERER\_DIRECT" is set to "1", the renderer will render directly to the render target when [[Render]] is invoked.
 
 	Config settings may be set using the [[std::std.filesystem.SetConfig|SetConfig]] function.
 

+ 1 - 1
modules/mojo3d/render/renderer.monkey2

@@ -63,7 +63,7 @@ Class Renderer
 	
 	#rem monkeydoc Gets the current renderer.
 	
-	The config setting "MOJO3D_DEFAULT_RENDERER" can be used to override the default renderer created. It should be set to "deferred" or "forward".
+	The config setting "MOJO3D\_DEFAULT\_RENDERER" can be used to override the default renderer created. It should be set to "deferred" or "forward".
 
 	Config settings may be changed using the [[std::std.filesystem.SetConfig|SetConfig]] function.
 	

+ 11 - 11
modules/std/filesystem/filesystem.monkey2

@@ -191,17 +191,17 @@ End
 
 Currently known built-in config settings:
 
-| Name								| More information
-|:----------------------------------|:----------------
-| "MOJO_OPENGL_PROFILE"				| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
-| "MOJO_OPENGL_VERSION_MAJOR"		| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
-| "MOJO_OPENGL_VERSION_MINOR"		| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
-| "MOJO_COLOR_BUFFER_BITS"			| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
-| "MOJO_DEPTH_BUFFER_BITS"			| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
-| "MOJO_STENCIL_BUFFER_BITS"		| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
-| "MOJO_TEXTURE_MAX_ANISOTROPY"		| [[mojo:mojo.graphics.Texture.New|Texture.New]]
-| "MOJO3D_DEFAULT_RENDERER"			| [[mojo3d:mojo3d.Renderer.GetCurrent|Renderer.GetCurrent]]
-| "MOJO3D_FORWARD_RENDERER_DIRECT"	| [[mojo3d:mojo3d.ForwardRenderer.New|ForwardRenderer.New]]
+| Name									| More information
+|:--------------------------------------|:----------------
+| "MOJO\_OPENGL\_PROFILE"				| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
+| "MOJO\_OPENGL\_VERSION\_MAJOR"		| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
+| "MOJO\_OPENGL\_VERSION\_MINOR"		| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
+| "MOJO\_COLOR\_BUFFER\_BITS"			| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
+| "MOJO\_DEPTH\_BUFFER\_BITS"			| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
+| "MOJO\_STENCIL\_BUFFER\_BITS"			| [[mojo:mojo.app.AppInstance.New|AppInstance.New]]
+| "MOJO\_TEXTURE\_MAX\_ANISOTROPY"		| [[mojo:mojo.graphics.Texture.New|Texture.New]]
+| "MOJO3D\_DEFAULT\_RENDERER"			| [[mojo3d:mojo3d.Renderer.GetCurrent|Renderer.GetCurrent]]
+| "MOJO3D\_FORWARD\_RENDERER\_DIRECT"	| [[mojo3d:mojo3d.ForwardRenderer.New|ForwardRenderer.New]]
 
 See also: [[GetConfig]].
 

+ 4 - 0
modules/std/stream/filestream.monkey2

@@ -87,6 +87,10 @@ Class FileStream Extends Stream
 	End
 	
 	#rem monkeydoc Opens a file and returns a new filestream.
+
+	When opening a file using "r" or "rw", the file must already exist or the function will fail and null will be returned.
+	
+	When opening a file using "w", any existing file at the same path will be overwritten.
 	
 	Note: This method should not be used to open an 'asset stream' because assets are not always files. You should instead use 
 	[[Stream.Open]] for streams that have a stream path prefix such as `asset::`, `internal::`, `external::` etc.

+ 16 - 0
modules/std/stream/stream.monkey2

@@ -537,6 +537,22 @@ Class Stream Extends std.resource.Resource
 	
 	`mode` should be "r" for read, "w" for write or "rw" for read/write.
 	
+	If the stream could not be opened, null will be returned.
+	
+	When opening a file using "r" or "rw", the file must already exist or the function will fail and null will be returned.
+	
+	When opening a file using "w", any existing file at the same path will be overwritten.
+	
+	Stream paths may include the following prefixes:
+	
+	| Stream path prefix	| Supported targets | Description
+	|:----------------------|:------------------|:-----------
+	| `asset::`				| All				| Open a stream for reading an app asset.
+	| `internal::`			| Mobile			| Open a stream for reading/writing internal app storage.
+	| `external::`			| Android			| Open a stream for reading/writing external app storage.
+	| `home::`				| Desktop 			| Open a stream for reading/writing a file in the user's home directory.
+	| `desktop::`			| Desktop 			| Open a stream for reading/writing a file in the user's desktop directory.
+	
 	@param mode The mode to open the stream in: "r", "w" or "rw"
 	
 	#end