basic CSS template for A4 print
Forked from rafaelcastrocouto's Pen A4 CSS page template.
A Pen by Dermot McGuire on CodePen.
-(float)compareString:(NSString *)originalString withString:(NSString *)comparisonString | |
{ | |
// Normalize strings | |
[originalString stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]]; | |
[comparisonString stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]]; | |
originalString = [originalString lowercaseString]; | |
comparisonString = [comparisonString lowercaseString]; | |
// Step 1 (Steps follow description at http://www.merriampark.com/ld.htm) |
// Updates to LLVM give us better instantiation methods | |
NSNumber *n1 = @1000; // [NSNumber numberWithInt:1000] | |
NSNumber *n2 = @3.1415926; // [NSNumber numberWithDouble:3.1415926] | |
NSNumber *c = @'c'; // [NSNumber numberWithChar:'c'] | |
NSNumber *b = @YES; // [NSNumber numberWithBool:YES] | |
Arrays | |
// before | |
NSArray *words = [NSArray arrayWithObjects:@"list", @"of", @"words", nil]; |
#import <Foundation/Foundation.h> | |
#import <objc/runtime.h> | |
#import "typestring.h" | |
// clang -g -fobjc-arc -Wall -framework Foundation -o runtime typestring.m runtime.m | |
// Runtime reference, at least until Apple breaks the link | |
// http://developer.apple.com/library/ios/#documentation/Cocoa/Reference/ObjCRuntimeRef/Reference/reference.html |
// clang -fobjc-arc -framework Foundation runtime-class.m | |
#import <Foundation/Foundation.h> | |
#import <objc/runtime.h> | |
@interface Person : NSObject | |
- (id)initWithFirstName: (NSString *)firstName lastName: (NSString *)lastName age: (NSUInteger)age; |
// When the `accessibility inspector' is enabled on the iOS Simulator the private `UIAccessibility' | |
// framework is loaded. In turn it will try to load a list of bundles amongst which is one that has | |
// only resources, no executable. This leads to `CFBundleLoadExecutableAndReturnError' logging this | |
// offending error message. | |
// | |
// This code omits the `SDK_ROOT/System/Library/AccessibilityBundles/CertUIFramework.axbundle' | |
// bundle from ever being attempted to load. | |
// | |
// This code is available under the MIT license: http://opensource.org/licenses/MIT | |
// |
/** | |
* JapaneseCharacter contains static functions to do various tests | |
* on characters to determine if it is one of the various types of | |
* characters used in the japanese writing system. | |
* <p/> | |
* There are also a functions to translate between Katakana, Hiragana, | |
* and Romaji. | |
* | |
* @author Duane J. May <[email protected]> | |
* @version $Id: JapaneseCharacter.java,v 1.2 2002/04/20 18:10:24 djmay Exp $ |
import GCDWebServer | |
class CorsProxy { | |
init(webserver : GCDWebServer!, urlPrefix: String) { | |
var prefix = | |
(urlPrefix.hasPrefix("/") ? "" : "/") | |
+ urlPrefix | |
+ (urlPrefix.hasSuffix("/") ? "" : "/") | |
let pattern = "^" + NSRegularExpression.escapedPatternForString(prefix) + ".*" |
basic CSS template for A4 print
Forked from rafaelcastrocouto's Pen A4 CSS page template.
A Pen by Dermot McGuire on CodePen.
All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.
Generally, all APIs that synchronously provide layout metrics will trigger forced reflow / layout. Read on for additional cases and details.
elem.offsetLeft
, elem.offsetTop
, elem.offsetWidth
, elem.offsetHeight
, elem.offsetParent
/* | |
* v8_wrap_class.cpp | |
* | |
* Created on: 14/01/2013 | |
* Author: nicholas | |
* License: public domain | |
*/ | |
/* CMakeLists.txt | |
project(v8_wrap_class) |