Compiler Question - Figure Docking

6 ビュー (過去 30 日間)
Ian Straits
Ian Straits 2022 年 4 月 19 日
回答済み: Yair Altman 2022 年 10 月 27 日
Hi,
I have a project I am doing where I created a game and the user plays through the command window and the display is a figure which is automatically docked and the user can play live on the screen. I want to export this file to a .exe but when I do the figure docking goes away and I cant play it while also typing in command window. Is there a way to keep figures docked once I compile the program?

採用された回答

Yair Altman
Yair Altman 2022 年 10 月 27 日
The Matlab Desktop is not available in compiled application, and for a very good reason - otherwise users could compile and distribute a free program that mimics Matlab. Therefore, you cannot compile something that looks like the Matlab Desktop, with integrated console and figures in the same window. There is a technical way to dock figures in deployed programs, but it will be to a separate figures window, which is separate from the console.
I suggest that you modify your program so that all user interaction is done in a single (non-docked) figure window that has 2 panels: one panel displays the graphics results of your program; the other panel accepts user input text and interaction. This unified figure GUI can then easily be compiled and will work the same way when you deploy it as a standalone executable.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeEnvironment and Settings についてさらに検索

製品


リリース

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by