This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function abomination(InnerComponent) { | |
const Subclass = (function(SuperComponent) { | |
function Subclass() { | |
SuperComponent.prototype.constructor.apply(this,arguments); | |
} | |
Subclass.prototype = Object.create(SuperComponent.prototype); | |
Subclass.prototype.componentDidMount = function() { | |
if (SuperComponent.prototype.componentDidMount) { | |
SuperComponent.prototype.componentDidMount.apply(this,arguments); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/opt/local/bin/php | |
<?php | |
// logs can be viewed with: | |
// sudo tail -f /opt/local/var/squid/logs/cache.log | |
$enabled = true; | |
$verboseLogging = true; | |
$upsideDownTernet = false; | |
$negativeLand = true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(void)drawInteriorWithFrame:(NSRect)theControlViewBounds inView:(NSView*)theControlView { | |
if (!self.isEditing) { | |
NSLog(@"%@ drawInteriorWithFrame:%@; inView:%@;",self, NSStringFromRect(theControlViewBounds),theControlView); | |
self.isEditing = YES; | |
NSTextView *theTextView = [self textDrawingObject]; | |
NSTextContainer *theTextContainer = [theTextView textContainer]; | |
NSLayoutManager *theLayoutManager = [theTextContainer layoutManager]; | |
NSTextStorage *theTextStorage = [theLayoutManager textStorage]; | |
NSRange theOldGlyphRange = NSMakeRange(0, [theLayoutManager numberOfGlyphs]); | |
NSRange theOldCharacterRange = [theLayoutManager characterRangeForGlyphRange:theOldGlyphRange actualGlyphRange:nil]; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// test | |
NSRect theRect = [theTextContainer lineFragmentRectForProposedRect:proposedRect sweepDirection:sweepDirection movementDirection:movementDirection remainingRect:remainingRect]; | |
NSLog(@"This is your rect:%@;",NSStringFromRect(theRect)); |