Search

CN-122019025-A - Interface layout method and equipment

CN122019025ACN 122019025 ACN122019025 ACN 122019025ACN-122019025-A

Abstract

The application discloses an interface layout method and equipment, which relate to the technical field of terminals and can reasonably layout elements on a desktop before and after the gesture of terminal equipment changes, so that on one hand, the space of the desktop is fully utilized, and on the other hand, the similarity of the layout of the desktop elements can be ensured to be kept under different gestures, and a user can accurately and quickly find target elements before and after the gesture changes. The display screen of the terminal equipment in the first gesture comprises a first area and a second area in the second gesture, the shapes and the sizes of the first area and the second area are the same, when the terminal equipment detects that the terminal equipment is changed from the first gesture to the second gesture, the first type elements on the desktop in the second gesture are laid out according to the obtained layout of the plurality of elements on the desktop in the first gesture, wherein the plurality of elements comprise the first type elements, and the first type elements comprise elements which are newly added to the first area in the first gesture and/or elements with changed positions in the first area.

Inventors

  • GUO NIAN
  • MING FAN
  • LEI LIANG
  • Bian Zhougang
  • DING ZEQI
  • Liang Shansuo

Assignees

  • 华为技术有限公司

Dates

Publication Date
20260512
Application Date
20250919

Claims (20)

  1. 1. The interface layout method is applied to a terminal device, wherein a display screen of the terminal device in a first posture comprises a first target display area, the first target display area comprises a first area, the first area in the first posture comprises a first area, a display screen of the terminal device in a second posture comprises a second target display area, the second target display area comprises a first area, and the first area in the second posture comprises a second area, and the method comprises the following steps: When the terminal equipment is detected to be changed from the first gesture to the second gesture, first interface layout information is obtained, wherein the first interface layout information characterizes the layout of a plurality of elements on a desktop of the terminal equipment under the first gesture, the first gesture is one of a horizontal screen gesture and a vertical screen gesture, the second gesture is the other of the horizontal screen gesture and the vertical screen gesture, the plurality of elements comprise a first type of elements, the first type of elements comprise M1 elements meeting a first condition, the M1 is an integer greater than or equal to 1, and the elements meeting the first condition comprise elements newly added to the first area under the first gesture and/or elements with changed positions in the first area; And laying out the first type elements on the desktop in the second gesture according to the first interface layout information, wherein in the second gesture, the M1 elements are laid out in the second area.
  2. 2. The method of claim 1, wherein the first region and the second region are both the same shape and size.
  3. 3. The method of claim 1 or 2, wherein the first and second regions each comprise a plurality of cells arranged in rows and columns, the number of cells in the first and second regions being the same, and the number of cells in the first and second regions being the same.
  4. 4. The method of claim 1, wherein the first target display area and the second target display area are areas for laying out target desktop elements in a desktop, the target desktop elements being desktop elements in the desktop other than status bar elements and dock bar elements.
  5. 5. The method of claim 3 or 4, wherein in the first position the first region is to the left of the central axis of the display screen and in the second position the second region is to the left of the central axis of the display screen, or wherein in the first position the first region is to the right of the central axis of the display screen and in the second position the second region is to the right of the central axis of the display screen.
  6. 6. The method of claim 1, wherein the relative positional relationship between the M1 elements in the first pose is the same as the relative positional relationship between the M1 elements in the second pose.
  7. 7. The method of any of claims 1-6, wherein a layout of the M1 elements in the first region in the first pose is the same as a layout in the second region in the second pose.
  8. 8. The method of any one of claims 1-7, wherein the first region further comprises a third region in the first pose and a fourth region in the second pose, the first class of elements further comprising M2 elements satisfying a second condition, the M2 being an integer greater than or equal to 1, wherein the elements satisfying the second condition comprise elements that newly add to the third region in the first pose and/or elements whose positions change in the third region; In the second pose, the M2 elements are laid out in the fourth region.
  9. 9. The method of claim 8, wherein the third region and the fourth region are each the same shape and size.
  10. 10. The method of claim 8 or 9, wherein the third region and the fourth region each comprise a plurality of cells arranged in rows and columns, the number of cells in the third region and the fourth region being the same, and the number of cells in the third region and the fourth region being the same.
  11. 11. The method of claim 1, further comprising determining the first region according to the following rules: when the first gesture is a vertical screen gesture and the second gesture is a horizontal screen gesture, the first target display area comprises a left half area and a right half area which are divided by taking a central axis as a boundary; an overlapping region in a case where an upper left corner of the left half region is aligned with an upper left corner of the second target display region and an upper right corner of the right half region is aligned with an upper right corner of the second target display region is the first region.
  12. 12. The method of any of claims 1-11, wherein the plurality of elements on the desktop of the terminal device in the first pose further comprises a second class of elements that are elements that have not changed in position in the first pose, the method further comprising: when the terminal equipment is detected to change from the first posture to the second posture, second interface layout information is obtained, wherein the second layout information characterizes the layout of a plurality of elements on a desktop of the terminal equipment in the second posture at the last time; and according to the second interface layout information, laying out the second class of elements on the desktop in the second gesture.
  13. 13. The method according to claim 12, wherein a layout of the second-class element laid out according to the second interface layout information is the same as a layout of the second-class element in the second pose last time.
  14. 14. The method according to any one of claims 1-13, characterized in that The first type element on the desktop in the second gesture is laid out according to the first interface layout information, and the first layout strategy comprises that the layout of the M1 elements in the first gesture in the first area is the same as the layout in the second gesture in the second area; The second type elements on the desktop in the second gesture are laid out according to the second interface layout information, wherein the second layout strategy comprises that the layout of the second type elements on the desktop in the first gesture is the same as the layout of the second type elements on the desktop in the second gesture last time; the method further comprises the steps of: And when the determined position of the first element in the first type element is partially or completely overlapped with the determined position of the second element in the second type element, adjusting the position of one element in the first element and the second element to be adjacent idle positions.
  15. 15. The method of any of claims 1-14, wherein the first target display area and the second target display area further comprise a second area, the second area in a first pose comprising a fifth area, the second area in a second pose comprising a sixth area; The plurality of elements further comprises a third class of elements, wherein the third class of elements comprises elements which are newly added to the fifth area by a user in the first gesture and/or elements with positions changed in the fifth area; the method further includes laying out the third class of elements according to the first interface layout information when the terminal device is detected to change from the first posture to the second posture.
  16. 16. The method of claim 15, wherein the laying out the third class of elements according to the first interface layout information comprises: and according to the first interface layout information, the third class element is laid out to the first area in the second gesture.
  17. 17. The method according to claim 15 or 16, characterized in that the method further comprises: Upon detecting a change of the terminal device from the first pose to the second pose, dividing the third class of elements into one or more element sets according to the first interface layout information, the one or more element sets including a first element set; Wherein the relative positional relationship between the plurality of elements in the first element set in the second posture is the same as the relative positional relationship between the plurality of elements in the first element set in the first posture.
  18. 18. The method of claim 17, wherein the one or more partitioned element sets, a plurality of elements in the same element set forming a connected region.
  19. 19. The method of any of claims 15-17, wherein the relative positional relationship between the plurality of elements in each of the sets of elements on the desktop in the second pose is the same as the relative positional relationship between the plurality of elements in the corresponding set of elements on the desktop in the first pose.
  20. 20. The method of any of claims 15-19, wherein the first gesture is a portrait gesture and the elements located to the left and right of the central axis in the fifth region belong to different sets of elements.

Description

Interface layout method and equipment Technical Field The present application relates to the field of terminal technologies, and in particular, to an interface layout method and apparatus. Background In recent years, with the rapid development of flexible display technologies such as folding screens and scroll screens, the use gestures of terminal devices are becoming rich, and various modes such as a keyboard-embedded folding state, a full-screen vertical unfolding state, a full-screen transverse unfolding state, a full-screen book state and the like are continuously emerging. Each gesture corresponds to different screen proportions, interaction scenes and user requirements, so that the layouts of desktop elements such as icons, cards and storage clips are different in face of different equipment gestures such as folding, unfolding, transverse, vertical and the like. When a user rotates the terminal device from a horizontal screen posture to a vertical screen posture, the layout of desktop elements such as icons, cards and storage clips on the desktop often greatly changes, and the change causes difficulty in quickly positioning target elements after the user rotates the screen. Therefore, the similarity and stability of desktop layout under different screen postures are maintained, the continuity of using the terminal equipment by the user in a cross-posture mode can be improved, the cost of desktop management by the user is reduced, and the interaction experience is further improved. At present, a desktop screen-turning layout scheme adopted by terminal equipment aiming at multiple screen postures still has obvious defects, and the similarity and stability of desktop element layout cannot be ensured, so that a user is easy to feel lost when using the desktop screen-turning layout scheme in a posture-crossing manner, and the operation efficiency is reduced. Disclosure of Invention The application provides an interface layout method and equipment, which can reasonably layout elements on a desktop before and after the gesture of a terminal device changes, such as before and after screen turning, on one hand fully utilize the space of the desktop, on the other hand ensure that the terminal device can keep the similarity of the layout of the desktop elements under different gestures, so that a user can accurately and quickly find target elements before and after the gesture of the terminal device changes, and the terminal device is convenient for the user to operate. In order to achieve the above purpose, the application adopts the following technical scheme: The interface layout method comprises the steps of obtaining first interface layout information when the terminal equipment is detected to change from a first posture to a second posture, wherein the first interface layout information represents the layout of a plurality of elements on a desktop of the terminal equipment in the first posture, the first posture is one of the horizontal screen posture and the vertical screen posture, the second posture is the other of the horizontal screen posture and the vertical screen posture, the plurality of elements comprise first elements, the first elements comprise M1 elements meeting first conditions, M1 is an integer larger than or equal to 1, the elements meeting the first conditions comprise the elements in the first posture and/or the first elements in the first area, and the elements in the second area are arranged in the first posture, the elements meeting the first conditions are arranged in the first area, and the first elements are arranged in the second area according to the first layout. Through the technical scheme provided by the first aspect, when the terminal equipment detects that the terminal equipment changes from the first posture to the second posture, the terminal equipment can lay out the first type elements on the desktop under the second posture according to the obtained layout of the plurality of elements on the desktop of the terminal equipment under the first posture. Through the scheme, elements on the desktop can be reasonably arranged before and after the gesture of the terminal equipment changes, such as before and after screen turning, on one hand, the space of the desktop is fully utilized, on the other hand, the terminal equipment is ensured to keep the similarity of the layout of the desktop elements under different gestures, so that a user can accurately and quickly find target elements before and after the gesture of the terminal equipment changes, and the user can operate the terminal equipment conveniently. As an example, a plurality of pages are arranged on a desktop of the terminal equipment, each page contains a plurality of elements, the elements contained in different pages are different, when the terminal equipment changes from a first posture to a second posture, the layout of the plurality of elements on each page can be according to the corresponding first interface