In previous versions of this GameEngine, I referenced the constants DEFAULT_CANVAS_WIDTH and DEFAULT_CANVAS_HEIGHT directly from the class GameEngineConstants. This is a bad practice since I want to give the developers who use this framework the ability to define their own screen width and height for the games that they create.

To fix this problem I removed all direct references of the default screen width and height in the GameFramework (except in the default constructor) and I now have the two constructors below:

public GameEngine(IRender renderer)
This constructor uses the default screen width and height found in the class GameEngineConstants, which happen to be 800 by 600 respectively.

public GameEngine(IRender renderer, int userDefinedScreenWidth, int userDefinedScreenHeight)
This constructor uses the user defined screen width and height instead of the default ones provided in the class GameEngineConstants.

With these fixes, the game framework will only refer to what is defined by either constructor and all direct references to the default screen width and height (DEFAULT_SCREEN_WIDTH and DEFAULT_SCREEN_HEIGHT) are now gone.
Since I now allow the user to specify a defined screen width and height, I had to add a range check in the constructor (below). Now, if the user enters a zero or negative value for either the screen width or height, the game engine reverts to the default screen width and height defined in GameEngineConstants.

public GameEngine(IRender renderer, int userDefinedScreenWidth, int userDefinedScreenHeight)