Skip to content

Instantly share code, notes, and snippets.

View mustafaibrahim989's full-sized avatar

Mustafa Ibrahim mustafaibrahim989

View GitHub Profile
func roundImage(#image: UIImage, withSize size: CGSize, withStorkeColor strokeColor: UIColor, withCornerRaduis raduis: CGFloat, withBorderWidth borderWidth: CGFloat) -> UIImage {
UIGraphicsBeginImageContextWithOptions(image.size, false, 0)
let borderWidth: CGFloat = borderWidth
let cornerRadius:CGFloat = raduis
let multiplier:CGFloat = image.size.height/size.height > image.size.width/size.width ?
image.size.height/size.height :
image.size.width/size.width
//
// RBResizer.swift
// Locker
//
// Created by Hampton Catlin on 6/20/14.
// Copyright (c) 2014 rarebit. All rights reserved.
//
import UIKit
//
// MBProgressHUD+Extra.h
// EFG-IPhone
//
// Created by Mustafa Ibrahim on 10/23/14.
// Copyright (c) 2014 EFGHermes. All rights reserved.
//
#import "MBProgressHUD.h"
//
// CheckConnection.h
// Youxel Technology
//
// Created by Mustafa Ibrahim on 10/3/12.
// Copyright (c) 2012 Youxel Technology. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "Reachability.h"
@mustafaibrahim989
mustafaibrahim989 / UIImage(MICropping).m
Last active January 26, 2016 10:37
Image cropping with resizing
//
// UIImage+MICropping.m
// Mustafa Ibrahim
//
// Created by Mustafa Ibrahim on 2/4/14.
// Copyright (c) 2014 Mustafa Ibrahim. All rights reserved.
//
#import "UIImage+MICropping.h"