Box surrounding a word


Author
Message
Ali
Ali
Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)
Group: Forum Members
Posts: 26, Visits: 194
Exactly what I needed! Thanks!
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 108K
What you need to do is define proper /size, /position, /txbgcolor etc. for the <text> elements in the foreground. Then a single, simple rectangular <shape> in the background is enough. Example:

<text a>
/ items = ("Foo Bar Baz")
/ txcolor = (white)
/ txbgcolor = (black)
/ size = (25%, 0.25px*display.width)
/ position = (50%, 50%)
/ vjustify = top
</text>

<text b>
/ items = ("Foo")
/ txcolor = (white)
/ txbgcolor = (transparent)
/ size = (25%, 0.25px*display.width)
/ position = (50%, 50%)
/ vjustify = center
</text>

<text c>
/ items = ("Foo Bar Baz")
/ txcolor = (white)
/ txbgcolor = (transparent)
/ position = (50%, 50%)
/ size = (25%, 0.25px*display.width)
/ position = (50%, 50%)
/ vjustify = bottom
</text>

<shape bg>
/ color = (blue)
/ size = (26%, 0.26px*display.width)
/ position = (50%, 50%)
</shape>

<trial mytrial>
/ stimulusframes = [1=bg,a,b,c]
/validresponse = (57)
</trial>


Ali
Ali
Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)
Group: Forum Members
Posts: 26, Visits: 194
Hello Dave. Thanks for the tip. 
I tried it but the result turned out aesthetically unappealing (see attached screenshot, right box). So I came up with a 'low-tech' way to design a box (see .iqx attached). I wonder if there is a more high-tech way to prepare this type of  square more efficient. 

Attachments
screenshot.jpg (529 views, 169.00 KB)
Implicit PPL.iqx (517 views, 25.00 KB)
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 108K
See e.g. https://www.millisecond.com/forums/Topic3223.aspx (applies to <text> elements as well).

Ali
Ali
Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)Guru (5.5K reputation)
Group: Forum Members
Posts: 26, Visits: 194
Hello. I'm trying to draw a box. I need it to be either transparent or just borders--so that it does not hide words behind/in it. 

The documentation says the shape element can be used "for drawing background to be presented behind other stimuli." But I did find how. It keeps covering other stimuli. Any help? Thanks! 

Best, 

Ali


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search