Skip to content

Instantly share code, notes, and snippets.

View gist:aa57fd95f738b78ecf6e
### Keybase proof
I hereby claim:
* I am mverzilli on github.
* I am mverzilli (https://keybase.io/mverzilli) on keybase.
* I have a public key whose fingerprint is 1A62 F4E8 C9E1 3F5E 913E 60A4 029B 117E D8E9 4948
To claim this, I am signing this object:
View LayoutUtils.java
package simurrythmia.ui.util;
import java.awt.GridBagConstraints;
import java.awt.GridBagLayout;
import java.awt.Insets;
import javax.swing.BorderFactory;
import javax.swing.JComponent;
import javax.swing.JPanel;
View Nautic.elm
import Html (..)
import Html.Attributes (..)
import Html.Events (..)
import Signal
import Graphics.Collage (collage, filled, rect, toForm, move, rotate)
import Graphics.Element (Element, image)
import Window
import Color (..)
import Keyboard (arrows)
import Text (asText)
@mverzilli
mverzilli / pi.elm
Created Feb 28, 2015
Estimando PI con Montecarlo y Elm
View pi.elm
import List (..)
import Random (pair, float, generate, Seed, initialSeed)
import Signal
import Time (every, millisecond, Time)
import Graphics.Collage (collage, Form, filled, circle, move, toForm)
import Graphics.Element (Element)
import Color (..)
import Window (dimensions)
import Text
import String
View csd_operating_hours.txt
## Facility Operating hours
CSDOperatingHours => XXX (*)
CSDChildOf => CSDFacility (*)
## Open flag (Yes/No field)
CSDOpenFlag => ''
## Day of the week (Integer, Sunday=0, Monday=1, ...)
CSDDayOfTheWeek => ''
View csd_contact_points.txt
## Contact points
CSDType => "contactPoint" (*)
CSDCode => XXX (*)
## For each contact point text field (see page 95)
CSDContactData => YYY (one of: "equipment", "purpose", "certificate")
View csd_contact.txt
## Contacts
CSDType => contact (*)
CSDCode => XXX (*)
## Names
CSDName => YYY (*)
CSDChildOf => CSDContact (*)
## Forename
CSDForename => ''
@mverzilli
mverzilli / csd_addresses.txt
Created Oct 2, 2014
How to map a subset of fields in a RM collection to a CSD Facility Address
View csd_addresses.txt
## Addresses
For each address line, a Text Field with this metadata
CSDAddress => ''
CSDChildOf => CSDFacility
CSDCode => XXX (For example, "Legal", see page 89)
CSDComponent => YYY (One of: "StreetAddress", "City", "Province", "Country", "PostCode", see page 89)
@mverzilli
mverzilli / csd_org.txt
Last active Aug 29, 2015
Mapping a CSD organization
View csd_org.txt
La metadata que tiene (*) Tiene que repetirse en todos los campos de ahí para abajo en la jerarquía del modelo.
Los entries con value='' admiten cualquier valor, no hace falta que sean empty.
## Organization
CSDOrganization => XXX (*)
## OID (Text)
CSDAttributeFor => CSDOrganization
CSDAttribute => oid
View hello_world_sdl2.cr
#Instead of this:
require "sdl2/sdl2"
SCREEN_WIDTH = 1280
SCREEN_HEIGHT = 720
SDL2.init
window = SDL2.create_window("SDL Tutorial", LibSDL2::WINDOWPOS_UNDEFINED, LibSDL2::WINDOWPOS_UNDEFINED, SCREEN_WIDTH, SCREEN_HEIGHT, LibSDL2::WINDOW_SHOWN)