Never tried writing any scripts for the real time data- I have SSplus so 15 mins delayed (when i can use it)
The immediate way i can think would be to write a script to check the open price (there is a getOpen() function) the only thing I am not sure of is if this would work on the real time data. I am not sure if SS stores this data inthe same place as the end of day data such that the function would "see" it.
I might give it a go see if I can get something working on mine in the 15 mins delayed- the principle is the same. You would want to check the open against the previous close.
Only issue beyond this I can see is that the gap is effectively between the Opening selling price (bid) As its the lower of the bid/ask and the previous days close. I'm not sure if the re is a function that can pull out this level of detail- ie the bid rather than the mid price.