Millisecond Forums

IAT Instruction Pages

https://forums.millisecond.com/Topic33616.aspx

By devin698260 - 12/14/2021

Hello, 

I am looking for help editing an IAT script/adapting it for mobile devices. I've uploaded a screenshot- I'm having trouble with the instruction pages. I would like each instruction page to have the directions centered and large enough to be read on a mobile device. However, the instruction pages keep looking like the attached image. 
<text instructions>
/ items = instructions
/ position = (50%,50%)
/ halign = left
/ valign = bottom
/ hjustify = left
/ vjustify = center
/ size = (25%, 25%)
/ select = values.instructionIndex
</text>

<trial instructions>
/ ontrialbegin = [
    values.progresswidth += 10;
    values.instructionIndex += 1;
]
/ stimulustimes = [1=instructions, spacebar, progressbar, progressbar_fill]
/ correctresponse = (" ")
/ errormessage = false
/ recorddata = false
/ showmousecursor = true
</trial>

<trial finish>
/ recorddata = true
/ stimulusframes = [1 = finish, exit]
/ validresponse = (" ")
</trial>

These are my current instruction settings (I've also tried editing the defaults) and have had no luck changing the position/size/alignment. Please let me know if you have any guidance, thank you!

By Dave - 12/14/2021

devin698260 - 12/14/2021
Hello, 

I am looking for help editing an IAT script/adapting it for mobile devices. I've uploaded a screenshot- I'm having trouble with the instruction pages. I would like each instruction page to have the directions centered and large enough to be read on a mobile device. However, the instruction pages keep looking like the attached image. 
<text instructions>
/ items = instructions
/ position = (50%,50%)
/ halign = left
/ valign = bottom
/ hjustify = left
/ vjustify = center
/ size = (25%, 25%)
/ select = values.instructionIndex
</text>

<trial instructions>
/ ontrialbegin = [
    values.progresswidth += 10;
    values.instructionIndex += 1;
]
/ stimulustimes = [1=instructions, spacebar, progressbar, progressbar_fill]
/ correctresponse = (" ")
/ errormessage = false
/ recorddata = false
/ showmousecursor = true
</trial>

<trial finish>
/ recorddata = true
/ stimulusframes = [1 = finish, exit]
/ validresponse = (" ")
</trial>

These are my current instruction settings (I've also tried editing the defaults) and have had no luck changing the position/size/alignment. Please let me know if you have any guidance, thank you!


<text instructions>
/ items = instructions
/ position = (50%,50%)
/ halign = left
/ valign = bottom
/ hjustify = left
/ vjustify = center
/ size = (25%, 25%)
/ select = values.instructionIndex
</text>

/size is  way too small to hold all that text, plus it seems you've chosen some huge size for the font. Also, with /halign = left, the element's position is relative to the left border of its bounding rectangle, i.e. it's not centered.

https://www.millisecond.com/support/docs/v6/html/language/attributes/halign.htm