Desktop component editing method, device, equipment and storage medium
By displaying candidate component information on smart terminal devices and allowing users to edit and replace components, the cumbersome desktop component replacement process is solved, enabling quick replacement and custom editing, thus improving the user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- VIVO MOBILE COMM CO LTD
- Filing Date
- 2022-08-29
- Publication Date
- 2026-04-17
AI Technical Summary
In existing technologies, the process of replacing desktop components on smart terminal devices is cumbersome. Users need to delete components before placing new ones, and adjust other components when the component size is not suitable. The operation steps are complicated and the user experience is poor.
This paper provides a method for editing desktop components. It displays candidate component information by receiving user input, allows users to select the target component and enter the editing page, and replaces the original component based on the editing results. It supports quick replacement and custom editing of components.
It reduces the complexity of component editing, provides convenient desktop component editing operations, improves user experience, and supports user-defined desktop component design.
Smart Images

Figure CN115328603B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of human-computer interaction technology, and in particular to a desktop component editing method, apparatus, device, and storage medium. Background Technology
[0002] On the desktop of mobile devices such as smartphones and tablets, application-provided widgets are typically displayed. For example, weather applications can provide a widget to display weather conditions, which is then shown on the desktop. Users can also access the corresponding application's interface by touching the widget and interact with it; users can also view relevant information through the widget, such as getting the local weather conditions using the weather application's widget.
[0003] However, there are many software applications on smart terminal devices at present, and the process of replacing desktop components is quite cumbersome. Users need to delete components before they can place new components. If the size of the new component is not suitable, other components need to be adjusted and the operation repeated. The operation steps are quite cumbersome. The current desktop component editing solution is quite cumbersome, resulting in a poor user experience. Summary of the Invention
[0004] This application provides a desktop component editing method, apparatus, device, and storage medium, which enables rapid replacement of desktop components and provides users with convenient desktop component editing functions.
[0005] In a first aspect, embodiments of this application provide a desktop component editing method, applied to a terminal device, the method comprising:
[0006] When the first component is displayed, receive a first input to the first component;
[0007] In response to the first input, candidate component information is displayed;
[0008] Receive a second input regarding the target component in the candidate component information;
[0009] In response to the second input, the editing page of the target component is displayed;
[0010] Based on the editing results of the editing page of the target component, replace the first component with the target component.
[0011] Secondly, embodiments of this application provide a desktop component editing device, the device comprising:
[0012] The first input receiving unit is configured to receive a first input to the first component when the first component is displayed;
[0013] The first input response unit is used to display candidate component information in response to a first input.
[0014] The second input receiving unit is used to receive a second input to the target component in the candidate component information;
[0015] The second input response unit is used to display the editing page of the target component in response to a second input;
[0016] The component editing unit is used to replace the first component with the target component based on the editing result of the target component.
[0017] Thirdly, embodiments of this application provide an electronic device, which includes:
[0018] A processor and a memory, the memory storing a program or instructions that can run on the processor, the program or instructions, when executed by the processor, implement the steps of the desktop component editing method as described in the first aspect.
[0019] Fourthly, embodiments of this application also provide a readable storage medium storing a program or instructions that, when executed by a processor, implement the steps of the desktop component editing method as described in the first aspect.
[0020] This application embodiment provides users with the ability to quickly edit displayed desktop components. After determining the target component, users enter the editing page, which allows them to edit the target component according to their own needs. This not only reduces the complexity of component editing and provides users with convenient desktop component editing operations, but also supports user-defined desktop components, thus improving the user experience. Attached Figure Description
[0021] Figure 1 A flowchart illustrating the desktop component editing method provided in this application embodiment;
[0022] Figure 2 This is a schematic diagram illustrating the display of an editing page on a smart terminal device according to an embodiment of this application;
[0023] Figure 3 A flowchart illustrating a desktop component editing method provided in another embodiment of this application;
[0024] Figure 4 A flowchart illustrating a desktop component editing method provided in yet another embodiment of this application;
[0025] Figure 5 This is a schematic diagram of the structure of the desktop component editing device provided in the embodiments of this application;
[0026] Figure 6This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application;
[0027] Figure 7 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application. Detailed Implementation
[0028] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the embodiments described herein are for illustrative purposes only and not for limiting the scope of the application. Furthermore, it should be noted that, for ease of description, only the parts relevant to the present application are shown in the accompanying drawings, not the entire structure.
[0029] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity, operation, or object from another entity, operation, or object, and do not necessarily require or imply any such actual relationship or order between these entities, operations, or objects. Furthermore, in the description of this application, "several" means one or more, and "multiple" means two or more.
[0030] The desktop component editing method provided in this application can be executed by terminal devices such as mobile phones and tablets. For ease of understanding, the desktop component editing device is used as an example terminal device in the embodiments for illustrative description.
[0031] Typically, a terminal device has an operating system installed, such as Android or iOS. Several software applications are installed on the terminal device, and corresponding application icons are displayed on the desktop. Desktop widgets are associated with the software applications and can display relevant information about the software applications on the desktop widgets.
[0032] It should be noted that desktop components can include icons, controls, and logos. Besides touch control, users can also control desktop components via voice input. The following description uses touch control as an example to illustrate the solution in this application.
[0033] Figure 1 A flowchart of a desktop component editing method provided in this application embodiment is shown in the figure. The method includes the following steps:
[0034] Step S110: When the first component is displayed, receive the first input to the first component.
[0035] Step S120: In response to the first input, display candidate component information.
[0036] When a user touches a desktop component already displayed on the screen on a terminal device—that is, touches the first component, such as by long-pressing the first component—candidate component information is displayed on the desktop. It can be understood that the first input can be a long press, a swipe, etc. The first input that triggers the display of candidate component information can be predefined by the terminal device's operating system. For example, if the first touch operation is predefined as a long press, when the terminal device receives a long press on a desktop component, it responds by displaying the candidate component information.
[0037] Optionally, candidate components are desktop components provided to users for editing operations such as replacement, merging, or splicing. The candidate component information displayed on the desktop includes relevant information about the candidate components, such as the function type to which the candidate component belongs and the number of desktop components that can currently be edited. Therefore, users can select appropriate candidate components to edit according to their needs.
[0038] Step S130: Receive the second input for the target component in the candidate component information.
[0039] Step S140: In response to the second input, display the editing page of the target component.
[0040] The second input can be a touch operation to select candidate component information. For example, if several options are displayed in the current candidate component information, the user can select the above options, such as by clicking to select any option. When the terminal device receives a touch operation to click one of the options, it executes the corresponding response.
[0041] In one embodiment, the candidate component information includes functional feature tags for the candidate components. Each functional feature tag represents a function type and is associated with a candidate component. For example, the displayed candidate component information includes multiple functional feature tags, each corresponding to a function type such as navigation or music playback. Each functional feature tag is associated with at least one candidate component. For instance, the functional feature tag corresponding to the music playback function type is associated with the desktop components of multiple music applications (such as music application 1, music application 2, etc.) installed on the terminal device. Therefore, users can filter desktop components with certain function types by using the functional feature tags, and then perform editing operations such as replacing or merging them.
[0042] Optionally, each software application, when installed on a terminal device, is assigned a function type based on its implemented functions. Therefore, the desktop widget corresponding to that software application is associated with a function feature tag. The number of desktop widgets associated with a function feature tag is related to the number of software applications of that function type installed on the terminal device.
[0043] Therefore, the terminal device can display candidate component information on the desktop via dialog boxes or pop-ups. After the user selects a feature tag from the displayed candidate component information, the terminal device recognizes the selected feature tag and displays the corresponding candidate component associated with that feature tag. The user can select any candidate component as the target component from the displayed candidate components to edit the desktop component on the editing page.
[0044] For example, if a feature tag corresponding to the music playback function type is selected, the corresponding candidate components for the music applications installed on the terminal device will be displayed. The number of candidate components is the same as the number of music applications installed. Users can select the desired candidate components themselves. For example, when selecting a candidate component corresponding to music application 1, the terminal device uses that candidate component as the target component and generates an editing page corresponding to the target component. This allows users to edit the target component on the editing page, thereby determining the display attributes of the target component on the desktop, such as size and the range of the displayed component area.
[0045] It should be noted that, in one embodiment, the candidate component information may include multiple candidate components, that is, multiple selectable candidate components are displayed on the desktop, such as in the form of pop-up windows or dialog boxes, for the user to select, and an editing page corresponding to the target component is generated using the candidate component selected by the user as the target component, thereby realizing the editing of the target component.
[0046] Step S150: Replace the first component with the target component based on the editing results of the target component's editing page.
[0047] Understandably, the terminal device can display the edited target component on the desktop based on the user's edits on the editing page, simultaneously delete the desktop component, and then display the target component in its corresponding position. It should be considered that the deletion of the desktop component could be automatically performed by a built-in application of the operating system; that is, after determining the target component to display, the operating system would delete the desktop component.
[0048] As can be seen from the above solution, the embodiments of this application can provide users with the function of quickly editing the displayed desktop components. After determining the target component, the user enters the editing page so that the user can re-edit the target component according to their own needs. This not only reduces the complexity of component editing and provides users with convenient desktop component editing operations, but also supports user-defined desktop components, thus improving the user experience.
[0049] Optionally, the size of the target component can be adjusted according to the size of the first component. This can be done by scaling the target component to make its size the same as the size of the first component, or by making the size of the target component proportional to the size of the first component.
[0050] Figure 2 The figure shows a schematic diagram of an intelligent terminal device displaying an editing page according to an embodiment of this application. As shown, the editing page includes a display area, an editing area, and a preview area. The display area is used to display desktop components to be edited, such as a target component or a first component. The editing area is used to maintain, reduce, or enlarge the size of the target component. The preview area is used to display a preview effect of maintaining, reducing, or enlarging the size of the target component.
[0051] In one embodiment, for the target component that needs to be edited, the target component is displayed in a display area on the editing page, such as at a preset size. It is understood that different target components have preset sizes according to the operating system. The user can edit the size of the target component in the editing area; that is, the size of the target component can be maintained, reduced, or enlarged through the editing area on the editing page. Correspondingly, the edit preview result after scaling the target component can be displayed synchronously in the preview area. As shown in the diagram, the edit preview result is the same as the final desktop component displayed after editing, allowing the user to confirm whether the editing operation was correct.
[0052] It is conceivable that after the preview area displays the edit preview effect of the target component, the editing page can also display multiple option controls for confirming the editing results, such as displaying an option control for confirmation and an option control for cancellation. Users can confirm the editing results by touching the option controls, so that the edited target component is displayed on the desktop. Alternatively, users can also cancel the editing results by touching the option controls, so as to re-edit the target component.
[0053] The target component displayed within the display area comprises at least one cell. The terminal device divides the target component within the display area into at least one cell according to a preset division rule. That is, the target component displayed within the display area is divisible; for example, any number of cells can be selected to enter the editing area. It should be noted that the number of cells after division can be determined based on the size of the target component. One cell can be the minimum size specification defined by the operating system. Therefore, the size of the desktop component is determined by the number and arrangement of the cells. For example, for a target cell with a size of 2*2, displayed within the display area, the target component can be divided into four cells arranged in two rows and two columns. Furthermore, the editing area includes a zoomable sub-area and a non-zoomable sub-area, and the sum of the sizes of the zoomable and non-zoomable sub-areas is the same as the size of the first component.
[0054] The editing page displayed on the terminal device provides users with an interactive interface for editing components. Users can move the target component displayed in the display area to the editing area according to their editing needs, thereby satisfying their editing requirements and realizing the customized design of the component, which helps to improve the user experience.
[0055] Figure 3 A flowchart of a desktop component editing method provided in another embodiment of this application is shown in the figure. The desktop component editing method further includes:
[0056] Step S310: In response to a third input to the display area, determine at least one cell of the target component as the target cell.
[0057] Understandably, the display area on the editing page is divided into sections based on preset cell sizes. Multiple lines (such as dashed lines or dotted lines) distinguish the cells within the displayed area. Therefore, users can select cells to place in either a scaled or non-scaled sub-area.
[0058] When a third input is received from the user on the editing page displayed on the terminal device, the third input is a selection operation on the cell. For example, the user can click on some cells on the target component, and the terminal device can determine that the selected cells are the target cells. It can be assumed that the target cell includes at least one cell of the target component, and the user can select all cells of the target component, that is, select the entire target component for scaling.
[0059] Step S320: In response to the fourth input to the target cell, move the target cell to the scaling sub-region, and shrink or enlarge the target cell that has entered the scaling sub-region according to the size of the target cell and the size of the scaling sub-region.
[0060] In response to the user's fourth input to the target cell, the terminal device can determine that the target cell has moved to a sub-region within the editing area, such as determining that the target cell has entered a zoom sub-region.
[0061] Understandably, when a user moves a target cell into a zoomable sub-region, scaling the target cell within that sub-region should be considered. The content displayed on the target cell should also change size accordingly. This can be achieved by determining the zoom ratio of the zoomable sub-region based on the sizes of both the target cell and the zoomable sub-region, thus scaling the target cell and its corresponding content accordingly. It's important to note that if a user selects a portion of the target component's cells as the target cell for scaling, the scaling effect does not affect the display of the target component within the main display area. However, the portion of the target cell corresponding to the zoomable sub-region in the preview area will display the scaled-down or enlarged version of the target cell.
[0062] In one embodiment, when scaling the target cell within a scaling sub-region, it is necessary to identify the number of rows and columns of cells in the scaling sub-region, that is, to identify the number of rows and columns occupied by the cells included in the size corresponding to the scaling sub-region, namely the number of rows and columns of the first cell. It is also necessary to identify the number of rows and columns of the target cell to determine the number of rows and columns occupied by the cells included in the target cell, namely the number of rows and columns of the second cell.
[0063] Therefore, by determining the scaling ratio based on the number of rows in the first cell, the number of columns in the first cell, the number of rows in the second cell, and the number of columns in the second cell, the scaling ratio in both the horizontal and vertical directions can be determined, thereby scaling the content of the target component displayed in the target cell according to the scaling ratio.
[0064] For example, the scaling sub-region consists of two horizontally arranged cells, meaning the size of the scaling sub-region is 1*2. The two cells are arranged in one row and two columns, meaning the first cell has 1 row and 2 columns. The target cell consists of four cells, such as a target cell with a size of 2*2, meaning the four cells are arranged in two rows and two columns, meaning the second cell has 2 rows and 2 columns. Therefore, scaling the target cell is a vertical reduction, and the content of the target component displayed in the target cell is reduced vertically at a scaling ratio of 2:1, so that the size of the target cell and the corresponding displayed content can fill the scaling sub-region.
[0065] Therefore, users can zoom in or out of the target cell by scaling the sub-region to meet their personalized editing needs for the target component. Furthermore, the terminal device using the desktop component editing method provided in this application can provide users with a quick and convenient editing method, making it easy for users to edit the component.
[0066] Figure 4 A flowchart of a desktop component editing method provided in another embodiment of this application is shown in the figure. The desktop component editing method further includes:
[0067] Step S410: In response to a third input to the display area, determine at least one cell of the target component as the target cell.
[0068] Step S420: In response to the fourth input to the target cell, move the target cell to the non-scaling sub-region and hold the target cell in the non-scaling sub-region according to the size of the target cell and the size of the non-scaling sub-region.
[0069] Similarly, when a third input is received from the user on the editing page displayed on the terminal device, the third input is a selection operation on the cell, such as the user clicking on part of the cells on the target component. The terminal device can determine the selected target cell. The target cell includes at least one cell of the target component, and the user can select all cells of the target component, that is, select the entire target component and place it in the non-scaling sub-area.
[0070] Understandably, when a user moves the target cell into a non-scalable sub-region, the non-scalable sub-region does not perform shrinking or scaling operations on the target cell, but instead fixes the size of the target cell and the content of the corresponding target component, that is, it preserves the target cell.
[0071] In one embodiment, when the target cell moves to a non-scalable sub-region, it is necessary to identify the number of rows and columns of cells in the non-scalable sub-region, that is, to identify the number of rows and columns occupied by the cells included in the size corresponding to the non-scalable sub-region, such as the number of rows and columns of the third cell. It is also necessary to identify the number of rows and columns of the target cell, that is, to determine the number of rows and columns occupied by the cells included in the target cell, such as the number of rows and columns of the second cell.
[0072] Furthermore, if the number of rows in the second cell is less than or equal to the number of rows in the third cell, and the number of columns in the second cell is less than or equal to the number of columns in the third cell, the fourth touch operation is a valid operation, thereby ensuring that the target cell entering the non-scalable sub-area maintains its current size and displayed content.
[0073] If the number of rows in the second cell is greater than the number of rows in the third cell, or the number of columns in the second cell is greater than the number of columns in the third cell, the non-scalable sub-region will not respond to the target cell. In other words, the fourth touch operation is invalid; no response is made, no editing is performed on the target cell, and the corresponding preview effect is not displayed in the preview area. It should be noted that the terminal device can also inform the user via a pop-up window or dialog box that the current operation is invalid and that excessively large target cells cannot be placed in the non-scalable sub-region.
[0074] For example, a non-scalable sub-region consists of two horizontally arranged cells, meaning the size of the non-scalable sub-region is 1x2. These two cells are arranged in a row and two columns, with the third cell having 1 row and 2 columns. The target cell consists of one cell, meaning the size of the target cell is 1x1, arranged in a row and one column, with the second cell having 1 row and 1 column. Therefore, the target cell entering the non-scalable sub-region maintains its current size and displayed content. It's conceivable that when the size of the target cell is larger than the size of the non-scalable sub-region—that is, one of the number of rows or columns in the target cell is greater than the corresponding number of rows and columns in the non-scalable sub-region—the user cannot move the target cell to the non-scalable sub-region.
[0075] Therefore, users can retain target cells that do not need to be edited through non-scaling sub-regions to meet users' personalized editing needs for target components. Furthermore, terminal devices that apply the desktop component editing method provided in this application can provide users with a quick and convenient editing method, making it easy for users to edit components.
[0076] In one embodiment, the sum of the sizes of the scaled sub-region and the non-scaled sub-region is the same as the size of the first component. For example, the size of the first component is 1*3, that is, the cells included in the desktop component are arranged in a row and three columns. Correspondingly, the size of the scaled sub-region can be 1*2, that is, the cells included in the scaled sub-region are arranged in a row and two columns. Then the size of the non-scaled sub-region is 1*1, that is, the cells included in the non-scaled sub-region are arranged in a row and one column, so that the sum of the sizes of the scaled sub-region and the non-scaled sub-region is the same as the size of the first component.
[0077] Furthermore, the sizes of both the zoomable and non-zoomable sub-regions can be dynamically adjusted. When the user makes a fifth input to either the zoomable or non-zoomable region, the sizes of the zoomable and non-zoomable sub-regions are dynamically adjusted in response to the fifth input.
[0078] For example, a user can select and drag the boundaries of the zoomable area to adjust its size. If the current desktop component is 1x3 and the zoomable area is 1x2, in response to a fifth touch operation that shrinks the zoomable area, the zoomable area shrinks, for example, to 1x1. Correspondingly, the non-zoomable area expands, for example, to 1x2, so that the sum of the sizes of the zoomable and non-zoomable areas is equal to the current desktop component size.
[0079] As can be seen from the above solution, users can dynamically adjust the size of the zoomable and non-zoomable sub-regions to meet their usage needs and provide them with a good interactive experience.
[0080] In one embodiment, for the combination of desktop components and target components (such as merging, splicing, etc.), the target component and desktop component can be displayed together on the editing page after selecting candidate component information and determining the target component. That is, the target component and desktop component are displayed in the display area of the editing page. Users can perform scaling or holding operations on the target component and desktop component, such as selecting the target component and desktop component to put into the editing area, or selecting part of the target component and desktop component to put into the editing area, thereby merging the desktop component and target component, and displaying the combined editing result on the desktop.
[0081] For example, after displaying candidate component information, for the target component selected by the sixth input (such as a touch operation on the target component in the candidate component information), the target component and the first component are displayed simultaneously on the displayed editing page. For example, the target component and the first component are displayed in the display area of the editing page, and both the target component and the first component displayed in the display area can be separated.
[0082] Therefore, users can merge and combine the target component and the first component. For example, by selecting part or all of the cells of both the target component and the first component, and then scaling them up or down through the editing area, they can combine (e.g., merge or combine) them to form a new display component. The new display component, as the result of the editing page, replaces the first component on the terminal device's display interface, making it convenient for users to combine desktop components and the target component.
[0083] In one embodiment, before displaying candidate component information, options for editing corresponding components, such as replacement or merging operations, can be displayed via pop-ups or dialog boxes. Users can select the appropriate options to enable the terminal device to perform different editing operations on desktop components, thereby providing corresponding display content on the editing page.
[0084] For example, if the user selects the replace operation, the target component is displayed in the editing page's display area; if the user selects the merge operation, the target component and the original desktop component (i.e., the component already displayed on the desktop, such as the first component) are displayed in the editing page's display area. It's conceivable that when the target component or the original desktop component is large, a thumbnail of the target component or the original desktop component can be displayed accordingly in the display area.
[0085] In one embodiment, the target component and the original desktop component are displayed in the display area of the editing page, and the user can determine the operation to be performed. For example, if the user only operates on the target component, such as moving the target component into a zoomed sub-area or a non-zoomed sub-area, then the operation performed by the user can be determined as a replacement operation; if the user operates on both the target component and the original desktop component, such as moving the target component into a zoomed sub-area and also moving the original desktop component to the zoomed sub-area, then the operation performed by the user can be determined as a merge operation.
[0086] Optionally, a portion of the target component can be moved to a specific position in the first component, allowing a portion of the target component to replace a portion of the first component, effectively concatenating the target and first components. This can be achieved by splitting the first component into multiple cells, determining which cells to retain and which to replace; similarly, the target component can be split into multiple cells, determining which cells to replace, thus allowing a portion of the target component to replace a portion of the first component.
[0087] In one application scenario, when a user needs to replace the current desktop widget corresponding to the weather app with a desktop widget corresponding to the music app, the user can long-press the desktop widget corresponding to the weather app to display candidate widget information on the desktop. This candidate widget information includes function-specific tags for the corresponding music app. After the user clicks to select the corresponding function tag, a pop-up window will display multiple desktop widgets (i.e., candidate widgets) corresponding to different music apps.
[0088] Users can select a target component from the candidate components to display an editing page on the desktop, allowing them to edit the target component's display properties. The target component is displayed in the editing page's display area, and this target component is divided into multiple splittable cells for the user to select from.
[0089] Users can select a suitable cell or move the entire target component to the editing area for editing. If placed in a scaling sub-area, the selected cell is scaled; if placed in a non-scaling sub-area, the content of the selected cell is fixed. The editing results are simultaneously displayed in the preview area so users can confirm the effect. After the user confirms the editing is complete, the edited target component is displayed on the desktop, replacing the corresponding desktop component for the weather application.
[0090] Figure 5 This is a schematic diagram of the desktop component editing device provided in an embodiment of this application, with reference to... Figure 5 This device can be applied to terminal devices and is used to execute the desktop component editing method provided in the above embodiments, possessing corresponding functions and beneficial effects. The device includes:
[0091] The first input receiving unit 501 is used to receive a first input to the first component when the first component is displayed;
[0092] The first input response unit 502 is used to display candidate component information in response to a first input;
[0093] The second input receiving unit 503 is used to receive a second input to the target component in the candidate component information;
[0094] The second input response unit 504 is used to display the editing page of the target component in response to the second input;
[0095] The component editing unit 505 is used to replace the first component with the target component based on the editing result of the target component.
[0096] Optionally, the candidate component information includes functional characteristic labels of the candidate components; correspondingly, the first input response unit 502 is also used for:
[0097] Identify the selected feature labels;
[0098] Display at least one candidate component associated with the selected feature label;
[0099] Based on the selection of at least one candidate component, the target component is determined, and the editing page for the target component is displayed.
[0100] Optionally, the editing page of the target component includes: a display area, an editing area, and a preview area. The component editing unit 505 is also used for:
[0101] The target component is displayed in the display area according to its preset size;
[0102] Maintain, shrink, or enlarge the size of the target component within the editing area;
[0103] Display the edit preview results of the target component in the preview area.
[0104] Optionally, the target component within the display area includes at least one cell; the editing area includes a zoomable sub-region and a non-zoomable sub-region, and the sum of the sizes of the zoomable sub-region and the non-zoomable sub-region is the same as the size of the first component;
[0105] The component editing unit 505 is also used for:
[0106] In response to a third input to the display area, at least one cell of the target component is identified as the target cell;
[0107] In response to the fourth input to the target cell, the target cell is moved to the scaling sub-region, and the target cell that has entered the scaling sub-region is shrunk or enlarged according to the size of the target cell and the size of the scaling sub-region.
[0108] or,
[0109] In response to a fourth input to the target cell, the target cell is moved to a non-scaling sub-region, and the target cell is held in the non-scaling sub-region based on the size of the target cell and the size of the scaling sub-region.
[0110] Optionally, the component editing unit 505 is also used for:
[0111] Get the number of rows and columns of the first cell in the scaled sub-region, and the number of rows and columns of the second cell in the target cell;
[0112] The scaling ratio is determined based on the ratio of the number of rows and columns in the first cell, the number of rows in the second cell, and the number of columns in the second cell.
[0113] The size of the target cell and the content of the corresponding target component are reduced or enlarged according to the scaling ratio.
[0114] Optionally, the component editing unit 505 is also used for:
[0115] Get the number of rows and columns of the second cell in the target cell, as well as the number of rows and columns of the third cell in the non-scaled sub-region;
[0116] If the number of rows in the second cell is less than or equal to the number of rows in the third cell and the number of columns in the second cell is less than or equal to the number of columns in the third cell, then the content of the target component corresponding to the target cell will be displayed in the non-scaling area.
[0117] If the number of rows in the second cell is greater than the number of rows in the third cell, or the number of columns in the second cell is greater than the number of columns in the third cell, then the target cell will not be responded to in the non-scalable sub-region.
[0118] Optionally, the sum of the sizes of the scaled and non-scaled sub-regions is the same as the size of the desktop component; the component editing unit 505 is also used for:
[0119] In response to a fifth input on either a scaled or non-scaled sub-region, adjust the size of the scaled or non-scaled sub-region.
[0120] Based on the above embodiments, the second input receiving unit 503 is further configured to receive a sixth input on the target component in the candidate component information;
[0121] The second input response unit 504 is also configured to respond to the sixth input by displaying an editing page including the target component and the first component;
[0122] The component editing unit 505 is also used to replace the first component with a display component that combines the target component and the first component, based on the editing results of the editing page.
[0123] It is worth noting that in the embodiments of the desktop component editing device described above, the various units and modules included are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be achieved; in addition, the specific names of each functional unit are only for easy differentiation and are not used to limit the scope of protection of the present invention.
[0124] Optionally, Figure 6 This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application, as shown below. Figure 6 As shown, this application embodiment also provides an electronic device 610, including a processor 611 and a memory 612. The memory 612 stores a program or instructions that can run on the processor 611. When the program or instructions are executed by the processor 611, they implement the various steps of the desktop component editing method embodiment described above and can achieve the same technical effect. To avoid repetition, they will not be described again here.
[0125] It should be noted that the electronic devices in the embodiments of this application include mobile electronic devices and non-mobile electronic devices.
[0126] Figure 7 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application.
[0127] The electronic device 700 includes, but is not limited to, components such as: radio frequency unit 701, network module 702, audio output unit 703, input unit 704, sensor 705, display unit 706, user input unit 707, interface unit 708, memory 709, and processor 710.
[0128] Those skilled in the art will understand that the electronic device 700 may also include a power supply (such as a battery) for supplying power to various components. The power supply may be logically connected to the processor 710 through a power management system, thereby enabling functions such as managing charging, discharging, and power consumption through the power management system. Figure 7 The electronic device structure shown does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown, or combine certain components, or have different component arrangements, which will not be elaborated here.
[0129] User input unit 707 is used to receive a first input to the first component, and processor 710 is used to control display unit 706 to display candidate component information in response to the first input. User input unit 707 is also used to receive a second input to a target component in the candidate component information, and processor 710 is used to control display unit 706 to display the editing page of the target component in response to the second input, and replace the first component with the target component according to the editing result of the editing page of the target component.
[0130] It should be understood that, in this embodiment, the input unit 704 may include a graphics processing unit (GPU) 7041 and a microphone 7042. The GPU 7041 processes image data of still images or videos obtained by an image capture device (such as a camera) in video capture mode or image capture mode. The display unit 706 may include a display panel 7061, which may be configured in the form of a liquid crystal display, an organic light-emitting diode, or the like. The user input unit 707 includes at least one of a touch panel 7071 and other input devices 7072. The touch panel 7071 is also called a touch screen. The touch panel 7071 may include a touch detection device and a touch controller. Other input devices 7072 may include, but are not limited to, physical keyboards, function keys (such as volume control buttons, power buttons, etc.), trackballs, mice, and joysticks, which will not be described in detail here.
[0131] The memory 709 can be used to store software programs and various data. The memory 709 may primarily include a first storage area for storing programs or instructions and a second storage area for storing data. The first storage area may store the operating system, application programs or instructions required for at least one function (such as sound playback, image playback, etc.). Furthermore, the memory 709 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus RAM (DRRAM). The memory 709 in the embodiments of this application includes, but is not limited to, these and any other suitable types of memory.
[0132] Processor 710 may include one or more processing units; optionally, processor 710 integrates an application processor and a modem processor, wherein the application processor mainly handles operations involving the operating system, user interface, and applications, and the modem processor mainly handles wireless communication signals, such as a baseband processor. It is understood that the aforementioned modem processor may also not be integrated into processor 710.
[0133] This application also provides a readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various processes of the desktop component editing method embodiments described above and achieve the same technical effects. To avoid repetition, they will not be described again here.
[0134] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.
[0135] This application embodiment also provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement the various processes of the above-described desktop component editing method embodiment and can achieve the same technical effect. To avoid repetition, it will not be described again here.
[0136] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.
[0137] This application provides a computer program product that is stored in a storage medium and executed by at least one processor to implement the various processes of the desktop component editing method embodiment described above, and achieves the same technical effect. To avoid repetition, it will not be described again here.
[0138] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
[0139] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0140] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.
Claims
1. A method of editing a desktop component, characterized by, Applied to a terminal device, the method includes: When the first component is displayed, receive a first input to the first component; In response to the first input, candidate component information is displayed; Receive a second input regarding the target component in the candidate component information; In response to the second input, the editing page of the target component is displayed; Based on the editing results of the editing page of the target component, replace the first component with the target component; The editing page of the target component includes a display area, an editing area, and a preview area; The step of replacing the first component with the target component based on the editing result of the editing page of the target component includes: The target component is displayed in the display area according to its preset size. The size of the target component can be maintained, reduced, or enlarged within the editing area; The preview area displays the edit preview result of the target component; Furthermore, the target component within the display area includes at least one cell, the editing area includes a zoomable sub-area and a non-zoomable sub-area, and the sum of the sizes of the zoomable sub-area and the non-zoomable sub-area is the same as the size of the first component; The step of maintaining, reducing, or enlarging the size of the target component in the editing area includes: In response to a third input to the display area, at least one cell of the target component is determined to be a target cell; In response to a fourth input to the target cell, the target cell is moved to a scaling sub-region, and the target cell entering the scaling sub-region is scaled down or enlarged according to the size of the target cell and the size of the scaling sub-region; or, In response to a fourth input to the target cell, the target cell is moved to a non-scaling sub-region, and the target cell entering the non-scaling sub-region is held based on the size of the target cell and the size of the non-scaling sub-region.
2. The method of claim 1, wherein, The candidate component information includes functional characteristic tags of the candidate components; The second input in response to candidate component information, displaying the editing page of the target component, includes: Identify the selected feature labels; Display at least one candidate component associated with the selected feature label; Based on the selection of at least one of the candidate components, a target component is determined, and an editing page for the target component is displayed.
3. The method of claim 1, wherein, In response to a fourth input to the target cell, moving the target cell to a scaling sub-region, and scaling the target cell within the scaling sub-region according to the size of the target cell and the size of the scaling sub-region, includes: Obtain the number of rows and columns of the first cell in the scaled sub-region, and the number of rows and columns of the second cell in the target cell; The scaling ratio is determined based on the ratio of the number of rows and columns in the first cell, the number of rows in the second cell, and the number of columns in the second cell. The size of the target cell and the content of the displayed target component are reduced or enlarged according to the scaling ratio.
4. The method of claim 1, wherein, In response to a fourth input to the target cell, moving the target cell to a non-scaling sub-region, and maintaining the target cell within the non-scaling sub-region based on the size of the target cell and the size of the non-scaling sub-region, includes: Obtain the number of rows and columns of the second cell in the target cell, as well as the number of rows and columns of the third cell in the non-scaling sub-region; If the number of rows in the second cell is less than or equal to the number of rows in the third cell and the number of columns in the second cell is less than or equal to the number of columns in the third cell, then the size of the target cell and the content of the target component are displayed in the non-scalable sub-area. If the number of rows in the second cell is greater than the number of rows in the third cell, or if the number of columns in the second cell is greater than the number of columns in the third cell, then the non-scalable sub-region will not respond to the target cell.
5. The method of claim 1, wherein, Also includes: In response to a fifth input to the scaled sub-region or the non-scaled sub-region, the size of the scaled sub-region and the non-scaled sub-region are adjusted.
6. The method of claim 1, wherein, After responding to the first input and displaying candidate component information, the method further includes: Receive a sixth input regarding the target component in the candidate component information; In response to the sixth input, an editing page including the target component and the first component is displayed; Based on the editing results of the editing page, the first component is replaced with a display component that combines the target component and the first component.
7. A desktop component editing device, characterized in that, Applied to a terminal device, the device includes: The first input receiving unit is configured to receive a first input to the first component when the first component is displayed; The first input response unit is used to display candidate component information in response to a first input. The second input receiving unit is used to receive a second input to the target component in the candidate component information; The second input response unit is used to display the editing page of the target component in response to a second input; A component editing unit is used to replace the first component with the target component based on the editing result of the target component; The editing page of the target component includes a display area, an editing area, and a preview area; The component editing unit is also used for: The target component is displayed in the display area according to its preset size. The size of the target component can be maintained, reduced, or enlarged within the editing area; The preview area displays the edit preview result of the target component; Furthermore, the target component within the display area includes at least one cell, the editing area includes a zoomable sub-area and a non-zoomable sub-area, and the sum of the sizes of the zoomable sub-area and the non-zoomable sub-area is the same as the size of the first component; The component editing unit is also used for: In response to a third input to the display area, at least one cell of the target component is determined to be a target cell; In response to a fourth input to the target cell, the target cell is moved to a scaling sub-region, and the target cell entering the scaling sub-region is scaled down or enlarged according to the size of the target cell and the size of the scaling sub-region; or, In response to a fourth input to the target cell, the target cell is moved to a non-scaling sub-region, and the target cell entering the non-scaling sub-region is held based on the size of the target cell and the size of the non-scaling sub-region.
8. An electronic device, comprising: include: A processor and a memory, the memory storing a program or instructions executable on the processor, the program or instructions, when executed by the processor, implementing the steps of the desktop component editing method as described in any one of claims 1-6.
9. A readable storage medium, characterized by, The readable storage medium stores a program or instructions that, when executed by a processor, implement the steps of the desktop component editing method as described in any one of claims 1-6.
Citation Information
Patent Citations
Page control management method and device, computer equipment and storage medium
CN114116054A
Widget display method and electronic equipment
CN114860136A
File processing method, intelligent terminal and storage medium
CN114860674A