Skip to content

Instantly share code, notes, and snippets.

View TechUnRestricted's full-sized avatar
🍊

TechUnRestricted

🍊
View GitHub Profile
@krzyzanowskim
krzyzanowskim / Demangle Swift
Created October 16, 2016 23:20
Hopper Disassembler Swift names demangle script
import subprocess
def looksLikeBeginning(doc,seg,adr):
if isinstance(seg.getNameAtAddress(adr), str):
label = seg.getNameAtAddress(adr)
pos = label.find("_T")
if pos != -1:
return label[pos:]
return None
@zacwest
zacwest / ios-font-sizes.swift
Last active May 17, 2024 10:24
iOS default font sizes - also available on https://www.iosfontsizes.com
let styles: [UIFont.TextStyle] = [
// iOS 17
.extraLargeTitle, .extraLargeTitle2,
// iOS 11
.largeTitle,
// iOS 9
.title1, .title2, .title3, .callout,
// iOS 7
.headline, .subheadline, .body, .footnote, .caption1, .caption2,
]
@bananita
bananita / How to convert *app to *ipa
Created December 19, 2013 13:23
How to convert *app to *ipa
1. Create a folder called Payload
2. Place the .app folder inside of that
3. Zip up the Payload folder using normal compression
4. Then rename the file with a .ipa extension
@eric-robinson
eric-robinson / gist:1593255
Created January 11, 2012 05:45
NSColor to CGColor
@interface NSColor(Additions)
- (CGColorRef)toCGColor;
@end
@implementation NSColor(Additions)
- (CGColorRef)toCGColor {
CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceRGB();
NSColor* selfCopy = [self colorUsingColorSpaceName:NSDeviceRGBColorSpace];