I seem to recall from previous experiments that the order in which gem windows flash is based on the order in which the cut gems were created - if you cut a ruby, then an emerald, then a sapphire, then make them into a window, it will blink in one order, but if you cut them in the opposite order, then it'll blink in the opposite order.
Searching forums...
http://www.bay12forums.com/smf/index.php?topic=57265.msg1252432#msg1252432
"The gems are gathered based on which ones existed first, which then determined the order they flash in. By forbidding the old ones and cutting the new ones, I got then to all flash together"
"Dwarves will not begin construction on a gem window unless they can path to all the materials they need" [so you can't unforbid the gems in order]
"Now, you can (obviously, given the above) to some degree control the gem existence order- If you cut the gems in the order you want them, then they will have begun their new existence in the right order. But if you are buying cut gems, then the only thing you know is that the gems you cut after the traders arrive will be newer than the traders' gems, which will in turn be newer than gems that were cut before they arrived."
Nice find! Thank you. Also thanks a bunch to ZetaX for his invaluable contribution of invalidating my incorrect hypothesis about gem-blinking.
This method of controlling the gem-blinking seems difficult to pull-off, since it will require near total pre-planning of your project.
So...
Storing all gems as uncut, then preparing freshly cut-in-order batches of gems for windows that are meant to blink at the same time, right?
That would be my assumption. I guess you'd do 3 windows of the same type at a time, by cutting 9 gems (3 of each color) every time you want to make a window. Alternately, you could actually do larger batches if you made sure that the gems were cut in the right order.
I think the best way would be to plan-out your design ahead of time and determine the different "groups" of gem windows you would need for different parts of the image (groups of windows that will all blink identically), then choose one to start with (group 1), cut all the #1 gems for them, then cut all the #2 gems for it, and then all the #3 gems, and then build all of that set of identical windows. Now you can start Group 2!!!
The "travelling dot" effect requires 3 different gem-groups. The plan I dreamt up of "a hammer striking an anvil with sparks coming off" will probably require 8 groups. (Background, the anvil, the hammer in position1, hammer in position2, hammer in position3, overlap between position1 and 2, overlap between position2 and 3, and then finally the sparks.)
edit: I have modified the first post to now contain largely correct information. It looks like an ugly mess now though.