Skip to content

Instantly share code, notes, and snippets.

Hi August
#include <stdio.h>
#include <stdlib.h>
main()
{
int *foo;
foo = (int *)malloc(sizeof(int)*4);
foo[0] = 27;
int *bar = foo + 1;
*bar = 59;
printf("%d\n", foo[0]);
HAI
CAN HAS STDIO?
I HAS A VAR
IM IN YR LOOP
UP VAR!!1
VISIBLE VAR
IZ VAR BIGGER THAN 10? KTHXBYE
IM OUTTA YR LOOP
KTHXBYE
SBWidgetTag
WidgetDisplayName
WidgetDisplayName
WidgetDisplayName
DELETE_WIDGET_TITLE
DELETE_WIDGET_BODY
DELETE_WIDGET_CONFIRM
DELETE_WIDGET_CANCEL
isWidgetApplication
SBWidgetTag
widgetRoles
WidgetDisplayName
SBWidgetApplicationIcon
DELETE_WIDGET_TITLE
DELETE_WIDGET_BODY
DELETE_WIDGET_CONFIRM
DELETE_WIDGET_CANCEL
REMOTE REQUESTS:
com.sadun.airflick
RequestType := show-photo | play-media | screenshot
MediaLocation :=
<url string> | <local file path string> | <array of local file path strings for slideshow>
Rotation := 0 | 1 | 2 | 3 (0 ^, 1 <, 2 v, 3 >)
Transition := SlideRight | Dissolve
SlideDuration := 2 | 3 | 5 | 8 | 10 (Use strings. Incorrect durations default to 5)
// Single Slide
@erica
erica / gist:1130696
Created August 7, 2011 19:39
GrabUpper basics
I wrote GrabUpper many moons ago as a favor for a friend when GrabUp died. GrabUpper lets you automatically upload screenshots to Dropbox or TwitPic.
ADDING CREDENTIALS
Open the settings drawer (lower-right button). Enter your TwitPic (Twitter) credentials and/or add your Dropbox User ID. To retrieve this, visit Dropbox.com and right-click any item in your Public folder. Choose Copy Public Link. Your user id is between "/u/" and the file name, e.g.
http://dl.dropbox.com/u/THIS-IS-YOUR-ID/jobs-unicorn1.jpg
USING GRABUPPER
ScreenShots: Choose where you want screenshots sent to. With the screen shot service running (butterfly button), take a screenshot. If you select DropBox as the destination, it must be running on your computer for this to work.
@erica
erica / gist:5224282
Created March 22, 2013 19:58
Moooooooof
#define kClarusImageWidth 41
#define kClarusImageHeight 32
Byte moof[kClarusImageHeight][kClarusImageWidth] = {
{0,0,0,0,0,0,1,1,0,0,0,0,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,1,0,0,1,0,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,1,0,0,1,1,1,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0},
{0,0,0,0,0,1,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1},
{0,0,0,0,0,1,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1},
{0,0,0,0,1,0,0,0,1,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1},
{0,0,0,1,0,0,0,0,0,0,0,0,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,1},
2013-06-13 10:35:26.246 HelloWorld[26278:c07] [Helvetica Neue] HelveticaNeue-Light {NSCTFontProportionTrait = 0; NSCTFontSlantTrait = 0; NSCTFontSymbolicTrait = 0; NSCTFontWeightTrait = "-0.4";}, 14.000000
0 6 "Lorem "
NSFont: <UICTFont: 0xa265e60> font-family: "HelveticaNeue-Medium"; font-weight: bold; font-style: normal; font-size: 20px
NSColor: UIDeviceRGBColorSpace 0 0 1 1
6 6 "ipsum "
NSFont: <UICTFont: 0xed3f330> font-family: "HelveticaNeue-Light"; font-weight: normal; font-style: normal; font-size: 14px
NSColor: UIDeviceRGBColorSpace 1 0 0 1
@erica
erica / gist:5775391
Last active December 18, 2015 11:19
NSMutableAttributedString *s = [NSMutableAttributedString string];
NSMutableAttributedString *word = [NSMutableAttributedString stringWithString:@"Lorem "];
word.font = [UIFont headline1];
[s appendAttributedString:word];
word = [NSMutableAttributedString stringWithString:@"ipsum "];
word.color = [UIColor redColor];
word.font = [UIFont body].italic;
[s appendAttributedString:word];