Seeking translation help with か between two verbs and と


> よだかは口を大きくひらいて、はねをまっすぐに張って、まるで矢のようにそらをよこぎりました。  
> からだがつちにつく **か** つかない **うちに** 、よだかはひらり **と** またそらへはねあがりました。

I'm having trouble parsing that 2nd sentence especially the usage of the
bolded か , うちに and と.

* * *

Right now, I'm reading the **か** as "or" (the same way it's used when listing
nouns) but I don't know if that's grammatically correct. I'm also reading
**うちに** as "while" and **とまた** as "and again", which makes my current reading:

> Yodaka opened his mouth wide, spread his wings straight back and moved
> through the sky like an arrow.  
> **While** his body was colliding **or** not colliding with the ground,
> Yodaka **again** nimbly flew up toward the sky.

* * *

**EDIT:**  
I've done some reading on SE, and it seems that:

  1. **うちに** does mean "while", See: [Difference between うちに and うちから](https://japanese.stackexchange.com/questions/42075/difference-between-%E3%81%86%E3%81%A1%E3%81%AB-and-%E3%81%86%E3%81%A1%E3%81%8B%E3%82%892).
  2. The **と** is with ひらり as the adverb's particle, See: [<adv> versus <adv>+と versus <adv>+に](https://japanese.stackexchange.com/questions/1903/adv-versus-adv%E3%81%A8-versus-adv%E3%81%AB)
  3. And (most importantly) both **か** and **うちに** are part of a set grammatical structure as answered below.




VかVないかのうちに (or VかVないうちに) is a set grammatical construction.

It means here the moment where it's not clear whether he hit the ground or not
because it happened so fast.

So it's "at the very instant he hit the ground, he bounded back up into the
sky"

(see <http://japanesetest4you.com/flashcard/learn-
jlpt-n2-grammar-%E3%81%8B%EF%BD%9E%E3%81%AA%E3%81%84%E3%81%AE%E3%81%86%E3%81%A1%E3%81%AB-
kanai-no-uchi-ni/> for instance).

