Skip to content

Instantly share code, notes, and snippets.

View gjroelofs's full-sized avatar

Gijs-Jan Roelofs gjroelofs

View GitHub Profile
public class MyGdxGame extends ApplicationAdapter {
public PerspectiveCamera cam;
public ModelBatch modelBatch;
public Model model;
public ModelInstance instance;
@Override
public void create() {
modelBatch = new ModelBatch();
@gjroelofs
gjroelofs / UnityErrors.cs
Created January 16, 2016 14:53
Internal Compiler Errors in Unity
public static class ExtensionTests {
public static void Test(this object target, float a, float b = 1, float c = 2, float d = 3) { }
}
object target = null;
// Compiles
target.Test(0);
public class FooAttribute : Attribute {}
public class Target {
[Foo]
public void Interesting(){}
public void NotInteresting(){}
}
/* Hide description badge */
.badge.is-icon-only {
display: none;
}
/* Make ID smaller */
.card-short-id.hide, .card-short-id {
display: inline-block !important;
font-size: 10px;
font-weight: bold;
"Its not the bananas. I'm a bad conductor."
/*************** Hierarchical Sections *******************/
var folders = {
// "<name>" : JQueryObject (section)
};
var childMapping = {
// "PX-2": [
// "Sprint Planning"
// ],
.card_view--root--1ItV2NTu {
transition: background-color 0.15s ease-in-out, color 0.15s ease-in-out;
position: relative;
box-sizing: border-box;
width: 100%;
background: white;
cursor: default;
padding: 5px;
}
@gjroelofs
gjroelofs / JS TOC - Coda
Last active October 14, 2019 10:49
Javascript injection hack to create a TOC for Coda, also see: https://gist.github.com/gjroelofs/8cd6d0908ac72783ec97bbf7e0c91ef0 for CSS
/** Table of Contents **/
var AUTOGENERATED_TABLE_OF_CONTENTS = true;
var TOC_ID_PREFIX = "auto_toc_";
var canvasSection = ".document--root--MUOgORi0";
var codeH1 = ".kr-h1";
var codeH2 = ".kr-h2";
var codeH3 = ".kr-h3";
@gjroelofs
gjroelofs / CSS TOC - Coda
Created October 12, 2019 14:07
CSS for automatic TOC creation for Coda
/** Table of Contents. **/
#toc {
position: fixed;
display: table;
padding: 10px;
border: 1px solid #a2a9b1;
background-color: white;
padding: 5px;
font-size: 95%;
/* Ensure that cards without images don't reserve space for them. */
.card_view--root--1ItV2NTu .card_view--mediaTop--3m6a0XK2 {
box-sizing: border-box;
height: 100%;
margin-left: auto;
margin-right: auto;
padding: 0px;
}