GUI Designer Pop-up and Floating Window User Manual

freeFree Technical Resource

This content is free to read, suitable for basic learning and search traffic.

GUI Designer Pop-up and Floating Window User Manual

1. Introduction to Pop-up and Floating Windows

Both pop-up and floating windows are displayed as small windows, serving as prompts or for other purposes, and float above the original window. (Note: Differences between Floating and Pop-up Windows

When clicking other blank areas, floating windows will not automatically close, while pop-up windows will.)

2. How to Add a Window

Open or create a new project file, click the window icon in the Common Controls module to add a window. Modify the window name according to the prompt, as shown in Figure 2.1.

GUI Designer Pop-up and Floating Window User ManualFigure

Figure2.1 Add Window

3. How to Set the Position and Size of a Window

Select the added window, NEW2, and modify its size using the mouse or the Public Properties window on the right, as shown in Figure 3.1.

GUI Designer Pop-up and Floating Window User ManualFigure1

Figure3.1 Modify the Position and Size of the Window

4. How to Set the Mis-Touch Prompt Window via Pop-up/Floating Window

Click the Exit button in window, NEW1, to pop up a prompt window, Prompting, asking whether to exit the interface. Click OK to close the pop-up window and switch to the main interface, main, or click Cancel to close the pop-up window and return to window, NEW1.

1How to add a window

Add two windows and set their names to "main" and "Prompting", respectively. The specific steps are as above, and will not be repeated here. See Figure 4.1.

GUI Designer Pop-up and Floating Window User ManualFigure2

Figure4.1 Add window

2How to set the size and position of a window

Select the "Prompting" window and set its position and size. The specific setting methods and operations are as above, and will not be repeated here. See Figure 4.2.

GUI Designer Pop-up and Floating Window User ManualFigure3

Figure4.2 Set the position and size of the window

3How to add a control

Select window "NEW1" and add a button control in window "NEW1" to serve as the exit button. Add a text control and two button controls in the "Prompting" window. The text control displays the prompt, and the two button controls are the "Confirm" and "Cancel" buttons, respectively. See Figure 4.3.

GUI Designer Pop-up and Floating Window User ManualFigure4

Figure4.3 Add control

Note: The specific text settings for button controls and text controls will not be repeated. For details, please refer to the "Button Control User Manual" and the "Text Control User Manual".

4How to set the window"NEW1"Button Event

Click the button in window NEW1, click on "Events" in the property window on the right, click "Add", set the event to "Click", click the "..." under the handling method to pop up the handling method window, select "Display Pop-up Window" or "Display Floating Window" (here, the display of a pop-up window is exemplified) in the window switching section, and select the "prompting" window as the target window, as shown in Figure 4.4.

GUI Designer Pop-up and Floating Window User ManualFigure5

Figure4.4 Set Event

5and How to Set WindowpromptingButton Event

Click the "Confirm" button in the prompting window, click "Events" in the property window on the right, add two events, set both events to "Click", select "Close Window" in the window switching section for the handling method, set the target window to "prompting", and select "Switch Window" in the window switching section for the other handling method, with the target window being "main". The specific setting method is the same as above and will not be repeated here. See Figure 4.5.

GUI Designer Pop-up and Floating Window User ManualFigure6

Figure4.5 Confirm Button Event Settings

Click the "Cancel" button in the prompting window, click "Events" in the property window on the right, add an event, set the event to "Click", click the "..." under the handling method to pop up the handling method window, select "Close Window" in the window switching section, set the target window to "prompting", as shown in Figure 4.6.

GUI Designer Pop-up and Floating Window User ManualFigure7

Figure4.6 Cancel Button Event Settings

6and Simulation Demonstration

Click the "Simulation Demonstration" buttonGUI Designer Pop-up and Floating Window User ManualFigure8, and the simulation running window will pop up

Click the "Exit" button in window "new1" to pop up a prompt window, as shown in Figure 4.7.

GUI Designer Pop-up and Floating Window User ManualFigure9

Figure4.7 Click the "Exit" button.

Click the "Confirm" button in the pop-up box to close the pop-up window and switch to the "main" window, as shown in Figure 4.8.

GUI Designer Pop-up and Floating Window User ManualFigure10

Figure4.8 Switch to themain window.

Click the "Cancel" button to close the pop-up window and return to window "NEW1", as shown in Figure 4.9.

GUI Designer Pop-up and Floating Window User ManualFigure11

Figure4.9 Switch to window"NEW1" Middle

Related Tags
Put this resource to use in a real project?

Go to the Tool Center for message parsing, CRC verification and device debugging, or submit your requirements for selection and integration advice.

Engineer Membership

Turn this article into actionable debugging resources

After activation, you can use advanced message parsing, resource pack downloads, code examples, engineering cases and priority technical support, suitable for real project delivery.

Unlimited Advanced Tools
Resource & Code Packs
Complete Engineering Case Library
Priority Technical Support

Leave a Reply

Your email address will not be published. Required fields are marked *.