Application display method and electronic equipment

By adjusting the number of display columns and element processing in the waterfall flow display area, the problem of abnormal display of the waterfall flow display area under different screen sizes is solved, improving user experience and information volume, and reducing developer adaptation costs.

CN118625980APending Publication Date: 2024-09-10HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310268856.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-03-10
Publication Date
2024-09-10

Smart Images

  • Figure CN118625980A
    Figure CN118625980A
Patent Text Reader

Abstract

The invention provides an application display method and electronic equipment, which are used for realizing adaptive display of a waterfall flow display area included in an application on the electronic equipment with different screen sizes, so that the abnormal display problem of the waterfall flow display area can be avoided, for example, the size of a picture display size is large. According to the method, the electronic equipment can respond to user operation, based on original display data of an application, the display column number of a display area adopting a multi-column layout is modified, and then an application interface is displayed. In this way, the electronic equipment can execute column number modification of application display from the system side, and the display effect can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of terminal technology, and in particular to an application display method and an electronic device. Background Art

[0002] As the styles of terminal products increase, the size and form of the display screens of electronic devices also tend to be diversified. For example, the display screens of electronic devices can be folded inside and outside, horizontally and vertically, etc. For display screens of various shapes and sizes, many applications have optimized the application display interface, such as using a responsive layout method to use different application interface layouts for display screens of different sizes; for example, using the split-screen capability provided by the electronic device system to display applications in a split-screen interface. However, there are still many applications that cannot adapt to various screen aspect ratios, resulting in abnormal application display.

[0003] In application layout, waterfall layout is a common layout method. The waterfall layout can generally be presented as a jagged multi-column layout, and can scroll in response to the page scroll bar or mouse wheel.

[0004] Therefore, how to solve the abnormal display problem of the waterfall display area on different electronic devices is of great research significance. Summary of the invention

[0005] The present application provides an application display method and an electronic device, which are used to flexibly display a waterfall flow layout on the screen of the electronic device and improve the user experience.

[0006] In a first aspect, the present application provides an application display method. In response to a first operation triggered by a user, the electronic device obtains original display data of a first area included in a first application, wherein the original display data includes one or more elements constituting a first area interface of the first area, and an original column number layout adopted by the one or more elements; in response to a first instruction, a second area interface is displayed; the first instruction is used to instruct the one or more elements to change from being displayed in the original column number layout to being displayed in the target column number layout.

[0007] In this method, the electronic device can realize the display adjustment of the display area including the waterfall flow area in the application interface, which adopts the multi-column layout mode, and can improve the adaptability of the waterfall flow display area to the screen size of the electronic device by modifying the display column number of the waterfall flow display area. Therefore, it is unnecessary for the application developer to carry out targeted adaptation for electronic devices with screens of different aspect ratios. The electronic device can adjust the layout of the application developer's application from the perspective of the operating system before displaying it. In this way, it is unnecessary for the application developer to carry out targeted development for different types of electronic devices, which can reduce the adaptation cost, be applicable to more application scenarios, and can also increase the amount of information displayed in the application interface.

[0008] In some embodiments, the first element includes at least two levels, and the first element is at least one of the one or more elements; after responding to the first instruction and before displaying the second area interface, the method also includes: detecting that the first element satisfies a first condition, and the first condition is used to indicate that the first size of the first level included in the first element is smaller than the second size of the second level; wherein the first level includes the second level; expanding the first level of the first element from the first size to a third size, and the third size is greater than or equal to the second size.

[0009] In this embodiment, based on the adjustment of the number of display columns in the waterfall flow area and the possibility that the elements may be displayed in a multi-level manner, when the electronic device detects that the display size of the outer level of the element is larger than the display size of the inner level, it can expand the display size of the outer level of the element, thereby avoiding the problem of truncated display of the elements.

[0010] In some embodiments, the method also includes: detecting that the first element satisfies a second condition, the second condition being used to indicate that the first display size information of the first element is larger than the target display size information corresponding to the target column number layout; reducing the first element from the first display size information to a second display size information, the second display size information being equal to or smaller than the target display size information.

[0011] In this embodiment, based on adjusting the number of display columns in the waterfall flow area, the electronic device can also perform element reduction processing when it detects that the size of the element is larger than the maximum size allowed by each column, thereby avoiding problems such as overlapping display caused by the enlargement of the element.

[0012] In some embodiments, after shrinking the first element from the first display size information to the second display size information, the method further includes: determining a stacking value of a second element based on the first display size information and the second display size information of the first element, the second element being an element located in the same column as the first element when the target column number layout is adopted, and the stacking value is a negative value; and adjusting the display position of the second element based on the stacking value.

[0013] In this embodiment, based on the reduction processing of the elements by the electronic device, the stacking processing between the elements can also be combined, so as to increase the amount of information displayed on the screen.

[0014] In some embodiments, the method also includes: detecting that the first element satisfies a third condition, the third condition being used to indicate that the first display position information of the first element is inconsistent with the target display position information corresponding to the target column number layout; determining a deviation value of the display position of the first element based on the first display position information and the target display position information; and adjusting the display position of the first element based on the deviation value.

[0015] In this embodiment, based on adjusting the number of display columns in the waterfall flow area, the electronic device can also perform alignment processing on the elements of a column when it detects that the display positions of a column of elements cannot be aligned, thereby avoiding the problem of elements not being able to be aligned for display.

[0016] In some embodiments, the first instruction is an instruction pre-configured by the electronic device; or, the first instruction is a second operation triggered by a user, and the second operation is used to indicate the target column number layout determined by the user.

[0017] In this embodiment, the method provided in the embodiment of the present application can be triggered in response to a user operation, or can be automatically triggered by the electronic device.

[0018] In some embodiments, the first area displays the one or more elements in a waterfall layout.

[0019] In a second aspect, the present application provides an electronic device, the electronic device comprising a plurality of functional modules; the plurality of functional modules interact with each other to implement the method shown in the first aspect and its various embodiments. The plurality of functional modules can be implemented based on software, hardware, or a combination of software and hardware, and the plurality of functional modules can be arbitrarily combined or divided based on specific implementations.

[0020] In a third aspect, the present application provides an electronic device comprising at least one processor and at least one memory, wherein the at least one memory stores computer program instructions, and when the electronic device is running, the at least one processor executes the method shown in the above-mentioned first aspect and its various embodiments.

[0021] In a fourth aspect, the present application further provides a computer program, which, when executed on a computer, enables the computer to execute the method described in any one of the above aspects and its various implementations.

[0022] In a fifth aspect, the present application further provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a computer, the computer executes the method shown in any one of the above aspects and its various embodiments.

[0023] In a sixth aspect, the present application also provides a chip, which is used to read a computer program stored in a memory and execute the method shown in any of the above aspects and its various embodiments.

[0024] In a seventh aspect, the present application further provides a chip system, which includes a processor for supporting a computer device to implement the method shown in any of the above aspects and its various embodiments. In a possible design, the chip system also includes a memory, which is used to store the necessary programs and data of the computer device. The chip system can be composed of a chip, or it can include a chip and other discrete devices.

[0025] For the beneficial effects of any aspect from the second to the seventh aspect and its possible designs, please refer to the beneficial effects of the various possible designs in the first aspect, which will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] Figure 1 A schematic diagram is shown for one application;

[0027] Figure 2 A schematic diagram of an electronic device displaying an application interface in the center of a screen;

[0028] Figure 3 A schematic diagram of an electronic device displaying an application interface in a parallel field of view manner on a screen;

[0029] Figure 4 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application;

[0030] Figure 5 A software architecture block diagram of an electronic device provided in an embodiment of the present application;

[0031] Figure 6A schematic diagram of an interface of an application display method provided in an embodiment of the present application;

[0032] Figure 7 One of the flowcharts of an application display method provided in an embodiment of the present application;

[0033] Figure 8 A schematic diagram of an interface for a truncated display problem that may be involved in an application display method provided in an embodiment of the present application;

[0034] Fig. 9 A schematic diagram showing a scenario in which an application display method provided by an embodiment of the present application is applicable to a truncated display problem;

[0035] Fig.10 A schematic diagram showing another scenario in which an application display method provided by an embodiment of the present application is applicable to a truncated display problem;

[0036] Fig.11 A schematic diagram of an interface for a position display problem that may be involved in an application display method provided in an embodiment of the present application;

[0037] Fig.12 The second flowchart of an application display method provided in an embodiment of the present application. DETAILED DESCRIPTION

[0038] The embodiments of the present application will be described in detail below with reference to the accompanying drawings.

[0039] As the styles of terminal products increase, the size and form of the display screens of electronic devices also tend to be diversified. For example, the display screen of an electronic device can be folded inside and outside, horizontally and vertically, etc. For display screens of various shapes and sizes, many applications have optimized the application display interface, for example, through responsive layout methods, different application interface layouts are adopted for display screens of different sizes; for example, with the help of the split-screen capability provided by the electronic device system, the application is displayed in the split-screen interface. However, there are still many applications that cannot adapt to various screen aspect ratios, resulting in abnormal application display. In application layout, waterfall layout is a more common layout method. The waterfall layout can generally be expressed as an uneven multi-column layout, and can scroll in response to page scroll bars or mouse wheels. In scenarios where the application cannot adapt to the screen aspect ratio, solving the abnormal display problem of the waterfall display area is of great research significance.

[0040] For example, Figure 1 A schematic diagram is shown for one application. Figure 1 , for an application, it can be displayed on the mobile phone as follows Figure 1The interface 11 includes a display area 11a which is an application display area using a waterfall flow layout. Figure 1 When the application shown in interface 11 is displayed in a tablet computer, or when the mobile phone is a folding screen device, interface 11 is displayed when the mobile phone is folded, and when the mobile phone changes from the folded state to the unfolded state, the application shown in interface 11 can be displayed as follows Figure 1 Interface 12 in the figure; wherein, interface 12 includes display area 12a which is an application display area using a waterfall flow layout. It can be seen from interfaces 11 and 12 that the interfaces of the same application displayed on the screens of different types of electronic devices are only scaled up. Therefore, although the screen of a tablet computer or a folding screen in an unfolded state is larger, due to the large screen of the tablet computer or the folding screen in an unfolded state, the pictures, texts and other contents in the application interface displayed on the tablet computer or the folding screen in an unfolded state become abnormally large, and the amount of information displayed on the screen is less, which affects the user experience.

[0041] In one application display solution, in order to solve the problem of different screen aspect ratios of electronic devices, each application developer can make targeted matches for their own applications, for example, they can develop application versions suitable for mobile phones and also for tablet computers. In this way, application developers can develop waterfall display areas for electronic devices with different screen aspect ratios. However, this solution has a high adaptation cost and certain application limitations.

[0042] In another application display solution, when the aspect ratio of the application interface is incompatible with the aspect ratio of the electronic device screen, the electronic device can display the application interface in the center of the screen to display the application interface in a more appropriate ratio. Figure 2 A schematic diagram of an electronic device displaying an application interface in the center of the screen. Figure 2 The content shown in interface 21 in the figure is displayed in the center of the electronic device screen, and the area on the screen not occupied by the application interface can be filled with a black background. However, in this solution, the size of the application interface displayed on the screen is fixed, the screen utilization rate is low, and the user experience is poor.

[0043] In another application display solution, in large-screen devices such as tablet computers or foldable screen phones, the application interface can also be displayed in a parallel view mode. Figure 3 A schematic diagram of an electronic device displaying an application interface in a parallel field of view manner on a screen. Figure 3As can be seen from the interface 31 shown in the figure, the screen of the electronic device can be divided into two windows to display the application program, such as the interface 31 can be divided into a display window 31a and a display window 31b. This display mode usually requires the configuration of various jump logics to realize the linkage of the two windows. For example, the electronic device detects and responds to the operation instruction of the preview card 31a1 for displaying the top in the display window 31a, and can be displayed as a detailed information page 31b1 corresponding to the top in the display window 31b. Although this display mode can overcome the problem of abnormal display of the application by means of parallel horizons, since the various jump logics of this display mode are generally configured by the application developer, and the jump logic is relatively complex, the application developer needs to perform a lot of configuration; moreover, the user may not be adapted to the jump logic developed by the application developer, and the user experience is not good.

[0044] In view of this, an application display method is provided in an embodiment of the present application, which is used to flexibly display an application interface on the screen of an electronic device, and at the same time, the screen utilization rate of the electronic device can be improved. In the embodiment of the present application, the focus is on the display area of ​​the application that adopts a waterfall flow layout. In this method, the electronic device can provide the ability to modify the number of columns in the waterfall flow display area, and can achieve adaptive display after modifying the number of columns. In this way, there is no need for application developers to perform targeted adaptation for electronic devices with screens with different aspect ratios. The electronic device can adjust the layout of the application developer's application from the perspective of the operating system before displaying it. In this way, there is no need for application developers to carry out targeted development for different types of electronic devices, thereby reducing the adaptation cost, being suitable for more application scenarios, and also increasing the amount of information displayed in the application interface.

[0045] The following describes an electronic device and an embodiment for using such an electronic device. The electronic device of the embodiment of the present application may be a tablet computer, a mobile phone, a vehicle-mounted device, an augmented reality (AR) / virtual reality (VR) device, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), a wearable device, or other electronic device with a display function. The embodiment of the present application does not impose any restrictions on the specific type of the electronic device.

[0046] Figure 4 FIG. 1 is a schematic diagram of the structure of an electronic device 100 provided in an embodiment of the present application. Figure 4As shown, the electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.

[0047] The processor 110 may include one or more processing units, for example, the processor 110 may include an application processor (AP), a modem processor, a graphics processor (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU) and other processing units. Among them, different processing units may be independent devices or integrated into one or more processors. Among them, the controller may be the nerve center and command center of the electronic device 100. The controller may generate an operation control signal according to the instruction opcode and the timing signal to complete the control of fetching and executing instructions. A memory may also be set in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a high-speed cache memory. The memory may store instructions or data that the processor 110 has just used or circulated. If the processor 110 needs to use the instruction or data again, it can be directly called from the memory. Repeated access is avoided, the waiting time of the processor 110 is reduced, and the efficiency of the system is improved. In the embodiment of the present application, the processor 110 may be used to execute the application display method provided in the embodiment of the present application. For example, the processor 110 may be used to modify the number of columns of the waterfall display area included in the application. In addition, the processor 110 may also be used to solve one or more of the problems of element display truncation, element display position abnormality, element size, and element spacing that may occur due to the modification of the number of columns.

[0048] The USB interface 130 is an interface that complies with the USB standard specification. The charging management module 140 is used to receive charging input from the charger. The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, and provides power to the processor 110, the internal memory 121, the external memory, the display screen 194, the camera 193, and the wireless communication module 160.

[0049] The wireless communication function of the electronic device 100 can be implemented by antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modulation and demodulation processor and baseband processor. The mobile communication module 150 can provide solutions for wireless communication including 2G / 3G / 4G / 5G applied to the electronic device 100. The wireless communication module 160 can provide solutions for wireless communication including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) network), bluetooth (bluetooth, BT), global navigation satellite system (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field communication technology (near field communication, NFC), infrared technology (infrared, IR) and the like applied to the electronic device 100. In some embodiments, the antenna 1 of the electronic device 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with the wireless communication module 160, so that the electronic device 100 can communicate with the network and other devices through wireless communication technology.

[0050] In the embodiment of the present application, the electronic device 100 can obtain an application program package provided by an application developer through the mobile communication module 150 or the wireless communication module 160, so that after installing the application program package on the electronic device 100, an application interface can be provided to the user.

[0051] The display screen 194 is used to display the display interface of the application, such as the display interface of the application installed on the electronic device 100; wherein the application interface may include a display area using a waterfall flow layout, such as Figure 1The interface 11 includes the display area 11a, or the interface 12 includes the display area 12a. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oLed, a quantum dot light emitting diode (QLED), etc. In some embodiments, the electronic device 100 may include 1 or N display screens 194, where N is a positive integer greater than 1.

[0052] The camera 193 is used to capture still images or videos. In some embodiments, the electronic device 100 may include 1 or N cameras 193, where N is a positive integer greater than 1.

[0053] The internal memory 121 can be used to store computer executable program codes, which include instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area may store an operating system, and software code of at least one application program, etc. The data storage area may store data (such as captured images, recorded videos, etc.) generated during the use of the electronic device 100. In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (universal flash storage, UFS), etc. In an embodiment of the present application, the application package obtained by the electronic device 100 may be stored in the internal memory 121, and the computer program instructions for implementing the application display method provided in the embodiment of the present application may also be stored, so as to realize the layout adjustment of the elements using the waterfall flow layout included in the application package from the application developer, such as modifying the number of display columns, and then displaying the application.

[0054] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as pictures and videos are stored in the external memory card.

[0055] The electronic device 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone jack 170D, and the application processor.

[0056] Among them, the sensor module 180 may include a pressure sensor 180A, an acceleration sensor 180B, a touch sensor 180C, etc.

[0057] The pressure sensor 180A is used to sense the pressure signal and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be disposed on the display screen 194 .

[0058] The touch sensor 180C is also called a "touch panel". The touch sensor 180C can be arranged on the display screen 194, and the touch sensor 180C and the display screen 194 form a touch screen, also called a "touch screen". The touch sensor 180C is used to detect touch operations acting on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the display screen 194. In other embodiments, the touch sensor 180C can also be arranged on the surface of the electronic device 100, which is different from the position of the display screen 194. In the embodiment of the present application, the touch sensor 180C can be used to collect user operations of the user on the display screen 194. The user operation can be, for example, a sliding operation on the display interface of the application to switch the display of different contents of the application, and can also be a click operation on an element on the display interface of the application to jump to the associated display interface corresponding to the element, etc.

[0059] The button 190 includes a power button, a volume button, etc. The button 190 can be a mechanical button. It can also be a touch button. The electronic device 100 can receive the button input and generate a key signal input related to the user settings and function control of the electronic device 100. The motor 191 can generate a vibration prompt. The motor 191 can be used for incoming call vibration prompts, and can also be used for touch vibration feedback. For example, touch operations acting on different applications (such as taking pictures, audio playback, etc.) can correspond to different vibration feedback effects. The touch vibration feedback effect can also support customization. The indicator 192 can be an indicator light, which can be used to indicate the charging status, power changes, and can also be used to indicate messages, missed calls, notifications, etc. The SIM card interface 195 is used to connect the SIM card. The SIM card can be inserted into the SIM card interface 195, or pulled out from the SIM card interface 195 to achieve contact and separation with the electronic device 100.

[0060] Understandably, Figure 4 The components shown do not constitute a specific limitation on the electronic device 100. The electronic device may also include more or fewer components than shown, or combine some components, or separate some components, or arrange the components differently. Figure 4 The combination / connection relationship between the components can also be adjusted and modified.

[0061] Figure 5 The following is a software architecture diagram of an electronic device provided in an embodiment of the present application. Figure 5 As shown, the software architecture of the electronic device can be a layered architecture, for example, the software can be divided into several layers, each layer has a clear role and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the operating system is divided into four layers, from top to bottom, namely, the application layer, the application framework layer (framework, FWK), the runtime (runtime) and the system library, and the kernel layer.

[0062] The application layer can include a series of application packages. Figure 5 As shown, the application layer may include camera, settings, skin module, user interface (UI), third-party applications, etc. Among them, the third-party applications may include gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, short message, etc. In the embodiment of the present application, the application layer may include a target installation package of a target application that the electronic device requests to download from a server, and the function files and layout files in the target installation package are adapted to the electronic device.

[0063] The application framework layer provides an application programming interface (API) and a programming framework for the applications in the application layer. The application framework layer may include some predefined functions. Figure 5 As shown, the application framework layer may include a content provider, a phone manager, a notification manager, a resource manager, and a window manager; and may also include the callback tool, layout manager, and view system that are the focus of the embodiments of the present application.

[0064] The view system includes visual controls, such as controls for displaying text, controls for displaying pictures, etc. The view system can be used to build applications. A display interface can be composed of one or more views. For example, a display interface including a text notification icon can include a view for displaying text and a view for displaying pictures. It can be understood that the view system can support the display of various elements included in the application.

[0065] The layout manager is a plug-in toolkit added in the embodiment of the present application to implement the application display method, which can be used to implement the layout re-editing of the visual controls in the view system; wherein, the layout re-editing, for example, may include but is not limited to: modifying the number of columns, reducing (or enlarging), stacking, adjusting the layout, etc. Correspondingly, the layout manager may include but is not limited to: modifying the number of columns, reducing (or enlarging) tools, stacking tools, adjusting layout tools, etc.

[0066] The callback tool can be used to respond to the application layer's request for displaying the application interface, and to call back various tools in the layout management, so that the layout of the original visual controls in the view system included in the application package can be re-edited. Exemplarily, the callback tool can be, for example, a hook tool. It should be noted that in the embodiment of the present application, the number of hook tools is not limited, and hook tools can be added to various drawing nodes as needed, such as when a new view node is added, when the size of the view changes, before measuring the view size, or before drawing the view. In a specific embodiment, the hook tool can call various tools in the layout manager, so that the functions that the various tools are responsible for can be implemented.

[0067] The content provider is used to store and retrieve data and make the data accessible to the application. The data may include video, images, audio, dialed and received calls, browsing history and bookmarks, phone book, etc. In the embodiment of the present application, the window manager is also used to calculate the size of the waterfall display area adjusted by the user and improve the zoom capability of the window.

[0068] The phone manager is used to provide communication functions for electronic devices, such as the management of call status (including answering, hanging up, etc.).

[0069] The resource manager provides various resources for applications, such as localized strings, icons, images, layout files, video files, and so on.

[0070] The notification manager enables applications to display notification information in the status bar. It can be used to convey notification-type messages and can disappear automatically after a short stay without user interaction. For example, the notification manager is used to notify download completion, message reminders, etc. The notification manager can also be a notification that appears in the system top status bar in the form of a chart or scroll bar text, such as notifications of applications running in the background, or a notification that appears on the screen in the form of a dialog window. For example, a text message is displayed in the status bar, a prompt sound is emitted, an electronic device vibrates, an indicator light flashes, etc.

[0071] The window manager is used to manage window programs. The window manager can obtain the display screen size, determine whether there is a status bar, lock the screen, capture the screen, etc.

[0072] The runtime includes the core library and the virtual machine. The runtime is responsible for the scheduling and management of the operating system.

[0073] The core library consists of two parts: one is the function that the Java language needs to call, and the other is the core library of the operating system. The application layer and the application framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and the application framework layer as binary files. The virtual machine is used to perform object life cycle management, stack management, thread management, security and exception management, and garbage collection.

[0074] The system library may include multiple functional modules, such as surface manager, media libraries, 3D graphics processing library (such as OpenGL ES), 2D graphics engine (such as SGL), image processing library, etc.

[0075] The surface manager is used to manage the display subsystem and provide the fusion of 2D and 3D layers for multiple applications.

[0076] The media library supports playback and recording of a variety of commonly used audio and video formats, as well as static image files, etc. The media library can support a variety of audio and video encoding formats, such as: MPEG4, H.264, MP3, AAC, AMR, JPG, PNG, etc.

[0077] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0078] A 2D graphics engine is a drawing engine for 2D drawings.

[0079] The kernel layer is the layer between hardware and software. The kernel layer contains at least display driver, camera driver, audio driver, and sensor driver.

[0080] The hardware layer can include various types of sensors, such as accelerometers, gyroscopes, touch sensors, etc.

[0081] It should be noted that Figure 4 and Figure 5 The structure shown is only an example of the electronic device provided by the embodiment of the present application, and cannot be used to limit the electronic device provided by the embodiment of the present application. In specific implementation, the electronic device may have more Figure 4 or Figure 5 More or fewer devices or modules may be included in the structures shown.

[0082] In order to make the purpose, technical scheme and advantages of the embodiments of the present application clearer, the embodiments of the present application will be further described in detail below in conjunction with the accompanying drawings. Among them, in the description of the embodiments of the present application, the terms "first" and "second" are used only for descriptive purposes and cannot be understood as indicating or implying relative importance or implicitly indicating the number of indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features.

[0083] It should be understood that in the embodiments of the present application, "at least one" refers to one or more, and "plurality" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b or c can represent: a, b, c, a and b, a and c, b and c, or a, b and c, where a, b, c can be single or multiple.

[0084] In order to facilitate understanding of an application display method provided by the present application, the following Figures 6 to 12 The content shown introduces the implementation process of the method provided by this application.

[0085] The method provided in the embodiment of the present application can be applied to electronic devices such as mobile phones, tablet computers, or folding screen mobile phones, and can be specifically applied to the scene of displaying an application program interface on an electronic device. Through the method provided in the present application, the problem of abnormal display of images and texts that may be caused by the incompatibility of the screen aspect ratio of the electronic device with the aspect ratio of the application interface developed by the application can be solved, and the focus can be on the abnormal display problems of the waterfall display area included in the application interface, such as abnormal display problems such as excessive display of pictures and excessive display of fonts (for ease of understanding, the following embodiments may be referred to as "large pictures and large fonts"). In this method, the electronic device can adjust the number of display columns for various display elements using waterfall flow layout included in the application interface designed by the application developer, and can also realize adaptive display based on the adjustment of the number of display columns. Among them, the adaptive display can be but not limited to processing the following abnormal display scenarios that may be caused by the adjustment of the number of display columns: one or more of abnormal displays such as element display truncation, abnormal element display position, element size and element spacing. Therefore, this method can not only improve the adaptability of the display application interface to the screen aspect ratio and solve abnormal display problems such as large images and large fonts, but also increase the amount of information displayed by the application on the screen of the electronic device and improve the user experience.

[0086] Among them, the display elements involved in the application may include but are not limited to: picture elements (for example, they may include picture controls, background picture frames, etc.), text elements (for example, they may include text controls, prompt text information, etc.), button controls, and selection controls, etc.

[0087] In some application scenarios, the method provided in the embodiments of the present application can be applied to foldable screen mobile phones; for example, the screen aspect ratio of the foldable screen mobile phone in the folded state is different from that in the unfolded state, and the foldable screen mobile phone in the folded state and the unfolded state are displayed based on the original display data of the application interface, and abnormal display problems may occur when the foldable screen mobile phone is in the unfolded state. Figure 6 A schematic diagram of an interface of an application display method provided in an embodiment of the present application is shown. Figure 6 It can include an application display interface 600a when the foldable screen mobile phone is in a folded state, and can also include an application display interface 600b when the foldable screen mobile phone is in an unfolded state; it can be seen from the waterfall flow display area 601 of interface 600a and the waterfall flow display area 602 of interface 600b that although the foldable screen mobile phone in the unfolded state has a larger display screen than the foldable screen mobile phone in the folded state, there is an abnormal display problem in the display of the application, resulting in less information displayed. Figure 6It may also include interface 600c. Interface 600c is an application interface displayed after the method provided in the embodiment of the present application is adopted. Interface 600c includes waterfall display area 603 which is the focus of the embodiment of the present application. For example, interface 600c and interface 600b can display the same application data. Interface 600b divides the application data into two columns for display. Interface 600c changes the display of application data from two columns to three columns. Figure 6 It can be seen from the interface 600c shown in FIG. 6 that compared with the interface 600b, the display effect of the waterfall flow display area of ​​the interface 600c can better adapt to the screen aspect ratio of the electronic device, and can also display more content, thereby increasing the amount of displayed information on the screen of the electronic device.

[0088] It should be noted that the interface 600c is only displayed in three columns as an example, and the method provided in the embodiment of the present application is not limited to changing to three columns, and changing to four columns or more is also applicable.

[0089] In other application scenarios, the method provided in the embodiment of the present application can also be applied to the scenario of projecting the application interface displayed on the mobile phone to other electronic devices, such as projecting to a large screen. Based on the fact that mobile phones usually have long and narrow characteristics, and large screens generally have large-screen characteristics, projecting the application interface displayed on the mobile phone to the large screen may also cause abnormal display problems as described in the scenario where the folding screen mobile phone changes from a folded state to an unfolded state. Based on the method provided in the embodiment of the present application, it is possible to display the number of display columns of the waterfall flow display area on the large screen after modification, so that a more suitable display effect can be achieved on the large screen. In some application scenarios, the method provided in the embodiment of the present application can also be applied to the scenario of turning the mobile phone from a vertical screen to a horizontal screen. It can be understood that the method provided in the embodiment of the present application can also be applied to electronic devices such as tablet computers, and the present application does not limit the type of electronic devices.

[0090] based on Figure 6 The following describes the implementation process of the application display method provided by this application to illustrate how to use the method provided by this application to achieve the above-mentioned interface display effect. Figure 6 The interface processing effect shown can flexibly display the waterfall display area included in the application interface on the screen of the electronic device.

[0091] In order to facilitate understanding of the method provided by the embodiment of the present application, the technologies that may be involved in the interface display of the application are first introduced. The application usually uses a slidable container control to build the interface. The following are some examples of typical controls provided by the system:

[0092] RecyclerView control: can display elements (or objects, which can contain text and images) in a list or grid format. Compared with the ListView control, the RecyclerView control has a more powerful element reuse mechanism and provides more layout managers to handle multiple layouts. You can customize the layout manager to determine the arrangement rules of items, such as: 1. Linear layout similar to the ListView control, to achieve horizontal or vertical list layout; 2. Grid layout, you can specify the number of elements; 3. StaggeredGridLayoutManager, you can specify the list direction, or the number of elements in the same direction.

[0093] Scrollbar (ScrollView): can make the control scroll. In some embodiments, ScrollView can trigger the control to scroll in response to the scrolling of the mouse wheel. In other embodiments, ScrollView can also trigger the control to scroll in response to the mouse, stylus or finger touching the page scroll bar.

[0094] StaggeredGridLayoutManager: Generally, it can be expressed as a staggered multi-column layout, and the display area using StaggeredGridLayoutManager can scroll in response to the page scroll bar, and can continuously load data blocks and append them to the end of the current display area. Among them, the staggered multi-column layout can be understood as the heights of elements such as cards or pictures displayed using the staggered grid layout can generally be unequal.

[0095] It can be understood that the combination of RecyclerView control, ScrollView and StaggeredGridLayoutManager can reduce the complexity of users browsing the application interface and improve the user experience. Therefore, waterfall flow layout appears more and more in application interfaces.

[0096] See also Figure 7 , is a flow chart of an application display method provided in an embodiment of the present application. The flow can be applied to an electronic device and may include the following steps:

[0097] Step 701, find the data to be displayed corresponding to the target cyclic view (RecyclerView) control. It can be understood that the electronic device can process the method provided in this application based on obtaining the application package from the application developer. Among them, the application package may include a variety of possible data; some data can be used to support the display of the application interface. The method provided in the embodiment of the present application focuses on the display method of the waterfall display area included in the application interface, and the waterfall display area can generally be implemented based on the RecyclerView control. Based on this, the electronic device can obtain the data to be displayed corresponding to the RecyclerView control from the application package, so as to facilitate the processing of the application display based on the data to be displayed.

[0098] Step 702: For the data to be displayed, change the display using the original number of columns to the display using the target number of columns.

[0099] In a possible example, the target RecyclerView control can be called based on the reflection method to implement the modification of the number of columns used when displaying the waterfall flow area of ​​the application on the system side. For example, if the waterfall flow area that does not adopt the method provided in the embodiment of the present application is displayed in two columns, the waterfall flow area after adopting the method provided in the embodiment of the present application can be changed to be displayed in three or more columns; in this scenario, the original number of columns is two columns, and the target number of columns is three or more columns, so that the data to be displayed in the waterfall flow layout included in the application package can be displayed in three or more columns on the screen of the electronic device. Among them, the reflection method is a feature of the programming language, which can obtain information and dynamically call objects when the program is running. Based on this, the electronic device can modify the number of display columns by running the reflection method during the display of the application package.

[0100] In some embodiments, the electronic device may provide the user with a selection interface for determining the target number of columns; wherein a selection control for determining the target number of columns may be provided in the selection interface. It is understood that if the electronic device detects that the user determines that the target number of columns is 3 columns through the selection control, the electronic device may change from using 2 columns to using 3 columns to display the waterfall flow area in response to the user operation; or, if the electronic device detects that the user determines that the target number of columns is 4 columns through the selection control, the electronic device may change from using 2 columns to using 4 columns to display the waterfall flow area in response to the user operation. In addition, the electronic device may also display a preview display interface after modifying the target number of columns to the user on the selection interface, so that the user can select the target number of columns. Through this embodiment, the display of the application interface can be made more in line with the user's usage habits, thereby realizing personalized application display and improving the user experience. In other embodiments, the electronic device may also automatically trigger the method provided in the embodiment of the present application based on the screen characteristics of the electronic device. For example, when a folding screen mobile phone detects that the mobile phone is converted from a folded state to an unfolded state, it may automatically trigger the method provided by the present application to realize the interface display on the unfolded folding screen.

[0101] In some possible implementations, after the electronic device executes step 702, due to the modification of the number of display columns, when displaying the data to be displayed, one or more of truncation display problems, size display problems, and position display problems may occur in the waterfall display area. For various display problems that may occur, the following steps may be used to solve them:

[0102] 1) Truncation display problem. In the waterfall display area, each data block can be used as an item, for example, Figure 6 Three items are shown in interface 600b, and seven items are shown in interface 600c. For each item, the display of element content can generally be implemented based on a container control. In some embodiments, the container control can be used to determine the display frame of the item, for example, the shape, size, and position of the display frame can be determined. In other embodiments, the container control can allow other element content to be added internally, for example, element content such as picture controls and text controls can be added internally. In addition, the item can generally be constructed based on a multi-branch tree structure; wherein the container control can serve as the root node of the multi-branch tree structure, the elements included in the container control can serve as child nodes of the multi-branch tree structure, and the innermost child elements further included in the elements can serve as leaf nodes of the multi-branch tree structure.

[0103] Based on the above introduction, after the electronic device uses step 701 and step 702 to modify the number of columns, it may happen that the size of the container control included in the Item as the parent node is adaptively adjusted, while the size of the element content included in the Item as the child node or leaf node is fixed and not adaptively adjusted, resulting in a truncated display problem. For example, Figure 8 A schematic diagram of an interface for a truncated display problem that may be involved in an application display method provided in an embodiment of the present application. Figure 8 Take a folding screen mobile phone in the unfolded state as an example. Figure 8 It can be seen from the area 801 shown in the interface 800a in the waterfall flow area that the image element content inside the data block cannot be fully displayed, and only the image element content of the item size can be displayed. In this scenario, the electronic device can perform the following steps 703a and 704a.

[0104] Step 703a: Determine whether there is a truncated display problem.

[0105] In some embodiments, the electronic device may use a recursive layer-by-layer method to compare the element display size with the target display size of the corresponding layer. Exemplarily, when it is detected that the first-level element meets the target display size requirement of the first level, but the second-level element does not meet the target display size requirement of the second level, it can be determined that there is a truncated display problem, and continue to execute step 704a; wherein the first level includes the second level. Another exemplary method is to detect that each level element meets the target display size of the corresponding level, it can be determined that there is no truncated display problem, and the subsequent steps can be continued, for example, it can be continued to execute Figure 7 In some embodiments, the electronic device comparing display sizes may be implemented as comparing display widths.

[0106] It can be understood that when the waterfall display area is displayed as two columns, the width of each column is approximately half the width of the electronic device screen (also referred to as "1 / 2 screen width"); wherein the electronic device screen width is the screen length determined based on the display direction of the electronic device and perpendicular to the display direction, for example, when the display direction is a vertical screen direction, the electronic device screen width is the top side length (or bottom side length) of the electronic device, and for example, when the display direction is a horizontal screen direction, the electronic device screen width is the side length of the electronic device. Similarly, when the waterfall display area is displayed as three columns, the width of each column is approximately one-third of the width of the electronic device screen (also referred to as "1 / 3 screen width"). It can be understood that the actual display width of each column of elements can also be determined in combination with the spacing between the elements and the side edges and the spacing between the elements. In the embodiments of the present application, for ease of understanding, 1 / 2 screen width and 1 / 3 screen width are used as examples for introduction. Those skilled in the art can understand that the actual display width may not be equal to 1 / 2 screen width or 1 / 3 screen width.

[0107] Based on the above introduction, the target display size can be determined according to the width of the electronic screen and the number of display columns. Exemplarily, when displayed as three columns, the target display size can be 1 / 3 of the screen width. In addition, it can be understood that for each Item in the waterfall display area, the node size at the previous level is generally greater than or equal to the node size at the current level. For example, the container control included in the Item is the parent node, and the size of the container control is generally greater than or equal to the image element as the child node. In this way, the waterfall display area will not have truncated display problems. If the size of each level does not meet the target display size requirements of the corresponding level, the following may occur. Figure 8 The interface 800a in FIG. 8 shows a truncated display problem.

[0108] It should be noted that Figure 8 The interface 800a in the figure is only for understanding the display interface corresponding to the method provided in the embodiment of the present application. When actually displayed, after the electronic device adopts the method provided in the embodiment of the present application, the interface 800d can be directly displayed. The interface 800d can be used to indicate the application interface displayed after the method provided in the embodiment of the present application is adopted. In addition, the interface 800b and the interface 800c introduced in the subsequent embodiments are also for facilitating the understanding of the method provided in the embodiment of the present application. When actually displayed, the electronic device may not display the interface 800a to the interface 800c, but directly display the interface 800d, which will not be described in detail later.

[0109] Step 704a: perform capacity expansion processing.

[0110] In some possible embodiments, Fig. 9 A schematic diagram of a scenario in which an application display method provided in an embodiment of the present application is applicable to a truncated display problem is shown. Fig. 9 The interface 900 included in may be an original display interface of an element of an application package; wherein the original display interface is displayed as two columns as an example. Fig. 9 The interface 910 included in the figure may be a display interface in which the element display problem occurs after the number of columns is modified; wherein the interface 910 is displayed as three columns as an example. Fig. 9The interface 920 included in may be a display interface after expansion processing for the truncated display problem. Exemplarily, the electronic device may expand the display size of the first-level element based on the display size of the second-level element, so that the display size of the first-level element may include the display size of the second-level element, so as to solve the truncated display problem; for example, the second-level element may be a picture element as a child node, and the first-level element may be a container control as a parent node. It can be understood that by expanding the container control, it can be achieved that the size of the container control after expansion can cover the size of the element content included in the container control, thereby solving the truncated display problem.

[0111] It can be understood that based on the expansion process introduced in step 704a, the waterfall flow display area after the expansion process can be displayed as Figure 8 As can be seen from interface 800b, although the waterfall display area after the expansion process can solve the truncated display problem, there is a size display problem, such as the enlargement problem shown in interface 800b. Based on this, the electronic device can continue to perform step 703b.

[0112] In some other possible embodiments, in order to solve the truncated display problem, in addition to using the expansion processing implementation method introduced in step 704a, the electronic device can also use a layer-by-layer recursive method to perform a reduction process on each item included in the waterfall display area, so that the node size of each level included in the item meets the target display size of the corresponding level. For example, Fig.10 A schematic diagram of another scenario in which an application display method provided in an embodiment of the present application is applicable to the truncated display problem is shown. Fig.10 The interface 1000 included in may be an original display interface of an element of an application package; wherein the original display interface is displayed as two columns as an example. Fig.10 The interface 1010 included in the figure may be a display interface in which the element display problem occurs after the number of columns is modified; wherein the interface 1010 is displayed as three columns as an example. Fig.10 The interface 1020 included in the above may be a display interface after the reduction process is performed in a layer-by-layer recursive manner for the truncated display problem. It can be understood that based on the above reduction process, the waterfall flow display area after the reduction process may be displayed as follows: Figure 8 As can be seen from interface 800c, the waterfall display area after the reduction process can solve the truncated display problem. In addition, the electronic device can also perform stacking processing on interface 800c, and after the stacking processing, it can be displayed as Figure 8 Interface 800d in.

[0113] 2) Size display problem, which can be manifested as a magnification problem. Since the screen size of the electronic device is fixed, after the number of columns is modified by step 701 and step 702, when there is a magnification problem, three columns of elements may overlap. Alternatively, after the electronic device executes step 704a, there may also be a size display problem. For example, Figure 8 The interface 800b in the figure shows the display interface of the waterfall area with the magnification problem. It can be understood that the truncated display problem can also be understood as a size display problem, which is due to the magnification problem of the internal elements included in the data block. It can be understood that since the size of the data block or picture element is greater than 1 / 3 or equal to 1 / 3 of the screen width and is not reduced to a suitable size range, there is a magnification problem, which may cause overlapping problems of elements belonging to different columns. In this scenario, the electronic device can perform the following steps 703b and 704b.

[0114] Step 703b, determine whether there is a size display problem. Exemplarily, the electronic device compares the element display width with the target display width. When it is detected that the element display width does not meet the requirement of the target display width, it is determined that there is a size display problem, and step 704b is continued; when it is detected that the element display width meets the requirement of the target display width, it is determined that there is no size display problem, and subsequent steps can be continued, for example, Figure 7 Step 703c shown in . In some embodiments, taking the size display problem as a zoom-in problem as an example, the target display width requirement may be less than 1 / 3 of the screen width; it can be understood that the element display width does not meet the target display width requirement and can be expressed as the element display width being greater than or equal to 1 / 3 of the screen width. Similarly, when the size display problem is a zoom-out problem, the target display width requirement may be greater than a specified screen width threshold, and it can be understood that the specified screen width threshold is less than 1 / 3 of the screen width. In other words, when the waterfall display area is displayed as three columns, the picture elements need to be displayed in a suitable target display width range, for example, the target display width range may be 0.3 screen width to 1 / 3 screen width, etc., and this application does not limit this.

[0115] Step 704b: Perform scaling, or scaling and stacking. It is understood that when the size display problem is a magnification problem, the electronic device can perform a reduction process; when the size display problem is a reduction problem, the electronic device can perform a magnification process.

[0116] In some possible embodiments, taking the size display problem as an example of a magnification problem, the electronic device can perform a reduction process on the element to reduce the width of the element to meet the target display width requirement. Figure 8In the area 802 shown in the interface 800b, there is an overlap problem between elements in different columns; after the electronic device performs a zoom-out process on the elements, it may be displayed as Figure 8 The area 601 shown in the interface 600c in FIG. 6 shows that the waterfall display area can be displayed normally. It can be understood that in this embodiment, the distance between each column of elements can be fixed, and the display position of the element can be automatically adjusted as the adjacent element is reduced (or enlarged).

[0117] In some embodiments, the reduction process can be performed by performing a reduction process in the direction of the first coordinate axis and performing a reduction process in the direction of the second coordinate axis; wherein the first coordinate axis direction and the second coordinate axis direction are perpendicular to each other, for example, the first coordinate axis can be the Y axis, and the second coordinate axis can be the X axis. In other embodiments, the reduction process can be performed once for each level of elements in a layer-by-layer recursive manner, or by performing a reduction process on the entire element including at least one level. In some further embodiments, the reduction process can be performed based on a reference point, or can also be performed based on a reference axis; wherein the reference point can include, for example, but is not limited to: the upper center point of the element, the upper left coordinate point, the upper right coordinate point, or the center point of each element, etc., and the reference axis can include, for example, but is not limited to: the center axis of the element, the left side, the right side, etc. It should be noted that the various aspects introduced above can be combined with each other, and the specific implementation process will not be described in detail in this application.

[0118] In some other possible embodiments, after the electronic device performs zooming on the elements, there may be a certain amount of blank space between each column of elements. Figure 8 In the area 803 shown in the interface 800c in the figure, the overlapping problem of the waterfall display area has been solved, but there is a certain blank area between the elements due to the reduction process, resulting in less information displayed in the waterfall display area. At this time, the electronic device can perform stacking processing between the elements, for example, after stacking processing, it can be displayed as Figure 8 In the area 804 shown in the interface 800d, the waterfall flow display area can not only solve the overlapping problem, but also increase the amount of information in the waterfall flow display area.

[0119] In the above embodiment, the electronic device can determine the target stacking value of the element based on the height and reduction ratio of the previous adjacent element in the same column; for example, the target stacking value y of the jth element in the i-th column can be expressed as y=-h i(j-1) *(1-ratio i(j-1) ), where h i(j-1) Can be used to indicate the height of the j-1th element in the i-th column, ratio i(j-1)It can be used to indicate the reduction ratio of the j-1th element in the ith column; wherein the jth element in the ith column may be, for example, the 2nd element in the 1st column, and its target stacking value may be determined according to the height and reduction ratio of the 1st element in the 1st column.

[0120] In addition, in the embodiments of the present application, other possible implementation methods of the reduction processing and stacking processing may also be adopted, and the present application does not limit this.

[0121] 3) Location display problem.

[0122] Step 703c: Determine whether there is a position display problem. For example, after the electronic device performs the process of modifying the number of columns, there may still be a problem that the element is not displayed at the target center position of the corresponding column, for example, it is not displayed in the center of the corresponding column. Fig.11 An interface schematic diagram of a position display problem that may be involved in an application display method provided in an embodiment of the present application. Fig.11 The interface 1100 in the example has a position display problem. Taking the modification to three columns for display as an example, the target center position corresponding to the elements in the first column can be, for example, 1 / 6 of the screen width, the target center position corresponding to the elements in the second column can be, for example, 3 / 6 of the screen width (i.e., the center of the screen), and the target center position corresponding to the elements in the third column can be, for example, 5 / 6 of the screen width. It can be seen from the interface 1100 that the display position of each column of elements has a position display problem of being biased to the right relative to the target position. It should be noted that Fig.11 The target center position of each column shown in the figure is only an example. In actual implementation, factors such as the column spacing, the spacing from the screen edge, etc. may also be considered to determine the target center position.

[0123] Exemplarily, the electronic device may compare the display center position of each column element with the target center position. If they are the same, step 704c may not be performed. If they are not the same, step 704c may be continued. As can be seen from interface 1100, the display center position of each column element is different from the target center position, so it is necessary to perform alignment processing through step 704c.

[0124] Step 704c: perform alignment processing. Fig.11 As shown, Fig.11 Schematic diagram of the interface displayed after the alignment process is shown in interface 1120 in . Exemplarily, the electronic device may determine the offset based on the display center position of each column element and the target display position; then, the electronic device performs translation processing on the element based on the offset. In some embodiments, the offset may be a positive value or a negative value. If the offset is a positive value, the element may be translated to the right, and if the offset is a negative value, the element may be translated to the left.

[0125] It should be noted that, in the embodiments of the present application, the execution order for the three display problems introduced above is not limited. For example, different processes or threads may be used for parallel execution, or the processing for the position display problem may be performed first, or the processing for the truncated display problem may be performed first.

[0126] Through the method provided in the embodiment of the present application, the electronic device can realize the display adjustment of the waterfall flow area included in the application interface, and can improve the degree of adaptation of the waterfall flow display area and the screen size of the electronic device by modifying the number of display columns of the waterfall flow display area. Therefore, there is no need for application developers to perform targeted adaptation for electronic devices with screens of different aspect ratios. The electronic device can adjust the layout of the application developer's application from the perspective of the operating system before displaying it. In this way, there is no need for application developers to perform targeted development for different types of electronic devices, which can reduce the adaptation cost, be applicable to more application scenarios, and can also increase the amount of information displayed in the application interface.

[0127] See also Fig.12 , is a flow chart of an application display method provided in an embodiment of the present application. The method can be applied to an electronic device, and the flow of the method may include at least the following steps:

[0128] Step 1201: In response to a first operation triggered by a user, the electronic device obtains original display data of a first area included in a first application, wherein the original display data includes one or more elements constituting a first area interface of the first area and an original column layout adopted by the one or more elements.

[0129] In some embodiments, the first operation may be an operation for a user to select a target number of columns; or, when the electronic device is a foldable screen mobile phone, the first operation may be an operation for a user to unfold the foldable screen mobile phone; or, the first operation may be an operation for a user to project the mobile phone interface onto a large screen, etc., which is not limited in this application. The first area may be, for example, an area with a multi-column layout such as a waterfall flow area.

[0130] Step 1202: The electronic device displays a second area interface in response to a first instruction; the first instruction is used to instruct the one or more elements to be displayed in a target column layout instead of the original column layout. For example, the original column layout may be 2 columns, and the target column layout may be 3 columns or 4 columns.

[0131] The specific implementation process of the method introduced in step 1201 and step 1202 can refer to the content introduced in the above-mentioned embodiment, which will not be repeated here.

[0132] Based on the above embodiments, the present application further provides an electronic device, the electronic device comprising multiple functional modules; the multiple functional modules interact with each other to implement the methods described in the embodiments of the present application. The multiple functional modules can be implemented based on software, hardware, or a combination of software and hardware, and the multiple functional modules can be arbitrarily combined or divided based on specific implementations. For example, the electronic device can be used to perform the following operations: Fig.12 For the specific implementation process of steps 1201 to 1202 shown, reference can be made to the contents introduced in the aforementioned embodiment, which will not be repeated here.

[0133] Based on the above embodiments, the present application further provides an electronic device, which includes at least one processor and at least one memory, wherein the at least one memory stores computer program instructions, and when the electronic device is running, the at least one processor executes the methods described in the embodiments of the present application. For example, the electronic device can be used to execute Fig.12 The specific implementation process of steps 1201 to 1202 shown can refer to the contents described in the above embodiments, which will not be repeated here. Based on the above embodiments, the present application also provides a computer program, which, when executed on a computer, enables the computer to execute the methods described in the embodiments of the present application.

[0134] Based on the above embodiments, the present application further provides a computer-readable storage medium, in which a computer program is stored. When the computer program is executed by a computer, the computer executes the methods described in the embodiments of the present application.

[0135] Based on the above embodiments, the present application further provides a chip, which is used to read a computer program stored in a memory to implement the methods described in the embodiments of the present application.

[0136] Based on the above embodiments, the present application provides a chip system, which includes a processor for supporting a computer device to implement the methods described in the embodiments of the present application. In one possible design, the chip system also includes a memory, which is used to store the necessary programs and data for the computer device. The chip system can be composed of a chip, or it can include a chip and other discrete devices.

[0137] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.

[0138] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0139] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0140] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0141] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the scope of protection of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.

Claims

1. An application display method, characterized in that: Applied to electronic equipment, the method comprises: In response to a first operation triggered by a user, original display data of a first area included in a first application is acquired, wherein the original display data includes one or more elements constituting a first area interface of the first area, and an original column number layout adopted by the one or more elements; In response to the first instruction, the second area interface is displayed; the first instruction is used to instruct the one or more elements to be displayed in a layout with a target number of columns instead of being displayed in the layout with the original number of columns.

2. The method according to claim 1, characterized in that A first element includes at least two levels, the first element being at least one of the one or more elements; After responding to the first instruction and before displaying the second area interface, the method further includes: It is detected that the first element meets a first condition, where the first condition is used to indicate that a first size of a first level included in the first element is smaller than a second size of a second level; wherein the first level includes the second level; The first level of the first element is expanded from the first size to a third size, the third size being greater than or equal to the second size.

3. The method according to claim 1 or 2, characterized in that: The method further comprises: It is detected that the first element meets a second condition, where the second condition is used to indicate that the first display size information of the first element is larger than the target display size information corresponding to the target column number layout; The first element is reduced from the first display size information to second display size information, where the second display size information is equal to or smaller than the target display size information.

4. The method according to claim 3, characterized in that After reducing the first element from the first display size information to the second display size information, the method further includes: determining a stacking value of a second element according to the first display size information and the second display size information of the first element, the second element being an element located in the same column as the first element when the target number of columns is used for layout, and the stacking value is a negative value; Based on the stacking value, a display position of the second element is adjusted.

5. The method according to any one of claims 1 to 4, characterized in that The method further comprises: It is detected that the first element meets a third condition, where the third condition is used to indicate that the first display position information of the first element is inconsistent with the target display position information corresponding to the target column number layout; determining a deviation value of a display position of the first element according to the first display position information and the target display position information; Based on the deviation value, a display position of the first element is adjusted.

6. The method according to any one of claims 1 to 5, characterized in that The first instruction is an instruction pre-configured by the electronic device; or, The first instruction is a second operation triggered by a user, and the second operation is used to indicate the target column number layout determined by the user.

7. The method according to any one of claims 1 to 6, characterized in that The first area displays the one or more elements in a waterfall layout.

8. An electronic device, characterized in that: It includes an acquisition module and a processing module; wherein, The acquisition module is configured to acquire original display data of a first area included in a first application in response to a first operation triggered by a user, wherein the original display data includes one or more elements constituting a first area interface of the first area, and an original column number layout adopted by the one or more elements; The processing module is used to display the second area interface in response to a first instruction; the first instruction is used to instruct the one or more elements to change from being displayed in the original column layout to being displayed in the target column layout.

9. The electronic device according to claim 8, characterized in that: A first element includes at least two levels, the first element being at least one of the one or more elements; The processing module is further configured to, after responding to the first instruction and before displaying the second area interface, include: It is detected that the first element meets a first condition, where the first condition is used to indicate that a first size of a first level included in the first element is smaller than a second size of a second level; wherein the first level includes the second level; The first level of the first element is expanded from the first size to a third size, the third size being greater than or equal to the second size.

10. The electronic device according to claim 8 or 9, characterized in that: The processing module is further used for: It is detected that the first element meets a second condition, where the second condition is used to indicate that the first display size information of the first element is larger than the target display size information corresponding to the target column number layout; The first element is reduced from the first display size information to second display size information, where the second display size information is equal to or smaller than the target display size information.

11. The electronic device according to claim 10, characterized in that: The processing module is further configured to reduce the first element from the first display size information to the second display size information, comprising: determining a stacking value of a second element according to the first display size information and the second display size information of the first element, the second element being an element located in the same column as the first element when the target number of columns is used for layout, and the stacking value is a negative value; Based on the stacking value, a display position of the second element is adjusted.

12. The electronic device according to any one of claims 8 to 11, characterized in that: The processing module is further used for: It is detected that the first element meets a third condition, where the third condition is used to indicate that the first display position information of the first element is inconsistent with the target display position information corresponding to the target column number layout; determining a deviation value of a display position of the first element according to the first display position information and the target display position information; Based on the deviation value, a display position of the first element is adjusted.

13. The electronic device according to any one of claims 8 to 12, characterized in that: The first instruction is an instruction pre-configured by the electronic device; or, The first instruction is a second operation triggered by a user, and the second operation is used to indicate the target column number layout determined by the user.

14. The electronic device according to any one of claims 8 to 13, characterized in that: The first area displays the one or more elements in a waterfall layout.

15. An electronic device, characterized in that: The system comprises at least one processor coupled to at least one memory, wherein the at least one processor is configured to read a computer program stored in the at least one memory to execute the method according to any one of claims 1 to 7.

16. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, which, when executed on a computer, enable the computer to execute the method according to any one of claims 1 to 7.

17. A computer program product comprising instructions, characterized in that When the computer program product is run on a computer, the computer is caused to execute the method according to any one of claims 1 to 7.