Skip to content

Instantly share code, notes, and snippets.

@Ellein-Keen
Ellein-Keen / AppStoryboard.swift
Created May 12, 2017 15:49 — forked from Gurdeep0602/AppStoryboard.swift
AppStoryboard enumeration
//
// AppStoryboards.swift
// AppStoryboards
//
// Created by Gurdeep on 15/12/16.
// Copyright © 2016 Gurdeep. All rights reserved.
//
import Foundation
import UIKit
@Ellein-Keen
Ellein-Keen / coreDataCheatSheet.swift
Created April 29, 2016 10:44
Core Data Cheat Sheet for Swift iOS Developers
// Fetch entities
let fetchRequest = NSFetchRequest(entityName: "Note")
var sortDescriptor = NSSortDescriptor(key: "text", ascending: false)
fetchRequest.sortDescriptors = [sortDescriptor]
let predicate = NSPredicate(format: "MyEntityAttribute == %@", "Matching Value")
fetchRequest.predicate = predicate
@Ellein-Keen
Ellein-Keen / UIColor+RGB.swift
Created April 3, 2016 06:37 — forked from mbigatti/UIColor+RGB.swift
UIColor extension that add a whole bunch of utility functions.
//
// UIColor+RGB.swift
// Copyright (c) 2014 Massimiliano Bigatti. All rights reserved.
//
import Foundation
import UIKit
/**
UIColor extension that add a whole bunch of utility functions like:
@Ellein-Keen
Ellein-Keen / RoundRectButton.swift
Created February 25, 2016 13:53 — forked from kristopherjohnson/RoundRectButton.swift
Swift: Custom UIButton subclass that displays a rounded rectangle in the background
import UIKit
/// UIButton subclass that draws a rounded rectangle in its background.
public class RoundRectButton: UIButton {
// MARK: Public interface
/// Corner radius of the background rectangle
public var roundRectCornerRadius: CGFloat = 8 {
@Ellein-Keen
Ellein-Keen / animation6-13.swift
Created February 13, 2016 17:51 — forked from sunnycyk/animation6-13.swift
Core Animation Example
//
// ViewController.swift
// animation613
//
// Created by Sunny Cheung on 23/10/14.
// Copyright (c) 2014 khl. All rights reserved.
//
import UIKit