Skip to content

Instantly share code, notes, and snippets.

@rmacqueen
rmacqueen / nama.rb
Created July 12, 2017 22:26
Solução para primeira avaliação
require 'test/unit'
def nama
num = 100
arr = []
(1..num).each { |i|
if i % 35 == 0
arr.push("Nama Team")
elsif i % 7 == 0
arr.push("Team")
@rmacqueen
rmacqueen / gist:6e4ed04ef5f4c3ccaf11f352cd7d28d3
Created March 14, 2017 20:34
emeus breaks when using wrap on gtk label
const Gtk = imports.gi.Gtk;
const Emeus = imports.gi.Emeus;
const Pango = imports.gi.Pango;
Gtk.init(null)
let layout1 = new Emeus.ConstraintLayout();
let layout2 = new Emeus.ConstraintLayout();
@rmacqueen
rmacqueen / EmeusWithGrid.txt
Last active March 19, 2017 16:25
Emeus with GtkGrid and nested layout
const Gtk = imports.gi.Gtk;
const Emeus = imports.gi.Emeus;
Gtk.init(null)
let layout1 = new Emeus.ConstraintLayout();
let layout2 = new Emeus.ConstraintLayout();
let grid = new Gtk.Grid();
const Gtk = imports.gi.Gtk;
const Emeus = imports.gi.Emeus;
Gtk.init(null)
let layout1 = new Emeus.ConstraintLayout();
let layout2 = new Emeus.ConstraintLayout();
layout1.add(layout2)
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <glib.h>
#include <stdint.h>
int
main (int argc, char *argv[])
{
unsigned int limit = g_ascii_strtod ("-1", NULL);
const GObject = imports.gi.GObject;
const Gtk = imports.gi.Gtk;
const Lang = imports.lang;
Gtk.init(null);
const FirstObject = new Lang.Class({
Name: 'First',
Extends: GObject.Object,
const GObject = imports.gi.GObject;
const Gtk = imports.gi.Gtk;
const Lang = imports.lang;
Gtk.init(null);
const SlidingPanelOverlay = new Lang.Class({
Name: 'SlidingPanelOverlay',
GTypeName: 'EknSlidingPanelOverlay',
const Gtk = imports.gi.Gtk;
Gtk.init(null);
let frame = new Gtk.Frame({
// expand: false,
margin: 30
});
frame.set_size_request(200, 100)
const Gtk = imports.gi.Gtk;
const Gdk = imports.gi.Gdk;
Gtk.init(null);
let overlay = new Gtk.Overlay()
let button = new Gtk.Button({
expand: true,
});
const Gtk = imports.gi.Gtk;
Gtk.init(null);
let frame = new Gtk.Frame({
expand: false,
margin: 30
});
frame.set_size_request(200, 100)