If this template helps then use it. If not then just delete and start from scratch.
OS (e.g. Win10): Win 10-10.0.19041-SP0
PsychoPy version (e.g. 1.84.x): PsychoPy 2020.2.4
Standard Standalone? (y/n) standalone
What are you trying to achieve?:
I want to present text set in a Text Component centered in the window and have it wrap according to the value set in the advanced tab of the Text Component, when using pygame as the graphics driver.
Apologies if this has been asked before, I was not able to find a similar question in the forum.
Thanks in advance for any assistance.
What did you try to make it work?:
This worked as expected when using pyglet as the driver, but a recent graphics card replacement has broken compatibility with pyglet (experiment stalls at startup; this is an ancient machine and the problem relates to OpenGL compatibility, I don’t think I can solve that, thus I am focused on solving the problem described here).
On switching to pygame, text is now rendered with a different interpretation of the co-ordinate system (1) and not wrapping (2).
(1) I am using ‘norm’ as the units throughout but text is left justified to the specified x co-ordinate, as opposed to centered, as it was with pyglet. Other components are spared and render at the expected locations in the window (i.e. 0,0 for a shape component places the center of the shape at the center of the window, not the bottom left hand corner of the shape)
(2) Text wrapping fails - text is rendered on one line. Attempting to impose “forced” wrapping by spreading text in the Text Box of a Text Component across multiple lines fails - text is still rendered on one line and the line-breaks are rendered as empty rectangles on that line.
I would like to continue to be able to use builder, as this experiment is intended to be modified by students who are not (yet) programmers.
What specifically went wrong when you tried that?:
Include pasted full error message if possible. “That didn’t work” is not enough information.
No error message to report, screen grabs are attached for illustration.