Skip to content

Instantly share code, notes, and snippets.

@barosl
barosl / add.c
Created July 26, 2015 07:26
Function overloading in C
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int addi(int a, int b) {
return a + b;
}
char *adds(char *a, char *b) {
char *res = malloc(strlen(a) + strlen(b) + 1);
@cuibonobo
cuibonobo / ScaleStrokePalette.js
Created August 19, 2013 22:10
Illustrator script that creates a palette with a slider that allows you to scale the stroke width of the selected object. Written by Carlos Canto and posted in the Illustrator scripting forums. What's remarkable about this file is the streamlining of the BridgeTalk call, which allows the palette to execute functions while staying open.
// script.name = scaleStrokes.jsx;
// script.description = scales selected objects strokes only;
// script.required = one or more selected objects
// script.parent = CarlosCanto // 5/7/12;
// script.elegant = false;
// script.updates = preview ON by default // 5/7/12
#target Illustrator
#targetengine 'main'
var unscale = 0;