The other Romex in the pan is a grey cable.
It is a 2 way switch with a ground screw.
I have not separated the wires on the wire nut yet, but I will try that.
I'm not sure I follow the last paragraph. I have measured the voltage on the bottom screw of the switch to the ground wire in the switchbox, and got ~120V, switch off or on. With the top screw and ground wire, I got 120V when the switch is on, but 0 when off.
Here's where I believe I made a mistake: I tried to measure the voltage between the top and bottom screws, which immediately made a rather large spark and blew the circuit breaker. I did not have anything connected to the fixture.
OTOH, I know which breaker that switch and fixture is on, now... which is unfortunately the same breaker the living room light+fan, exterior lights, utility room light, and outlet the AV equipment is plugged into. So I'll need to wait to find the right time to kill the power.
I'll get you the pic of the switch as soon as I do that, as well as the voltage test on the two connected conductors in the pan.
Thank you very much!
that means the switch works as it should and it's a single pole (not a 2 way!) with circuit wires on a switch that has 2 screws (not counting the system ground screw)
what happened when you went accross the switch it sounds like you accidentally grounded one of the meter terminals to the grounded switch causing a short circuit to ground, which trips the breaker. check the switch and the leads on your meter. the switch should show arc marks and carbon spatter from the energy released; the meter lead(s) will have a piece missing from it as it was welded onto the switch or off!
so far everything looks like it's wired ok. you simply need to put it back as you took it apart once you connect it up to your fan.
once you replace the box with a fan rated box and mount it properly to the wall here is what you should do:
based on one of your post
"Here's what I know, though. With the breakers (light switch?) off, I didn't get voltage on either loose black or white wire, either to each other or to the ground. I did get ~120V on the black/white mix; I think just to ground, but possibly to the other two wires as well. I guess I'll have to check it again. "
this means that the black wire that's connected to the white switch leg is the constant hot, this is correct and good.
after your box is mounted connect the constant hot black back to the switch leg (the yellow romex) white conductor the other black conductor from the switch will bring power to your fan light fixture and the wire from most fan kits for the light switch is blue (verify this with your fan installation instructions)
next, both your fan motor and light fixture neutrals (both should be white) get connected to that white wire that looks beige with the red wire nut on it. the fan motor should be a black conductor and connect it to the black/white wire under that wire nut. the reason for this is that the switch will turn on and off your fan light only (pull the pull chain on the fan for the light and leave the pull chain alone from then on only controlling the light with the wall switch. the fan motor is controlled by the fan speed pull chain. now you can turn the light on and off independent of the fan so on hot nights you can turn the light switch off and the fan will continue to turn. if you have a fan with a standard incandescent lamp you can use a dimmer switch to dim the lights. you cannot use a dimmer if your fan light kit has compact flourescent type lights again, read your fan kit instructions carefully.
hope this makes some sense; please keep me posted.