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
/* This is a VERY heavily abridged part of my code for event | |
handlers and editable DIVs. | |
The full code can be found here: http://github.com/hotdog003/gutenborg/tree/master */ | |
function gbDocument(docname) { | |
// This creates a new document then subscribes us to it. | |
this.jqedit = $("<div class='gb-editor'></div>"); // Our jQuery text editor | |
// ... |
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
this.get_start_offset = function () { | |
// Get the number of characters before the start of the selection. | |
// Thanks, TinyMCE | |
var range = this.get_range(); | |
if ($.browser.msie) { | |
// IE support | |
// Text selection | |
c = -0xFFFFFF; // ooooooooooh, magic | |
tr = document.body.createTextRange(); // Create a new blank range | |
begin = range.duplicate(); // Create a copy of the range we've selected |
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
def insert(self, user, pos, text, state): | |
""" | |
Inserts text into the document at pos | |
""" | |
# MANY THANKS TO Infinote for help with these transformations: | |
# http://gobby.0x539.de/trac/wiki/Infinote/Protocol | |
# First, reach back in time and see what we should do | |
# Think of this like a "git rebase"- we want to rebase | |
# the NEW changes on top of the changes the person |
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
import java.io.*; | |
/* | |
** Demonstrates how to set up a pathway between program and disk file | |
*/ | |
public class FileOutputDemo { | |
public static void main(String[] args) throws IOException { | |
// use File | |
File f1 = new File ("first.dta"); |
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
michael@northbound:~$ python | |
Python 2.5.2 (r252:60911, Oct 5 2008, 19:24:49) | |
[GCC 4.3.2] on linux2 | |
Type "help", "copyright", "credits" or "license" for more information. | |
>>> import sys | |
>>> sys.setrecursionlimit(sys.maxint) | |
>>> sys.setrecursionlimit(2**31-1) | |
>>> def f(): | |
... f() | |
... |
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
def insert(self, user, pos, text, state): | |
""" | |
Inserts text into the document at pos | |
""" | |
# MANY THANKS TO Infinote for help with these transformations: | |
# http://gobby.0x539.de/trac/wiki/Infinote/Protocol | |
# First, reach back in time and see what we should do | |
# Think of this like a "git rebase"- we want to rebase | |
# the NEW changes on top of the changes the person |
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
Conversation with #lisp at Tue 27 Jan 2009 11:46:49 AM MST on [email protected] (irc) | |
(11:46:49 AM) #lisp: The topic for #lisp is: Common Lisp, the #1=(programmable . #1#) programming language <http://paste.lisp.org/new/lisp>. New: SBCL 1.0.24, usocket 0.4.1, ABCL 0.12, cl-net-snmp 5.19, yason-0.1, trivial-features 0.4, CFFI 0.10.3, series 2.2.10 | |
(11:46:50 AM) nacsucauz: uhm | |
(11:47:02 AM) dcrawford: sounds right to me | |
(11:47:18 AM) nyef: "This must be a meaning of the word 'delegate' which I was previously unaware of." | |
(11:47:18 AM) hotdog003: Hello, frienth! I'm curiouth about thith language and wath wondering where I could get tharted. | |
(11:47:21 AM) nacsucauz: but they are similar, aren't? | |
(11:47:38 AM) ahaas: hotdog003: Go away. | |
(11:47:47 AM) nyef: ahaas: Don't feed the trolls. | |
(11:47:58 AM) hotdog003 has left #lisp |
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
Never be alone :) | |
A choice man, of how much we put out, how much we allow God to use. How much we listen. | |
I fail at listening, a lot. | |
I don't pay attention. and I am just as afraid as you are, my friend. | |
God is here though. God gives the abilities necessary to conquer all we face. Fatherhood. Husbandry. Friendship. Honesty. Freedom. Self-worth. Self-loathing. Intimacy. Love. | |
but all of these things. | |
all of them | |
we look at as pressures now, and that is saddening. |
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
// Sentinel-controlled loop | |
// User will enter up to MAXSCORES test scores, or a -1 to finish. | |
// This loop cannot use breaks. | |
do { | |
printf("Score %d: ", *nScores+1); | |
scanf("%d", &userResponse); // Get the response | |
if (userResponse >= 0) { | |
scores[*nScores] = userResponse; // Save it | |
*nScores = *nScores + 1; |
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
aoeuaoeu |