Text Area position issue in R2022b version

2 Ansichten (letzte 30 Tage)
Joris PERROT
Joris PERROT am 24 Jan. 2023
Kommentiert: Joris PERROT am 20 Mär. 2023
Hello,
I designed an app using the Design View in Matlab r2022a version with especially a Text Area with its associated Label ("Rejection :"). Here is the view of the Design View :
When I run the program, there is no problem to notice and the app is working well with the good design as it can be seen on the following picture:
This time, with matlab r2022b version, the Design View is the same but when I Run the program to use the app, some issue appears :
Indeed, the Text Area and the Label is not at the good place and when I change the Position variables 'bottom' and 'height', nothing is changing. We can see also some little position issues in the left hand side parameteres (boxed in red).
I thanks you in advance for your help :)
  2 Kommentare
Adam Danz
Adam Danz am 16 Mär. 2023
This is difficult to troubleshoot without having access to the app.
You could contact tech support and include instructions how to reproduce the problem or you could attach the app here and I could take a shot at investigating.
Joris PERROT
Joris PERROT am 16 Mär. 2023
Firstly, thank you for your answer !
I attached to this comment an example of this issue. I just put a Text Area in a 2-Panel App with a dimension fixed in the Design View.
When I Run the app (without any code inside), the Text Area is no longer the right size in version R2022b.
There was not this problem in R2022a.

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Adam Danz
Adam Danz am 19 Mär. 2023
Bearbeitet: Adam Danz am 19 Mär. 2023
Thanks for reporting this issue.
A workaround until it is fixed is to apply a grid layout to the right panel in R2022b (or later).
  1. Back up a version of your app before these making changes. If you intend to use the app in older releases of MATLAB some functionality may not be supported depending on what's in your app.
  2. Open the app in R2022b or later.
  3. Right click the panel. Grid options will appear.
  4. Save the app.
  3 Kommentare
Adam Danz
Adam Danz am 20 Mär. 2023
You can customize the grid layout to fit your needs.
Here's a documentation article on using grid layout managers
Here's a list of properties you can set
While investigating the simplified app you attached to a comment in this thread, I noticed that the position of the text box changes after the text box is initialized and after the startup command runs. In that case, one potential workaround would be to record and re-assign the position of the text box in your startup function which doesn't rely on a grid layout.
Within your startup function add this,
pos = app.RejectionTextArea.Position;
app.RejectionTextArea.Position = pos;
Joris PERROT
Joris PERROT am 20 Mär. 2023
Thank you very much for your quick response !

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Develop Apps Using App Designer finden Sie in Help Center und File Exchange

Produkte


Version

R2022b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by