Stardust

A village lies near a gap in a stone wall bordering the magical kingdom of Stormhold. The gap is guarded constantly, but Dunstan Thorn manages to go through and meets an enslaved princess, Una. She offers him a glass snowdrop in exchange for a kiss, then invites him on her trailer. Nine months later, the Wall Guard delivers a baby to Dunstan, saying his name is Tristan.
Eighteen years later, the dying king of Stormhold throws a ruby into the sky, decreeing that his successor will be the first of his fratricidal sons to recover it. The gem hits a star, they fall together, and the remaining sons, Primus and Septimus, independently search for the gem.
In Wall, Tristan sees the star fall and vows to get it for the object of his infatuation, Victoria, in return for her hand in marriage. Tristan learns that his mother is from beyond the wall, and receives a Babylon candle that she had left for him, which instantly takes the user to any desired location. Tristan lights it and is transported to the fallen star, personified as a beautiful woman named Yvaine. He promptly chains her to take her home to Victoria.
Three ancient witch sisters in Stormhold resolve to eat the fallen star's heart to recover their youth and replenish their powers. Their leader, Lamia, eats the remnants of an earlier star's heart, and sets off to find Yvaine. She conjures up a wayside inn as a trap.
Yvaine becomes tired, so Tristan chains her to a tree and promises to bring food. In his absence, a unicorn releases her, but unwittingly takes her to Lamia's inn. Tristan discovers Yvaine gone, but the stars whisper that she is in danger, telling him to get on a passing coach, which happens to be Primus's. At the inn, they interrupt Lamia's attempt to kill Yvaine. Lamia kills Primus, but Tristan and Yvaine use the Babylon candle to escape into the clouds, where they are captured by pirates in a flying ship, who teach Tristan how to fence.
Septimus discovers that, as the last surviving son, he need only find the stone to claim the throne. He learns it is in the possession of the fallen star and realizes that the heart of a star grants immortality.
After leaving Captain Shakespeare's ship, Tristan and Yvaine confess their love for one another and spend the night together at an inn. Come morning, Tristan leaves Yvaine sleeping and goes to Wall with a lock of her hair, to tell Victoria he will not marry her, having fallen in love with Yvaine. When the lock turns to dust, he realizes Yvaine will die if she crosses the wall, and rushes back to save her.
Yvaine finds Tristan gone, and starts walking towards the wall, thinking he has abandoned her for Victoria. Tristan's mother Una notices Yvaine walking to her doom, so takes the caravan of her enslaver, a witch named Ditchwater Sal, to the wall to stop her. Lamia arrives, kills Sal, and captures Una and Yvaine, taking them to the witches' castle. Septimus and Tristan both pursue Lamia, agreeing to work together for the time being. Barging into the castle, Septimus recognises the princess as his long-lost sister and Una informs Tristan that she is his mother.
Septimus and Tristan kill two of the witches, but Lamia uses a voodoo doll to kill Septimus and make his corpse fight Tristan. Lamia is about to finish Tristan off, when she appears to break down over the loss of her sisters. Lamia frees Yvaine, but her feigned defeat was just a ruse to bolster Yvaine's broken heart. As Tristan and Yvaine embrace, their love allows her to shine once again, vaporising Lamia in a blinding flash of starlight.
Tristan retrieves the jewel that Yvaine was wearing. As the jewel turns red, Una explains that, as her son, Tristan is the last male heir of Stormhold. He becomes king with Yvaine as his queen while Dunstan and Una are reunited. After 80 years of ruling Stormhold, they use a Babylon candle to ascend to the sky, where Tristan also becomes a star and the pair lives forever in the sky.

Question: What does the king throw into the sky?
Answer: Ruby