Reply To: Variable fixation dot position

PennController for IBEX Forums Support Variable fixation dot position Reply To: Variable fixation dot position


Hi Ana,

Are you trying to align ... with the start of the SPR sentence? If so, since you use a mono-spaced font to display the SPR sentence, you can simply pass a string of the same length to the three-dot Text element and it will be the exact same size as the SPR sentence, so if you print it at the same coordinates, they will be perfectly aligned. The trick is to make that string start with ... and render all remaining (dummy) characters invisible, eg:

// dots 1_1
newText("start1_1", "...<span style='visibility: hidden;'>"+
                    [ Array(variable.context.length-3)].map(v=>'_').join('')+"</span>")
    .print("center at 50%", "middle at 50%")
// Keep the dots in place for about a second 
newTimer("start1_1_timer", 1000).start().wait()
// Remove the dots
// context sentence
newText ("read_ctxt","Lies bitte den ersten Satz und drücke die Leertaste um fortzufahren")
    .css({"font-size":"15px","font-family":"times new roman"})
    .print("center at 50%", "middle at 46%")
// context sentence in SPR
...cumulative_ctxt(variable.context, "remove")