Wyoming, Michigan, you’re not alone (cities named after states)

April 9th, 2008

I ordered some new sandals online this weekend, and they shipped last night from Wyoming, Michigan. Cities named like this confuse me, and I felt prompted to figure out what other cities are named after states. After doing some quick searches, I couldn’t find a full list, and decided it would be a fun little problem to solve.

So I coded it up really quickly. It turns out there’s a lot — 289 to be exact. Click through to the full post to see the complete list.

This list doesn’t include cities that are named after countries or foreign cities. For example, another common shipping origin seems to be Ontario, CA (California, not Canada). That one confused me even more when I first read it on my tracking information.

  • Colorado, AK
  • Montana, AK
  • Georgia, AL
  • Kansas, AL
  • Pennsylvania, AL
  • Texas, AL
  • Virginia, AL
  • Alabama, AR
  • Arkansas, AR
  • California, AR
  • Delaware, AR
  • Georgia, AR
  • Illinois, AR
  • Kansas, AR
  • Kentucky, AR
  • Mississippi, AR
  • Missouri, AR
  • Montana, AR
  • Tennessee, AR
  • Texas, AR
  • Washington, AR
  • Maine, AZ
  • Minnesota, CA
  • Nevada, CA
  • Washington, CA
  • Florida, CO
  • Ohio, CO
  • Washington, CT
  • Washington, DC
  • Wyoming, DE
  • New York, FL
  • California, GA
  • Minnesota, GA
  • Ohio, GA
  • Texas, GA
  • Washington, GA
  • Delaware, IA
  • Indiana, IA
  • Iowa, IA
  • Maine, IA
  • Nebraska, IA
  • Nevada, IA
  • New York, IA
  • Ohio, IA
  • Oregon, IA
  • Virginia, IA
  • Washington, IA
  • Wyoming, IA
  • Virginia, ID
  • Kansas, IL
  • Kentucky, IL
  • Maine, IL
  • Maryland, IL
  • Mississippi, IL
  • Missouri, IL
  • Nebraska, IL
  • Nevada, IL
  • Ohio, IL
  • Oregon, IL
  • Pennsylvania, IL
  • Tennessee, IL
  • Texas, IL
  • Utah, IL
  • Vermont, IL
  • Virginia, IL
  • Washington, IL
  • Wyoming, IL
  • Alaska, IN
  • California, IN
  • Delaware, IN
  • Florida, IN
  • Georgia, IN
  • Kansas, IN
  • Michigan, IN
  • Nebraska, IN
  • Nevada, IN
  • Ohio, IN
  • Oregon, IN
  • Texas, IN
  • Utah, IN
  • Vermont, IN
  • Washington, IN
  • Colorado, KS
  • Delaware, KS
  • Georgia, KS
  • Illinois, KS
  • Indiana, KS
  • Iowa, KS
  • Kentucky, KS
  • Michigan, KS
  • Montana, KS
  • Nevada, KS
  • Ohio, KS
  • Washington, KS
  • Arkansas, KY
  • California, KY
  • Delaware, KY
  • Kansas, KY
  • Nevada, KY
  • New York, KY
  • Oklahoma, KY
  • Oregon, KY
  • Texas, KY
  • Virginia, KY
  • Washington, KY
  • Wyoming, KY
  • Arizona, LA
  • Delaware, LA
  • Georgia, LA
  • Iowa, LA
  • Maryland, LA
  • Oklahoma, LA
  • Texas, LA
  • Washington, LA
  • Florida, MA
  • Texas, MA
  • Washington, MA
  • Wyoming, MA
  • California, MD
  • New Mexico, MD
  • Oklahoma, MD
  • Oregon, MD
  • Texas, MD
  • California, ME
  • Maine, ME
  • Virginia, ME
  • Washington, ME
  • Alaska, MI
  • California, MI
  • Delaware, MI
  • Kentucky, MI
  • Oregon, MI
  • Texas, MI
  • Washington, MI
  • Wyoming, MI
  • Alaska, MN
  • Delaware, MN
  • Florida, MN
  • Maine, MN
  • Nevada, MN
  • Virginia, MN
  • Washington, MN
  • West Virginia, MN
  • Wisconsin, MN
  • Wyoming, MN
  • California, MO
  • Delaware, MO
  • Florida, MO
  • Guam, MO
  • Louisiana, MO
  • Mississippi, MO
  • Missouri, MO
  • Nevada, MO
  • New York, MO
  • Ohio, MO
  • Oregon, MO
  • Texas, MO
  • Virginia, MO
  • Washington, MO
  • Nevada, MS
  • Oklahoma, MS
  • Oregon, MS
  • Texas, MS
  • Washington, MS
  • California, NC
  • Maine, NC
  • Nebraska, NC
  • Texas, NC
  • Washington, NC
  • Idaho, ND
  • Illinois, ND
  • Iowa, ND
  • Maine, ND
  • Maryland, ND
  • Michigan, ND
  • Minnesota, ND
  • Missouri, ND
  • Virginia, ND
  • Washington, ND
  • Arizona, NE
  • Iowa, NE
  • Michigan, NE
  • Virginia, NE
  • Washington, NE
  • Wyoming, NE
  • Washington, NH
  • Delaware, NJ
  • Georgia, NJ
  • Maryland, NJ
  • Montana, NJ
  • Texas, NJ
  • Washington, NJ
  • Wyoming, NJ
  • Alaska, NM
  • Florida, NM
  • New York, NM
  • Washington, NV
  • Alabama, NY
  • Delaware, NY
  • Florida, NY
  • Idaho, NY
  • Maine, NY
  • Maryland, NY
  • New York, NY
  • Ohio, NY
  • Oregon, NY
  • Rhode Island, NY
  • Texas, NY
  • Washington, NY
  • Wyoming, NY
  • California, OH
  • Delaware, OH
  • Florida, OH
  • Idaho, OH
  • Kansas, OH
  • Nevada, OH
  • New Hampshire, OH
  • Ohio, OH
  • Oregon, OH
  • Texas, OH
  • Virginia, OH
  • Washington, OH
  • Wyoming, OH
  • Delaware, OK
  • Kansas, OK
  • Washington, OK
  • Alaska, PA
  • California, PA
  • Delaware, PA
  • Idaho, PA
  • Indiana, PA
  • Iowa, PA
  • Nebraska, PA
  • Ohio, PA
  • Oklahoma, PA
  • Oregon, PA
  • Texas, PA
  • Washington, PA
  • Wyoming, PA
  • Florida, PR
  • Washington, RI
  • Wyoming, RI
  • Texas, SC
  • Washington, SC
  • Delaware, SD
  • Georgia, SD
  • Iowa, SD
  • Minnesota, SD
  • Ohio, SD
  • Vermont, SD
  • Virginia, SD
  • Washington, SD
  • Idaho, TN
  • Kansas, TN
  • Utah, TN
  • Arizona, TX
  • Colorado, TX
  • Georgia, TX
  • Nevada, TX
  • New York, TX
  • Ohio, TX
  • Oklahoma, TX
  • Puerto Rico, TX
  • Rhode Island, TX
  • Tennessee, TX
  • Washington, TX
  • Washington, UT
  • California, VA
  • Delaware, VA
  • Washington, VA
  • Georgia, VT
  • Kansas, VT
  • Michigan, VT
  • Texas, VT
  • Washington, VT
  • Virginia, WA
  • Alaska, WI
  • Maine, WI
  • Montana, WI
  • Oregon, WI
  • Texas, WI
  • Vermont, WI
  • Washington, WI
  • Wyoming, WI
  • Arkansas, WV
  • Montana, WV
  • Washington, WV
  • Wyoming, WV
  • Wyoming, WY

Not sure of the point of allowing signups then…

March 14th, 2008

I received this email a few minutes ago:

Dear Registered iPhone Developer,

Thank you for expressing interest in the iPhone Developer Program. We have received your enrollment request. As this time, the iPhone Developer Program is available to a limited number of developers and we plan to expand during the beta period. We will contact you again regarding your enrollment status at the appropriate time.

It seems to me if they were only opening it up to select people, they should have held off on the signup form until they were actually ready for people to sign up. I guess they have to wait to get our $99.

Update:
It sounds like it was either first-come or random. I guess we fail for now.


REAL World 2008 Agenda Calendar

March 8th, 2008

In addition to Norman’s REAL World 2008 Track Calendar, I’ve created an iCal file for the conference agenda itself, excluding the session blocks. Combining his calendars with mine, you can now have the entire REAL World 2008 schedule in iCal. More importantly, it allows me to have everything on my iPhone :)

Subscribe

Download

Also, anyone who’s interested in meeting up with me and discussing any of our products, seek me out on Tuesday night, Wednesday, or Thursday. I’m also giving a talk on Team Development at 1:00 on Wednesday, so be sure to come if that sort of thing interests you.


TextKit a3 Available

February 1st, 2008

Following up Tuesday’s build, I’ve added a few more features and fixes to this release. I will be out of town for the next week, so it will be two weeks before a4. The changes are:

  • Cut, Copy, Paste, Select All, and Clear are all automatically enabled and handled. Currently only plain text is copied and pasted, but styled text will most likely be implemented in a4 or a5.
  • When clicking at the end of a line that ends with a line ending, the insertion point no longer is after the line ending, but rather directly after the last character on that line.
  • Clicking beyond the last line in the field now properly moves the insertion point to the end. Note that dragging from beyond the last line currently does not work.
  • When the insertion point is at the very end of the field, pressing a carriage return will insert a new line instead of adding a blank space to the last line.
  • The examples folder has been rearranged to help new people to the project understand the different components. A new example is in the works (the obvious one: a text editor).

To download the new version, visit the product page.

As always, we look forward to your feedback!


Window.FloaterProcess Fix for Mac OS X

February 1st, 2008

Recently on the NUG, a question came up about making Window.FloaterProcess work correctly on Mac OS X. This property is designed to make it easy to have one of your global floating windows show up only “inside” of another application. After a lack of volunteers, I coded up a generic drop-in fix.

Module FloaterProcessFix
  Private Const kEventAppFrontSwitched = 7
  Private Const kEventClassApplication = 'appl'
 
  Protected Sub CheckOpenWindows()
    declare function GetFrontProcess lib "Carbon" (psn as Ptr) as Integer
    dim psn as new MemoryBlock(8)
    dim err as Integer = GetFrontProcess(psn)
    if err = 0 then
      declare function GetProcessInformation lib "Carbon" (psn as Ptr, _
        info as Ptr) as Integer
      dim info as new MemoryBlock(60)
      err = GetProcessInformation(psn, info)
      if err = 0 then
        dim p as Ptr = info
        dim type as String = p.OSType(20)
        HideShowFloaters(type)
      end if
    end if
  End Sub
 
  Protected Sub Install()
    declare function NewEventHandlerUPP lib "Carbon" (handler as Ptr) _
      as Integer
    declare function InstallEventHandler lib "Carbon" (target as Integer, _
      handler as Integer, itemCount as Integer, typeList as Ptr, _
      userData as Integer, outRef as Integer) as Integer
    declare function GetApplicationEventTarget lib "Carbon" () as Integer
 
    dim handler as Integer = _
      NewEventHandlerUPP(addressOf CarbonEventHandler)
    dim eventTypes as new MemoryBlock(8)
    eventTypes.Int32Value(0) = kEventClassApplication
    eventTypes.Int32Value(4) = kEventAppFrontSwitched
    dim err as Integer
    err = InstallEventHandler(GetApplicationEventTarget, _
      handler, 1, eventTypes, 0, 0)
 
    CheckOpenWindows
  End Sub
 
  Private Function CarbonEventHandler(inHandlerCallRef as Integer, _
      inEvent as Integer, inUserData as Integer) As Integer
    CheckOpenWindows
    return 0
  End Function
 
  Private Sub HideShowFloaters(frontAppCode as String)
    for i as integer = 0 to WindowCount - 1
      if strcomp(Window(i).FloaterProcess, frontAppCode, 0) = 0 then
        Window(i).Show
      elseif Window(i).FloaterProcess <> "" then
        Window(i).Hide
      end if
    next
  End Sub
End Module

How does the code work? There is a Carbon event that fires each time a new application is activated. By installing this handler, we can then find out what the creator code of the frontmost app is, loop over our windows, and hide/show them appropriately. Because Carbon events are fired only when the event happens, the CPU usage is nearly 0, and you can once again use FloaterProcess on OS X.

You can download a full example here.


TextKit a2 Available

January 29th, 2008

We’ve made alpha 2 of TextKit available which includes several features and fixes that you’ve requested.

We’re excited to see how much interest there is in this product. Please let us know if there’s anything you would love to see this field do by either commenting here or filing a new ticket.

Visit the product page to download and learn more about TextKit.

Thanks everyone!


TextKit Released as Public Beta

January 24th, 2008

If you remember back to our teasers, we previewed a new product code-named ESTO. We’ve since named the product TextKit, and we’re pleased to announce that we are previewing it in a public beta.

TextKit is a REALbasic plugin that provides a rendering engine for styled text as well as a corresponding EditField-like control that works on Mac OS X, Windows, and Linux. Unlike most other engines, this engine is written specifically for REALbasic and is extremely extendable.

TextKit provides two classes to help with displaying and editing text: TKTextRenderer and TKTextField. Unlike REALbasic’s built-in classes, TKTextRenderer can be used to manipulate and draw text offscreen. TKTextField provides an easy way to edit and display text and objects on a window.

During this public beta, we are extending our customers a special offer: If you buy TextKit today, we’ll extend your license by twelve months from the day that we release TextKit 1.0. It’s our way of showing our gratitude for helping us improve the product.

More information about TextKit can be found at http://alacatialabs.com/products/textkit/. We look forward to hearing everyone’s feedback.


QA Deathmatch: Making Testing Fun

January 10th, 2008

An excellent idea over at The SlickEdit Developer Blog:

I’ve worked previously at several companies that didn’t have a QA department available. When the code freeze happened, all of the developers would go into QA mode. We’d then spend the next few weeks testing the features, and typically each developer would test their own. It was possibly the most feared and hated time of the year.

If you’re familiar with Quake, or pretty much any other FPS, then you know about the deathmatch. It’s my single favorite type of game and, in it’s own way, is really therapeutic when the stress of development, or testing, gets you down. A lot of the other developers I worked with at one point also loved to deathmatch and we used to play during lunch. When testing time came around, we found a way to make it fun… QA Deathmatch.

He goes on detailing the rules of QA Deathmatch. For someone who started out as a tester, this was highly entertaining, and I wished there was something like that in place when I was testing. Another idea is to have prizes for winners each week or month, giving everyone an incentive to participate and have some fun :)


Mail.app: IMAP Folders not updating?

January 2nd, 2008

Ever since switching to Leopard, Mail.app sometimes doesn’t update folders with new messages, even if the messages added to those folders are a result of rules in Mail.app. I searched, and found partial solutions to my liking, but here’s what I settled on.

In Script Editor, save this script somewhere:

on run
  tell application "System Events"
    if exists (application processes whose name is "Mail") then
      tell application "Mail"
        set everyIMAPAccount to every imap account
        repeat with eachIMAPAccount in everyIMAPAccount
          tell eachIMAPAccount
            synchronize with eachIMAPAccount
          end tell
        end repeat
      end tell
    end if
  end tell
end run

Next, add a new rule to Mail.app that has the condition “Any Message,” and the action “Run Applescript” using this AppleScript. All this script does is automatically run “Synchronize” on each account any time a new message is found. This ensures that all folders are kept up to date.

I’ve been using this solution for a week now, and it’s been a godsend.

Edit:

See comments for a much simpler script.


Holiday Teaser 2: Fast and Pretty Graphics

December 18th, 2007

If someone asked me to state what I dislike about REALbasic’s Graphics API, I would state:

  • It can’t be extended/overridden for different output devices (ie, a PDFGraphicsContext)
  • The API is structured around ancient QuickDraw philosophies, not around modern CoreGraphics/GDI+ apis.
  • It’s much slower on OS X than it needs to be.
  • Does not support CoreText.
  • The TextFont/Bold/Italic properties don’t offer much flexibility for fonts, and don’t support all of the fonts on the system.
  • Rotation/alpha/scaling are related to Object2D, and can’t be performed independently.
  • Rotation doesn’t work when printing on all platforms.
  • Curve drawing is limited to Object2D.
  • Subpixel rendering is not available outside of Object2D.
  • Object2D has a funky way of handling positions, rotations, and scales (feel free to ask me more about this if you disagree; it should be its own post).
  • It doesn’t work in console applications.

Well, what we have coming up solves all except the last item (at least initially).

Salivation: begin.