so when you get to where you need to cast on, in this example, it's a button hole.
you loop it around your thumb, like so
then you slide the right hand needle in front of the yarn, and behind your thumb, pull the working yarn tight, and zip your thumb out.
pull the loop tight-ish, and close to the working stitches. you'll have to finesse this a little bit, you don;t want the stitch to strangulate the needle, but it shouldn't be too loose.
you keep repeating it until you get the number of stitches you need.
now, a word about the number you'll need, i like to cast on two stitches more than the number i'll need, then on the subsequent row, i knit two together one on each end, to make the fabric a little neater.