View how-to-draw-circle-oval-with-haxe-javascript.md

How to draw a circle or oval with Haxe/JavaScript

public static function oval(g:Graphics, w:Float, h:Float, cx:Float = 0, cy:Float = 0):Graphics {
	var lx = cx - w * .5;
	var rx = cx + w * .5;
	var ty = cy - h * .5;
	var by = cy + h * .5;

	var magic = 0.551915024494; 
View combinators.hx
static final I = x -> x;
static final K = x -> y -> x;
static final A = f -> x -> f(x);
static final T = x -> f -> f(x);
static final W = f -> x -> f(x)(x);
static final C = f -> y -> x -> f(x)(y);
static final B = f -> g -> x -> f(g(x));
static final S = f -> g -> x -> f(x)(g(x));
static final P = f -> g -> x -> y -> f(g(x))(g(y));
View commands.md

Update Haxe Manual submodule

cd manual && git checkout master && git pull && cd .. && git commit -am "update manual"

Put from staging to master

git checkout master && git pull && git pull origin staging --rebase && git push && git checkout staging
View empty-haxe-project-size.md

Size of empty Haxe/JavaScript project

openfl kha heaps pixi.js
normal 1027kb 358kb 1460kb 1250kb
closure 533kb 181kb 829kb 415kb

Used compiler: Haxe 3.4.2


View Main.hx
package game;
import h2d.Bitmap;
import h2d.Sprite;
import hxd.Res;
import nape.geom.Vec2;
import nape.phys.Body;
import nape.phys.BodyType;
import nape.shape.Polygon;
import nape.space.Space;
View CSVReader.hx
using StringTools;
class CSVReader
{
private static var format:CSVFormat = { del: ",", quote: '"', escape: '""', linedel: "\r\n" };
private var csv:String;
public function new(csv:String)
{
this.csv = csv;
View IsMobile.hx
/**
* Type definitions for <https://github.com/kaimallea/isMobile>
* Don't forget to add the actual script in the head of the html.
*
* @author Mark Knol
*/
@:native("isMobile")
extern class IsMobile
{
public static var apple(default,null):{phone:Bool, ipod:Bool, tablet:Bool, device:Bool};
View haxe.json
{
/*
// Place your snippets for Haxe here. Each snippet is defined under a snippet name and has a prefix, body and
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are:
// \t, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the
// same ids are connected.
// Example:
"Print to console": {
"prefix": "log",
"body": [
View toolbar.xml
<button label="Git Sync" click="RunProcess" tag="$(Quote)C:\Program Files\TortoiseGit\bin\TortoiseGitProc.exe$(Quote);-command sync -path $(Quote)$(ProjectDir)$(Quote)" image="59" />
<button label="Git Pull" click="RunProcess" tag="$(Quote)C:\Program Files\TortoiseGit\bin\TortoiseGitProc.exe$(Quote);-command pull -path $(Quote)$(ProjectDir)$(Quote)" image="71" />
<button label="Git Push" click="RunProcess" tag="$(Quote)C:\Program Files\TortoiseGit\bin\TortoiseGitProc.exe$(Quote);-command push -path $(Quote)$(ProjectDir)$(Quote)" image="72" />
<button label="Git Commit" click="RunProcess" tag="$(Quote)C:\Program Files\TortoiseGit\bin\TortoiseGitProc.exe$(Quote);-command commit -path $(Quote)$(ProjectDir)$(Quote)" image="258" />
<button label="Git Commit (current file only)" click="RunProcess" tag="$(Quote)C:\Program Files\TortoiseGit\bin\TortoiseGitProc.exe$(Quote);-command commit -logmsg $(Quote)$(TypName)$(Quote) -path $(Quote)$(CurFile)$(Quote)" image="80" />
<button label="Git Switch" click="RunProc