Coordinate system moved after widgets were loaded #5454
Replies: 1 comment
-
Posted at 2022-12-11 by HughB Having you tried something like:
I see the text displayed in the same place regardless. I loaded the above code into RAM from the IDE. Attachments: Posted at 2022-12-11 by user148386 I added the extra load between the drawString methods but with no success. I did some extra testing and i found out that it dose not happen for every widget. I had the widget "A Battery Widget (with percentage)" and it happend there after the redraw. However i mangaed to reproduce the same error with a simple
command. Here is the example code
I noticed there, that the font size of the text was changed to that of the shown message. But even if i set it to a lower one, it is still moved to the left. Posted at 2022-12-12 by HughB Can you show a screenshot of what you see? Go to the IDE, type Posted at 2022-12-12 by user148386 Here is the screenshot of the screen Attachments: Posted at 2022-12-12 by HughB Lines 4 and 8 will draw in the same place, and it looks like they do. ShowMessage is different to drawstring. You might need to set the left alignment up. Posted at 2022-12-12 by @gfwilliams The issue is you need to call Even if you were lucky and the font stayed the same, maybe the battery widget decided to update the battery and leaves the foreground colour as green :) Posted at 2022-12-12 by user148386 That solved the problem, thanks. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2022-12-11 by user148386
Hi everyone,
when i run into a error, that the coordinate system moved when i load the widegets with
Before i run this line, i can draw a string at 0,0. If i run the same draw command after i loaded the widegts the string is moved to the top left out of the screen. Do you know what the problem could be?
Here is an example code.
Beta Was this translation helpful? Give feedback.
All reactions