Dynamically expandable development method and system for user interface based on software platform

The method dynamically extracts type information from the software platform's execution library to form a derived base window, enabling users to customize and extend existing windows and create new controls, addressing limitations in existing platforms and enhancing user interface development efficiency.

JP2025107958AActive Publication Date: 2025-07-22SHANGHAI TOSUN TECH LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
JP2024105830
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-01-09
Filing Date
2024-06-30
Publication Date
2025-07-22
Estimated Expiration
2044-06-30

AI Technical Summary

Technical Problem

Existing software platforms for secondary development of user interfaces restrict users to developing only with provided empty windows and control lists, limiting creative design and functionality, as they cannot extend existing windows or create new controls from scratch.

Method used

A method and system that dynamically extracts type information from the software platform's execution library to form a dynamically derived base window, allowing users to inherit and extend existing windows and create new controls without modifying the platform code, using an interface manager to generate and store introduction code for dynamic window creation.

Benefits of technology

Enables flexible and efficient user interface development by allowing users to customize and extend existing windows, adding new functions and controls, enhancing the user interface's creativity and functionality without recompiling the software platform.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2025107958000001_ABST
    Figure 2025107958000001_ABST
Patent Text Reader

Abstract

To provide a method and system that belongs to the field of vehicle software development technology, and more specifically, relates to dynamically expandable development method and system for a user interface based on a software platform.SOLUTION: The method for dynamically expandable development of a user interface based on a software platform includes the followings. During the execution of the software platform, type information about a window in an execution library of the software platform is dynamically extracted by an interface manager, the type information is inherited to form a dynamic derived base window, and a software platform introduction code is generated simultaneously by the interface manager. A one-time window dynamic creation code is generated based on the type information in the software platform introduction code, and the software platform introduction code and the one-time window dynamic creation code are stored once in a derived code file.SELECTED DRAWING: Figure 1
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application claims the Chinese Patent Application No. 202410028558.4 filed on January 9, 2024 based on priority, and all its contents are incorporated herein by reference.

[0002] The present invention belongs to the technical field of vehicle software development, and specifically relates to a dynamically extensible development method and system for user interfaces based on software platforms.

Background Art

[0003] Currently, the commercially available software platforms for secondary development of user interfaces only allow development using the empty windows and control lists provided to users. For example, the user can use the method of dragging to drag the control from the list to the empty window, set the attributes, create event codes related to the control events, and complete the extended development.

Summary of the Invention

[0004] The present invention relates to a method and a system, including the following. During the execution of the software platform, the interface manager dynamically extracts type information related to windows in the execution library of the software platform, and forms a dynamically derived base window by inheriting the type information. At the same time, the interface manager generates the introduction code of the software platform. Also, based on the type information in the software platform introduction code, the code for creating a window dynamically once is generated, and the software platform introduction code and the code for creating a window dynamically once are stored in a derived code file once.

[0005] Other features and advantages of the present invention will be described in the following specification, and some will be apparent from the specification or understood by practicing the present invention. The objects and other advantages of the present invention are realized and obtained by the structure particularly pointed out in the specification and drawings. In order to make the above objects, features, and advantages of the present invention more understandable, the following provides preferred embodiments and, in conjunction with the accompanying drawings, will be described in detail.

Brief Description of the Drawings

[0006] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions of the prior art, the following briefly describes the drawings that need to be used in the description of the specific embodiments or the prior art. The drawings described in the following description are some embodiments of the present invention, and it is obvious that those skilled in the art can obtain other drawings from these drawings without creative efforts.

Figure 1

Figure 2

Figure 3

Figure 4

Figure 5

Figure 6

Figure 7

Figure 8

Figure 9

Figure 10

Embodiments for Carrying Out the Invention

[0007] To make the objectives, technical aspects and advantages of the embodiments of the present invention clearer, the technical aspects of the present invention will be clearly and completely described below in connection with the accompanying drawings. It is obvious that the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the invention, all other embodiments obtained on the premise that those skilled in the art do not perform creative labor belong to the protection scope of the invention.

[0008] Currently commercially available software platforms for secondarily developable user interfaces only permit development using the empty windows and control lists provided to the user. For example, the user can, by means of the drag method, drag a control from the list to the empty window, set attributes, associate with control events, create event codes, and complete the extended development. In such an extension method, the user can only use the empty windows and limited controls provided by the software platform, and cannot perform extended development based on existing windows of the software platform, such as a graphic drawing window or a system message window. Nor can new controls not belonging to the control list be designed from scratch. Such an extended design of the user interface is greatly restricted by the software platform itself, and the resulting result is that the designed user interface pattern is single, the controls are simple, the functions are simple, and more creative designs cannot be realized.

[0009] Therefore, at least one embodiment provides a method for dynamically extending a user interface based on a software platform. This method includes the following. During the execution of the software platform, the interface manager dynamically extracts type information related to windows in the execution library of the software platform, and forms a dynamically derived base window by inheriting the type information. At the same time, the interface manager generates software platform introduction code. Also, based on the type information in the software platform introduction code, code for creating a window dynamically once is generated, and the software platform introduction code and the code for creating a window dynamically once are stored in a derived code file once.

[0010] Hereinafter, various non-limiting embodiments of the examples of the present disclosure will be described in detail in relation to the accompanying drawings. As shown in FIG. 1, some embodiments provide a method for dynamically extending a user interface based on a software platform. This method includes the following. In step S101, during the execution of the software platform, the interface manager dynamically extracts type information related to windows in the execution library of the software platform, and forms a dynamically derived base window by inheriting the type information. At the same time, the interface manager generates software platform introduction code. In step S102, based on the type information in the software platform introduction code, code for creating a window dynamically once is generated, and the software platform introduction code and the code for creating a window dynamically once are stored in a derived code file once.

[0011] In some embodiments, when performing N+1 derived modifications on the attributes of the dynamic derived base window and / or call events, create an N+1 derived code file. The above N+1 derived code file includes N derived code file introduction codes, N+1 window dynamic creation codes and / or user codes. Here, N≧1. The N+1 derived code file is executed, and a user interface for N+1 derivation is formed.

[0012] In some embodiments, during the execution of the software platform, the step of the interface manager dynamically extracting type information related to the window in the software platform execution library includes the following. Introduce an RTTI (Run-Time Type Information) unit. That is, before using the RTTI unit, it is necessary to introduce the system run-time type information (such as `System.Rtti`) unit into the code inside the software platform, and use the classes and methods related to the above window in the RTTI unit. Create a context object using the "run-time type information context type" (such as `TRttiContext`) class in the system run-time type information unit, and further obtain the "run-time type information" (such as `TRttiType`) object of the window by the "run-time type information type acquisition" (such as `GetRttiType`) method. From the "run-time type information" (such as `TRttiType`) object of the window, obtain the property information of the window using the "property acquisition" (e.g., `GetProperties`) method, and obtain the method information of the window using the "method acquisition" (such as `GetMethods`) method.

[0013] During the execution of the software platform, this embodiment dynamically extracts type information related to windows in the execution library of the software platform, and forms a dynamically derived base window by inheriting the above type information, thereby realizing dynamic derivation. It should be noted that dynamic derivation means that during the execution of a program, each type information of the basic window in the program's execution environment is dynamically extracted, and based on these basic window type information, new window types are dynamically created. These new window types are derived from the above-extracted basic window types, and new window objects can be created using these new window types. Compared with static derivation, dynamic derivation can create objects dynamically, call methods dynamically, access attributes dynamically, realize dynamic type conversion and compatibility checking, traverse enumeration and set types, and customize attributes. That is, dynamic derivation can realize more flexible and dynamic programming, and the code has higher extensibility and maintainability. Applying the dynamic extension development method of this embodiment to the development of the user interface of the software platform, the user can realize the extension development of the existing windows of the software platform without modifying the software platform code and without calling the compiler to compile the software. The developed window not only has various functions given by the software platform to the window, but also is a dedicated window highly customized by the user, which makes the development of the user interface based on the software platform more efficient and concise.

[0014] Specifically, dynamic extraction refers to the type information of a window dynamically extracted from the execution environment during program execution (in this embodiment, the window in the execution library of the software platform). If dynamic extraction is required, the program is required to have an RTTI mechanism. The explanation of the RTTI mechanism is as follows. RTTI (Run-Time Type Information) is a mechanism for obtaining type information related to program execution. It can obtain detailed information such as classes, interfaces, methods, and attributes at runtime, including names, types, access modifiers, etc.

[0015] Specifically, the type information of the window is the basic information of the window itself in the execution library of the software platform, such as the type name information of the window, parent class information, attribute information, method information, field information, constructor and destructor information, interface information, enumeration information, etc.

[0016] As shown in Figure 2, the above interface manager is used for creation, listing, design, saving, import, export, encryption, and execution of the user interface, thereby realizing comprehensive management of the designed user interface.

[0017] The process by which the interface manager dynamically extracts the type information related to the window in the execution library of the software platform (step) is as follows. By calling the acquisition type function in the context object provided to the "system runtime type information" unit, the type information related to the window in the execution library of the software platform is obtained.

[0018] Based on the obtained type information, further information such as fields, attributes, and methods related to the window is obtained. The methods of inheritance and derivation are as follows. Based on the obtained window information, a new derived window type is defined. That is, it is a dynamic derived base window, which is used to inherit window-related type information in the software platform execution library. The dynamic derived base window can call the protected and public methods of the window-related type information in the inherited software platform execution library, can read and write its attributes, and can read and write its fields, etc. Based on the further defined dynamic derived base window, the software platform allows the user to add new fields, methods, and attributes to the dynamic derived base window and controls the behavior of the dynamic derived base window. Thereby, based on the type information related to the software platform window obtained thereby, the functions of the new window are dynamically inherited to realize the derived formation.

[0019] In the following example, during the execution of the software platform, the method by which the interface manager dynamically extracts the window-related type information in the execution library of the software platform and forms a dynamic derived base window by inheriting the type information will be described in detail. Perform dynamic derivation on the base window of the software platform to form a new window type, thereby creating a new window object. That is, the new window object is a dynamic derived base window. The following several steps are required. 1. Introduction of the RTTI unit. Before using the RTTI unit, it is necessary to introduce the `System.Rtti` unit into the code inside the software platform, and use the classes and methods related to the base window in the RTTI unit. 2. Acquisition of window-type information: Create a context object using the `TRttiContext` class, and further obtain the `TRttiType` object of the base window by the `GetRttiType` method. The corresponding `TRttiType` object can be obtained by the type name or instance of the base window. 3. Extraction of window attributes and method information: Through the `TRttiType` object of the base window, use the `GetProperties` method to obtain the attribute information of the base window, and use the `GetMethods` method to obtain the method information of the base window. Traverse the attribute and method lists of the base window to obtain information such as the name and type of the base window attributes, and information such as the name and parameters of the base window methods. 4. Dynamically create a first-level derived type based on the extracted type information, inherit the extracted base window type information, thereby forming a window subtype, and obtain the above-mentioned dynamically derived base window after instantiating the window subtype. Store the software platform introduction code generated in the process of forming the dynamically derived base window and the first-level window dynamic creation code generated based on the type information in the software platform introduction code in the first-level derived code file.

[0020] As shown in FIG. 3, the left side of FIG. 3 is the content of the saved once-derived code file. Among them, frmTSForm is the basic window type of the software platform, and new_ is the window subtype after being once-derived from the basic window type. The right side in FIG. 3 is the dynamically-derived base window obtained after instantiating the window subtype new_. Since it inherits the base window type frmTSForm, it can be seen that the new dynamically-derived base window has a plurality of buttons 10 at the upper right corner of the toolbar and a pull-down menu included in the base window type, and has the functions of corresponding button click events and pull-down menu operation events.

[0021] In some embodiments, the user code is the code created by the user. The once-derived code file is derived based on the construction language of the software platform and forms the existing content of the software platform. Therefore, the once-derived code file cannot be edited and does not contain user code. When making derived modifications to the attributes and / or call events of the dynamically-derived base window, the user can modify the attributes and / or call events of the dynamically-derived base window by means of writing code, so that the N + 1 derived code file can contain user code.

[0022] In some embodiments, the user can further modify the attributes and / or call events of the dynamically-derived base window by adding callable controls to the dynamically-derived base window. The setting of the callable controls forms a control list after the software platform system summarizes the user's usage habits. As shown in the right area of FIG. 4, the controls in the control list are called callable controls. The user can embed these callable controls into the dynamically-derived base window by dragging them from the control list, but it is not limited to this.

[0023] In some embodiments, after the derived action is completed, the corresponding derived code file can be executed to form a derived user interface, which is used for the user to perform interface interaction.

[0024] In some embodiments, the software platform introduction code may be in the Python code language and include "from software platform name import *" or "import software platform name".

[0025] In some embodiments, the software platform introduction code may further be in the C or C++ code language and include "#include "software platform name"".

[0026] As an example, forming a dynamic derived base window by inheriting the above type information will be described in detail. Also, the specific process of performing derived modifications on the attributes and / or call events of the dynamic derived base window is as follows. In the type information of the base window, if the window type is TForm, the user of the software platform can use the window design tool provided by the software platform, inherit the window type TForm, form a window subtype TBaseForm, and after instantiating the window of this subtype, form the above dynamic derived base window. Add a top-display help button to the dynamic derived base window, that is, embed a button control in the dynamic derived base window. Subsequently, if the user of the software platform clicks the code generation button in the window design tool, the window dynamic creation code of the dynamic derived base window and the corresponding control creation code can be obtained. class TBaseForm(TForm): def __init__(self): self.btnHelp = Button(self) self.btnHelp.Parent = self self.btnHelp.Align = "alTop" self.btnHelp.Caption = 'Help' Here, "def __init__(self):" creates an event function definition for the window and modifies its attributes by automatically calling the event. In the above example, the value is assigned to the dynamically derived base window attribute "btnHelp" using the button generation function "Button(self)". Subsequently, the button control attribute "Parent" is set to this dynamically derived base window to display the button control in the dynamically derived base window. Subsequently, the button control attribute "Align" is set to "alTop" to align the button control at the top of the dynamically derived base window. Subsequently, the button control attribute "Caption" is set to "Help" so that the title of this button control is displayed as "Help", that is, help information.

[0027] As an optional implementation form of some embodiments, the above attributes include visual elements of the window and the control, and sub - members of the window and the control. The above sub - members are functional variables and / or behavioral characteristic variables of the window and the control. The above call events include one or more events among user interaction events, window and control life - cycle events, and window and control function events.

[0028] In some embodiments, the above attributes also include visual elements and sub - members of the control. The above sub - members are functional variables and / or behavioral characteristic variables of the control. The above call events include one or more events among user interaction events, control life - cycle events, and control function events.

[0029] In some embodiments, the visual elements of the window include, but are not limited to, for example, the color of the window body, the width of the window body, the height of the window body, the text information displayed within the window body, and the coordinates, transparency, icons, cursor types, etc. in the main screen of the window body. The visual elements of the control include, but are not limited to, for example, the color of the control, the width of the control, the height of the control, the text information displayed within the control, and the coordinates, transparency, icons, cursor types, etc. in the parent control of the control.

[0030] As shown in FIG. 5, the attribute entries on the right side indicate some attributes of the window.

[0031] As shown in FIG. 6, the attribute entries on the right side indicate some attributes of the control.

[0032] In some embodiments, the functional variables of the window and the control both include, but are not limited to, for example, font, drag & drop type, double buffering flag, right button menu, help file, tag value, etc. The operating characteristic variables of the window and the control both include, but are not limited to, for example, active state, visibility, alignment method, auto - adapt size, etc.

[0033] In some embodiments, user interaction events include, but are not limited to, for example, click event, cursor key press event, cursor key popup event, cursor entry event, cursor movement event, cursor exit event, keyboard press event, keyboard popup event, etc. The window and control life cycle events both include, but are not limited to, for example, creation event, discard event, etc. The window and control function events both include, but are not limited to, for example, timing event, display event, hide event, size change event, drawing event, etc.

[0034] In some embodiments, performing a derived modification on the attributes of a dynamically derived base window and / or call events (step) includes the following. Writing the attributes of the window by way of assignment and / or associating an event processing function with the call event of the window by way of assignment, and forming a call relationship with user code.

[0035] In some embodiments, performing a derived modification on the attributes of a dynamically derived base window and / or call events (step) includes the following. Writing the attributes of the control by way of assignment and / or associating an event processing function with the call event of the control by way of assignment, and forming a call relationship with user code.

[0036] Hereinafter, an example of a specific process of writing the attributes of a window in a way of assignment and forming a call relationship with user code will be described in detail. In the type information of the base window, if the window type is TForm, the user of the software platform uses the window design tool provided by the software platform, inherits the window type TForm, forms a window subtype TBaseForm, and after instantiating the window of this subtype, forms the above-mentioned dynamically derived base window. The user of the software platform can modify the Tag attribute of the dynamically derived base window to 1 in the window design tool, and then click the code generation button to obtain the code for dynamically creating the window of the dynamically derived base window. class TBaseForm(TForm): def __init__(self): self.Tag = 1 Here, "self.Tag = 1" indicates writing the Tag attribute of the dynamically derived base window by way of assignment.

[0037] In this example, the user can further modify the attributes and / or call events of the dynamically derived base window using the user code added by themselves. For example, in the user code, the user can determine the corresponding operation based on the Tag attribute of the dynamically derived base window. For example, when the Tag is 1, the user can set the title bar text of the dynamically derived base window to “Run Mode=1”. The user code is as follows: if 1 == self.Tag: self.Caption = “Run Mode = 1” Here, “if1==self.Tag:” means that the user code forms a calling relationship with the attribute “Tag” of the dynamically derived base window, calls the attribute “Tag” of the dynamically derived base window, and further determines the next operation of the dynamically derived base window.

[0038] Continuing with the above example, the specific process of associating the event processing function with the window's call event by the assignment method and forming a calling relationship with the user code will be described in detail as follows. In the user code, the user can associate the customized event processing function with the display event of the dynamically derived base window, update the title bar text of the dynamically derived base window in the display event, and the user code is as follows: def on_show(Sender): self.Caption = “Form displayed” self.OnShow = on_show Here, “def on_show(Sender):” is the event processing function customized by the user. In this function, the user resets the title bar text of the dynamically derived base window. The assignment statement “self.OnShow=on_show” indicates that the user associates the event processing function customized by the assignment method with the display event of the dynamically derived base window.

[0039] As an example, the specific process of writing the control attributes by the substitution method and forming the call relationship with the user code is described in detail as follows. In the type information of the base window, if the window type is TForm, the user of the software platform can use the window design tool provided by the software platform, inherit the window type TForm, form the window subtype TBaseForm, and after instantiating the window of this subtype, form the above-mentioned dynamically derived base window. The user of the software platform can add the button btnTest to the dynamically derived base window in the window design tool, change the Tag of the button btnTest to 1, and then click the code generation button in the window design tool to obtain the code for dynamically creating the window of the dynamically derived base window and the code for creating the control of the button btnTest. class TBaseForm(TForm): def __init__(self): self.btnTest = Button(self) self.btnTest.Tag = 1 Here, "self.btnTest = Button(self)" is the code for creating the control of the button btnTest. "self.btnTest.Tag = 1" indicates that the Tag attribute of the button is written by the substitution method.

[0040] In this example, the user can further modify the control attributes and / or call events by the user code added by himself. For example, in the user code, the user can determine the corresponding operation based on the Tag attribute of the button btnTest. For example, when the Tag is 1, the text of the button btnTest is set to "Run Mode = 1", and the user code is if 1 == self.btnTest.Tag: self.btnTest.Caption = “Run Mode = 1”, and Here, “if1==self.btnTest.Tag:” means that the user code forms a calling relationship with the attribute “Tag” of the button btnTest, calls the attribute “Tag” of the button btnTest, and further determines the next action of the button btnTest.

[0041] As an arbitrary embodiment of some embodiments, writing the attributes of the window by means of assignment and forming a calling relationship with the user code includes the following. Call the function library owned by the window itself, construct the corresponding parameters, and transmit them to the API function.

[0042] Hereinafter, an example of a specific process of calling the function library owned by the window itself, constructing the corresponding parameters, and transmitting them to the API function will be described in detail. The user sets the width, height, left margin, and top margin of the dynamically derived base window in the window design tool. For example, the width = 200, the height = 100, the left margin = 50, and the top margin = 30. The generated code segment for dynamically creating the window is self.SetBounds(50, 30, 200, 100), and Here, “SetBounds” is one of the specific functions of the dynamically derived base window. Its function is to set the position and size of the dynamically derived base window on the main screen. It has four parameters. Suppose the corresponding list of parameter names and parameter values is as follows.

Table 1

[0043] As an optional embodiment of some embodiments, writing the control attributes by the substitution method and forming a call relationship with the user code includes the following. Call the function library of the control itself, construct the corresponding parameters, and transmit them to the API function.

[0044] The following details an example of the specific process of calling the function library of the control itself and transmitting the corresponding parameters to the API function. If the user adds three entries to the list box control (TControl) in the window design tool, namely "Item 1", "Item 2", and "Item 3", the generated code segment for creating the control is as follows. self.ListBox1.Items.Assign(['Item 1','Item 2','Item 3']) Here, "Items.Assign" is one of the native functions of the list box control, and its function is to set the content of the list box. It has one parameter, and the parameter content is a string array. When this function is called, the content of the list box control is updated to three lines of text: Item 1, Item 2, and Item 3.

[0045] As an optional embodiment of some embodiments, writing the window attributes by the substitution method and forming a call relationship with the user code includes the following. Call the user's function library and introduce the window attributes as parameters to the API function.

[0046] The following details an example of the specific process of calling the user's function library and introducing the attributes of the dynamically derived base window as parameters to the API function. There is one API function in the user's function library "userlib" to display a window in the frontmost position, and the definition of its Python prototype is as follows. def set_top_most(AHandle: int) -> None: "set window to top most" This function has one parameter, which is the window handle. To use this user function library, it is necessary to first import this function library into the user code, and the code is as follows: import userlib Next, the user needs to add the following call code to call this user function in the user code. userlib.set_top_most(self.Handle) When this user function is called, the handle of the dynamically derived base window is transmitted to the user function, and the dynamically derived base window will be displayed in the frontmost position.

[0047] As an arbitrary embodiment of some embodiments, writing the attributes of the control by the method of assignment and forming a calling relationship with the user code includes the following. Call the user's function library and introduce the attributes of the control as parameters to the API function.

[0048] The following details an example of the specific process of calling the user's function library and introducing the attributes of the control as parameters to the API function. There is an API function in the user's function library "userlib" to set the text box pattern, and the definition of its Python prototype is as follows. def set_edit_style(AEdit: TEdit) -> None: "set text edit style" This function has parameters of a text box object. It is necessary to use the user function library and first import the function library into the user code. The code is as follows. import userlib Next, the following is how the user adds call code to call the user function in the user code. userlib.set_edit_style(self.edtTitle) When the user function is called, the text box object edtTitle is transmitted to the user function, and the font style of the text box is changed.

[0049] As an arbitrary implementation form of some embodiments, writing the attributes of the window by the substitution method and forming a call relationship with the user code includes the following. Call the function library of the software system and introduce the attributes of the window as parameters into the function of the API.

[0050] The following details an example of the specific process of calling the function library of the software system and introducing the attributes of the dynamically derived base window as parameters into the function of the API. In this example, assume that the above dynamically derived base window is a graphic display window provided by the software platform, and the graphic display window is a window provided by the software platform for displaying graphic curves. There is a function for taking a screenshot of a window in the function library "app" of the software system. The definition of its python prototype is as follows. def take_screenshot(ACaption: str, AFileName: str) -> None: "take screenshot of specific form and save it to disk" The function has two parameters. The first parameter is the window title name in text format, which is used to search for the corresponding design window in the software platform. The second parameter is the target file name, which is for saving the image file of the screenshot to the hard disk. It is necessary to use the function library of the software system and first import the software platform name into the user code. The code is as follows: import software platform name Next, the user needs to add the calling code to call the software system function in the user code as follows. app.take_screenshot(“Graphics 1”, r“C:\screenshots\graphics.png”) As shown in Figures 7 and 8, when this software system function is called, the window title name “Graphics 1” of the graphic display window and the target file name “C:¥screenshots¥graphics.png” are transmitted to the software system function, and the screenshot information of this graphic display window is saved to the hard disk. Also, as can be seen from Figure 7, the derived graphic display window also has several buttons 10 at the upper right corner of the toolbar and a pull-down menu included in the base window type, and has functions corresponding to button click events and pull-down menu operation events.

[0051] As an optional implementation form of some embodiments, writing the attributes of the control by the substitution method and forming the calling relationship with the user code includes the following. Call the function library of the software system and introduce the attributes of the control as parameters into the API function.

[0052] In the following, a specific example of the process of calling the function library of a software system and introducing the attributes of controls as parameters into the functions of the API will be described in detail. There is a function in the function library "app" of the software system to set system variables in the software platform, and the definition of its Python prototype is as follows. def set_system_var_generic(AName: str, AValue: str) -> None: "set system variable value from string" This function has two parameters. The first parameter is the system variable name, which is used to search for the corresponding system variable in the software platform. The second parameter is the target setting value in string format, which sets the value of the corresponding system variable to the target setting value. When using this software system function library, first, it is necessary to import the software platform name into the user code, and the code is as follows. import software platform name Next, the user adds the call code to call this software system function in the user code as follows. app.set_system_var_generic('sysvar1', self.Button1.Caption) The first parameter "sysvar1" entered first specifies that the name of the corresponding system variable is "sysvar1". The second parameter entered is the string value of the "Caption" attribute of the control "Button1", which is used as the target setting value of the corresponding system variable. If the string value of the "Caption" attribute of the control "Button1" is "3.5", when this software system function is called, the value of the system variable "sysvar1" will be rewritten to "3.5".

[0053] As an optional embodiment of some embodiments, writing the attributes of a window by the substitution method and forming a calling relationship with user code includes the following. Call the function library of the code language and introduce the attributes of the window as parameters into the API function.

[0054] The following details an example of the specific process of calling the function library of the code language and introducing the attributes of the window as parameters into the API function. Taking the Python language as an example, for a user to add the calling code of the code language function to the user code is as follows. self.Memo1.Text = dir(self.Icon) Here, "dir" is a function provided by the code language, and its function is to obtain all the contents in a certain class or module, including variables, methods, functions, classes, etc. When this code language function is called, all the contents of the icon attribute of the dynamically derived base window are loaded into the multi-line text box "Memo1" according to the input parameter "self.Icon".

[0055] As an optional embodiment of some embodiments, writing the attributes of a control by the substitution method and forming a calling relationship with user code includes the following. Call the function library of the code language and introduce the attributes of the control as parameters into the API function.

[0056] The following details an example of the specific process of calling the function library of the code language and introducing the attributes of the control as parameters into the API function. Taking the Python language as an example, for a user to add the calling code of the code language function to the user code is as follows. print(self.Button1.Caption) Here, "print" is a function provided by the code language, and its function is to print the string of the corresponding parameter in the software system. After the code language function is called, the "Caption" attribute of the control "Button1", that is, the tag content of the control "Button1", is printed to the software system according to the input parameter "Button1.Caption".

[0057] As described above, it is possible to modify the dynamically derived base window, and the attributes and / or call events of the controls embedded in the dynamically derived base window to realize a modified derivation for the dynamically derived base window. The user can further perform multiple modified derivations on the dynamically derived base window based on usage needs, and each modified derivation is performed based on the previous modified derivation. For example, the vehicle assembly plant can continue to add important signals related to the entire vehicle to the graphic display window after the first modified derivation of the dynamically derived base window and display them at fixed positions in the graphic display window. For example, display vehicle speed, wheel speed, etc. to form a graphic display window for the second modified derivation. Different component manufacturers can, based on the graphic display window for the second modified derivation transmitted from the vehicle assembly plant, subsequently add special signals belonging to each component manufacturer to their corresponding windows and fixedly display them in the graphic display window for the second modified derivation. For example, display brake deceleration, yaw angular velocity, etc., thereby forming a graphic display window for three or more modified derivations.

[0058] As shown in FIG. 9, some embodiments further provide a dynamically extensible development system for the user interface based on a software platform. This system includes the following. A base dynamic derivation module, during the execution of a software platform, is configured to dynamically extract type information regarding a window in the execution library of the software platform by an interface manager, form a dynamic derived base window by inheriting the type information, and simultaneously generate software platform introduction code by the interface manager. A derived code acquisition module, based on the type information in the software platform introduction code, is configured to generate code for dynamically creating a window once, and store the software platform introduction code and the code for dynamically creating a window once in a derived code file once.

[0059] In some embodiments, when the computer device further performs N + 1 times of derived corrections on the attributes and / or call events of the dynamic derived base window, it creates an N + 1 times derived code file. The N + 1 times derived code file includes N times of derived code file introduction code, N + 1 times of code for dynamically creating a window and / or user code, where N ≥ 1, and executes the N + 1 times derived code file to form a user interface for N + 1 times of derivation. Here, the specific implementation functions of the base dynamic derivation module and the derived code acquisition module are realized in a processor or a computer device. Specifically, reference can be made to the content of the development method for dynamically expanding the user interface based on the aforementioned software platform, and the description is omitted here.

[0060] Several embodiments of an electronic device from the perspective of hardware processing will be described below, but the specific implementation of the electronic device is not limited. As shown in FIG. 10, the electronic device includes a processor, a readable storage medium, a communication bus, and a communication interface. The above-mentioned processor, the above-mentioned readable storage medium, and the above-mentioned communication interface realize communication with each other via the above-mentioned communication bus. The above-mentioned readable storage medium is used to store a program for executing a method for dynamically expanding a user interface based on the above-mentioned software platform, and the above-mentioned processor is configured to execute a program of a method for dynamically expanding a user interface based on the above-mentioned software platform.

[0061] In other embodiments, a computer device or an industrial personal computer can also be regarded as a kind of electronic device.

[0062] Note that the configuration shown in FIG. 10 does not limit the electronic device, and it can include fewer or more components than shown in the figure, some components can be combined, or different components can be arranged.

[0063] In some embodiments, the communication interface may be a communication interface connectable to an external bus adapter, such as RS232, RS485, a USB port, and a TYPE port. A wired or wireless network interface may also be included. The network interface may optionally include wired and / or wireless interfaces (e.g., a WI-FI interface, a Bluetooth interface, etc.) typically used to establish a communication connection between the computer device and other electronic devices.

[0064] Among them, the readable storage medium or computer-readable storage medium includes at least one kind of memory. The memory includes flash memory, hard disk, multimedia card, card-type memory (such as SD or DX memory, etc.), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, it may be an internal storage unit of a computer device, such as a hard disk of a computer device. In other embodiments, the memory may be an external storage device of a computer device, such as a plug-in hard disk equipped on a computer device, a Smart Media Card (SMC) (registered trademark), a Secure Digital (SD) card, a Flash Card, etc. Further, the memory may include both an internal storage unit and an external storage device of a computer device. The memory is used to store various data such as application software installed on a computer device and the code of a computer program, and is also used to temporarily store the output data and the data to be output.

[0065] In some embodiments, the processor may execute the program code stored in the memory or process data, such as a Central Processing Unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chips for executing a computer program.

[0066] In some embodiments, the communication bus may be an input / output bus that can be a Peripheral Component Interconnect (PCI) bus or an Enhanced Industry Standard Architecture (EISA) bus, etc. This bus can be divided into an address bus, a data bus, a control bus, etc.

[0067] In some embodiments, the computer device includes a processor, a readable storage medium electrically connected to the processor, and a display module. The readable storage medium is used to store a program that executes a method for dynamically expanding the development of a user interface based on the software platform. The processor is configured to execute the program to generate a corresponding user interface. The display module is configured to display the user interface.

[0068] Optionally, the computer device may further include a user interface. The user interface may include input units such as a display and a keyboard, and optionally, the user interface may also include a standard wired interface and a wireless interface. Optionally, in some embodiments, the display may be an LED display, a liquid crystal display, a touch liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, etc. In this case, the display is also called a display screen or a display unit for displaying the information processed in the computer device and for displaying the visualized user interface.

[0069] When the processor executes the program, it realizes the steps in the embodiment of the method for dynamically expanding the development of a user interface based on the software platform shown in FIG. 1. For example, steps S101 to S102 shown in FIG. 1. Alternatively, when the processor executes a computer program, it realizes the functions of each module or unit in the embodiments of the above devices.

[0070] This embodiment further provides a computer-readable storage medium, on which a program of a method for dynamically extensible development of a user interface based on a software platform is stored. When the program is executed by a processor, specific steps of the method for dynamically extensible development of a user interface based on a software platform can be realized. Refer to the specific description of the method for dynamically extensible development of a user interface based on a software platform, and the description is omitted here.

[0071] Some embodiments further provide a computer program product, including a computer program or command. When the computer program or command is executed on a computer, the computer is caused to execute the method for dynamically extensible development of a user interface based on any of the possible software platforms described above.

[0072] In some embodiments provided by the present invention, it goes without saying that the disclosed devices and methods can also be implemented in other ways. The embodiments of the devices described above are merely illustrative. For example, the flowcharts and block diagrams in the drawings show the architectures, functions, and operations that can be realized by the devices, methods, and computer program products according to multiple embodiments of the present invention. In this regard, each block in the flowchart or block diagram can represent a module, a program segment, or a part of the code. The above-mentioned module, program segment, or part of the code contains executable instructions for realizing one or more predetermined logical functions. It should be noted that in some alternative implementation methods, the functions represented by the blocks may occur in an order different from the order shown in the drawings. For example, two consecutive blocks can actually be executed substantially in parallel, and depending on the related functions, they can sometimes be executed in the reverse order. Also, each block of the block diagram and / or flowchart, as well as the combination of the blocks of the block diagram and / or flowchart, may be realized by a dedicated hardware-based system for executing a predetermined function or operation, or may be realized by a combination of dedicated hardware and computer instructions.

[0073] Moreover, each functional module in each embodiment of the present invention may be integrated together to form an independent part, each module may exist alone, or two or more modules may be integrated to form an independent part.

[0074] When the above functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence or the part that contributes to the prior art or part of the technical solution, can be represented in the form of a software product. The computer software product is stored in a storage medium and includes a plurality of instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in each embodiment of the present invention.

[0075] Inspired by the preferred embodiments of the present invention described above, those skilled in the art can make various changes and modifications without departing from the technical idea of the present invention from the above description. The technical scope of the present invention is not limited to the content of the specification, and its technical scope must be determined based on the scope of the claims.

Claims

1. A method for dynamically extensible development of a user interface based on a software platform, comprising: During the execution of the software platform, the interface manager dynamically extracts type information related to windows in the execution library of the software platform, and forms a dynamically derived base window by inheriting the type information. At the same time, the interface manager generates the introduction code of the software platform, and generates the code for dynamically creating a window once based on the type information in the software platform introduction code, and stores the software platform introduction code and the code for dynamically creating a window once in a derived code file once. A method for dynamically extensible development of a user interface based on a software platform, characterized in that.

2. When performing N+1 times of derived modification on the attributes and / or call events of the dynamically derived base window, create an N+1 times of derived code file, where the N+1 times of derived code file includes the introduction code of the N times of derived code file, the code for dynamically creating a window N+1 times and / or user code, where N≥1, The N+1 times of derived code file is executed, and the user interface of the N+1 times of derived is formed. A method for dynamically extensible development of a user interface based on the software platform according to claim 1, characterized in that.

3. During the execution of the software platform, the fact that the interface manager dynamically extracts type information related to windows in the software platform execution library is introducing the system's run-time type information unit into the code inside the software platform and using the classes and methods related to the window in the unit, creating a context object using the "run-time type information context type" class in the system's run-time type information unit, and further obtaining the "run-time type information" object of the window by the "run-time type information type acquisition" method, Obtaining the property information of a window using the "property acquisition" method from the "runtime type information" object of the window, and obtaining the method information of the window using the "method acquisition" method, and a dynamically extensible development method for a user interface based on the software platform according to claim 2, characterized by including the above.

4. The interface manager is used for creation, listing, design, saving, import, export, encryption, and execution of the user interface, and a dynamically extensible development method for a user interface based on the software platform according to claim 3, characterized by the above.

5. The attributes include the visual elements and sub - members of the window, The sub - members are the functional variables and / or behavioral characteristic variables of the window, The call event is one or more events among user interaction events, window life - cycle events, and window function events, and a dynamically extensible development method for a user interface based on the software platform according to claim 1, characterized by the above.

6. Performing derived modifications on the attributes and / or call events of the dynamically derived base window Writing the attributes of the window in a substitution manner and forming a call relationship with user code, Associating the event - handling function with the call event of the window in a substitution manner, and a dynamically extensible development method for a user interface based on the software platform according to claim 5, characterized by including the above.

7. Writing the attributes of the window in a substitution manner and forming a call relationship with user code, Calling the function library owned by the window itself, constructing corresponding parameters and introducing them into the API function, Or, calling the user's function library and introducing the attributes of the window as parameters into the API function, Or, calling the function library of the software system and introducing the attributes of the window as parameters into the API function, Or, calling the function library of the code language and introducing the attributes of the window as parameters into the API function, and a dynamically extensible development method for a user interface based on the software platform according to claim 6, characterized by the above.

8. A dynamically extensible development system for a user interface based on a software platform, including a computer device, wherein the computer device is a base dynamic derivation module configured to dynamically extract type information regarding a window in an execution library of a software platform by an interface manager during execution of the software platform, inherit the type information to form a dynamically derived base window, and simultaneously generate software platform introduction code by the interface manager; and a derived code acquisition module configured to generate window dynamic creation code once based on type information in the software platform introduction code, and store the software platform introduction code and the window dynamic creation code once in a derived code file once. A dynamically extensible development system for a user interface based on a software platform, characterized by comprising the above.

9. When the computer device further performs N + 1 times of derived modification on attributes and / or call events of the dynamically derived base window, an N + 1 times derived code file is created, and the N + 1 times derived code file includes N times of derived code file introduction code, N + 1 times of window dynamic creation code and / or user code, where N ≥ 1, and the N + 1 times derived code file is executed to form a user interface with N + 1 times of derivation. The dynamically extensible development system for a user interface based on a software platform according to Claim 8, characterized by the above.

10. The attributes include visual elements and sub - members of the window, the sub - members are function variables and / or behavior characteristic variables of the window, and the call events include one or more events among user interaction events, window life cycle events, and window function events. The dynamically extensible development system for a user interface based on a software platform according to Claim 8, characterized by the above.

11. A computer - readable storage medium, The computer-readable storage medium stores a program for executing a method for dynamically extensible development of a user interface based on the software platform according to any one of claims 1 to 7, characterized in that it is a computer-readable storage medium.

12. A processor, wherein the processor is configured to execute a program of a method for dynamically extensible development of a user interface based on the software platform according to any one of claims 1 to 7, characterized in that it is a processor.

13. An electronic device, comprising a processor, a readable storage medium, a communication bus, and a communication interface, wherein the processor, the readable storage medium, and the communication interface realize communication with each other via the communication bus, wherein the readable storage medium is used to store a program for executing a method for dynamically extensible development of a user interface based on the software platform according to any one of claims 1 to 7, and the processor is configured to execute a program of a method for dynamically extensible development of a user interface, characterized in that it is an electronic device.

14. A computer device, comprising a processor, a readable storage medium electrically connected to the processor, and a display module, wherein the readable storage medium is used to store a program for executing a method for dynamically extensible development of a user interface based on the software platform according to any one of claims 1 to 7, the processor is configured to execute the program to generate a corresponding user interface, the display module is configured to display the user interface, characterized in that it is a computer device.

15. A computer program product, comprising a computer program or command, and when the computer program or command is executed by a computer, the computer is caused to execute a method for dynamically extensible development of a user interface based on the software platform according to any one of claims 1 to 7, characterized in that it is a computer program product.

Citation Information

Patent Citations

  • User interface creating and editing system for user interface server

    JP1995006030A

  • User interface device, software part management method, and software part management program

    JP2007034486A

  • Multi-view masters for graphical designs

    US20200065355A1