It’s an apple thing you wouldn’t understand

March 11th, 2008

my iPhone drops a call, again, the third time in a conversation.

Scott:You need to get another phone, the reception on that is horrible

me: Your just not cool enough to understand the iPhone crackle.

Meeting Tim O’Reilly

February 26th, 2008

After lunch I was a bit down. I was having a hard time meeting people at the conference. I called my girlfriend for a peptalk.  She said “You did this all the time in highschool and college, just act like you belong”. I hung up on her in mid conversation because I saw someone from Dow Jones walking by. I started talking to him and he was nice.

Emboldened, I decided that I was going to buy a pack of cigarettes and stand outside the hotel smoking (I quit smoking 3 months ago). Smoking was always a great way of meeting people. When I had a cigarette with someone, I was normally good for a 3-5 minute conversation, much better than an elevator pitch. While I was walking towards a convenience store I saw Tim O’Reilly walking with another O’Reilly employee.
Me: Tim, Hi I’m Paddy I’m a big fan of yours. Thanks for putting on this conference.
Tim: Thanks. What do you do?

Me:I’m the founder of chartWidget we build licensable interactive charts.

Tim: We might need some charting work you should talk to [...] at the conference, Brady can introduce you. Thanks for coming to the conference.

Me: Well, I didn’t exactly come to the conference. I’m hanging out in the lobby. I don’t have tickets.

Tim: We can take care of that. Brady can you get him registered?

Me: Wow, thanks.

That made my day.

I spent the next day and a half at the conference and met many many people.

Thank you Tim.

me skiing

February 12th, 2008

Here are some pics of me from Canada.
dsc_5549_2.JPG

dsc_5550_2.JPG

dsc_5532_2.JPG

dsc_5517_2.JPG

Me Skiing

dsc_6130.JPG

dsc_6129.JPG

Lobby Conning at O’Reilly Money:Tech

February 12th, 2008

On Wednesday I went to the Waldorf Astoria to hang out in the lobby and meet people going to the money:tech conference. This was a $3000 conference, and being the founder of a growing start-up, I couldn’t afford the $3000 ticket, nor could any of my friends get me in for free. So, my idea was to hang out in the lobby – otherwise known as “lobby coning” – in hopes of finding people heading to offsite meetings (read: bars) where real business happens. I also wanted meet other people running finTech startups.


As soon as I walked in, I saw someone with a Money:Tech name tag. I walked up to him to introduce myself, when he asked: “Are you Jonah?” To which, I replied: “No, I’m not.” I proceeded to give him my pitch and explained that I’m not actually in the conference. He said, “Oh, you really should come.” I thought to myself “Dick, does it look like I’m in a position to spend $3k on this conference?” He was smug.


So I plopped myself down in what I thought was the lobby of the WA, and after looking around a bit, I realized that there were about 4 entrances to the hotel. Thus I would only have a 1/4 chance of meeting people. I chose a spot with access to WIFI, and out of boredom and curiosity, looked up ‘conference crashing.’ That’s when I discovered that the term for what I am doing is ‘lobby conning.’


Then I see Jim Cramer walk through the lobby – he’s a true celebrity to me. I got up and introduced myself to him. He was very nice, and actually soft spoken. He said he will check out chartWidget.


That was quite a high for me. The rest of the morning was uneventful, there weren’t large groups of people hanging out in the lobby. I also realized that since most of the finance people at the conference live in New York, they won’t be going out to bars after the conference, they would be going home. I was getting a bit down by lunch, because I hadn’t really met anyone else. I went out to grab food.

lispnyc

November 21st, 2007

I have started attending lispnyc events. Wow, what a group. This is the smartest room full of programmers I have ever been in. It is also a surprisingly approachable group. Whether or not you care about about lisp or functional programming I recommend that you attend. Not everyone there programs in lisp or even a functional language for their day job, they all care about programming though. As I learn more about lisp, through events like this, more and more thoughts pop into my head which enhances my code in less functional languages.

The next iPhone

July 9th, 2007

I was talking to a friend and we were discussing the next version of the iPhone. We figured it needed to get cheaper for it to get more market penetration. Then it hit me, obviously the next version of the iPhone will be the iPhone shuffle. It will only have one button, that randomly calls people in your phone list. Jobs will introduce it like this, “We have been following trends in phone usage and many people use their phone just to blabber to people and tell them stuff that the other person doesn’t care about. Drunk Dialing is another hot trend. I present the iPhone Shuffle”.

Re mapping the caps lock key in OS X

May 2nd, 2007

I have heard tales for a while of the joy of having your caps lock key remapped to a more useful modifier key. For me the most useful modifier key that I know of is ESC, for vim. Alas, this seems to be very dificult to do in OS X. Here are some of the false starts I made when trying to do this.

.vimrc
in vim you remap keys with the following command
:mmap
this is great and a very useful feature, unfortunately I can’t directly map the caps lock key with mmap.

System Preferences
at least in 10.4, OS X lets you remap the caps lock key to Control, Command, Alt, or Nothing. This is great for most people, but it doesn’t help me make it ESC. It also doesn’t help me map it to ESC for one app (Vim) and nothing for other apps.
You can find this option in
System Preferences > Keyboard & Mouse > Modifier Keys

.inputRC / xmodmap
These are files that BASH (maybe all shells) and X11 read on startup to map keys. I didn’t examine them too much. From what I hear it is possible to remap the Caps Lock key with xmodmap, but I don’t run X11 regularly

Ukelele / .keylayout files
Ukelele is a program for creating key layout files, it comes highly recommended, I wasn’t impressed. I found it easier to hand edit the xml key layout files that OS X uses. You can read about their schema here. I found out that the caps lock key should generated a key code of 55 or 57 depending on whether it’s being turned on or off. On OS X they don’t generate that key code for a keylayout file to manipulate.

Writing A C program to modify keycodes
I ran across this code example OS X Internals and this code. Now I was on to something. I had one program that modifies key codes, and another one that traps the caps lock key (or any other modifier key being pressed. I was able to hack the code to generate a key code of “74″ (unused in the keylayouts I am using) every time the caps lock key is pressed. I was enormously satisfied with this.

Blinksale highly recommended

May 2nd, 2007

As a freelance worker I of course have to generate invoices for my clients. I don’t enjoy this process, I always worry that I’m not submitting a professional looking invoice. I discovered this company, Blinksale, that makes it easy. They are apparently big fans of 37signals. I am impressed with their product. It does one thing and does it efficiently

Delving into the Firefox source code

April 27th, 2007

Continuing from the previous post. I downloaded the Firefox source code and started trying to figure out why textContent was faster than innerHTML.

The FF source code is a daunting beast, around 57,000 files. I started with grep. this returned 57 files for innerHTML and 72 files for textContent. I then used comm to see which files had both words in them, only one did.

Somehow I decided to try looking at the idl files that grep returned. From these files I was able to figure out what I thought were the .cpp files related to the properties.

Here are links to the files on Mozilla’s website
innerHTML is found in this file
nsGenericHTMLElement.cpp
Here is a changelog of the setInnerHTML function
http://lxr.mozilla.org/mozilla1.8/ident?i=SetInnerHTML

Here is the cpp file that contains textContent
nsHTMLOptionElement.cpp
here is the changelog of the setText function
http://lxr.mozilla.org/mozilla1.8/ident?i=SetText

I haven’t actually yet figured out what each function does, but I’m getting there. I’m also not sure if I have the correct file for textContent.

speed of innerHTML vs textContent

April 27th, 2007

I was working on one of my js apps that updates the content of an element on mouseover. The performance in FF 2 was poor compared to all other browsers. After profiling with Firebug I realized that the problem was setting the innerHTML of an element. In Firebug, setting the innerHTML took about 3 times as long as the rest of the code for the mouseover, which included getting the mouse position, pulling a value from a large array, performing math on that number, and moving a cursor to the proper place on the screen.

I looked up the js docs, and found that FF elements have a property named textContent. I used this property instead of innerHTML, and performance for the mouseover doubled.

I was happy about finding this quirk. Then I told my friend Derik about it, he asked “did you look at the source to figure out why textContent is faster?”, then he called me a pussy when I told him I hadn’t.

The next post will be about delving into the Firefox source code