Table processing method and device, electronic equipment and storage medium

By responding to the split instructions for target cells in the spreadsheet processing software and determining and executing the splitting strategy, the problem of cumbersome cell splitting operations in the existing technology is solved, and a more efficient and convenient table processing experience is achieved.

CN119598987APending Publication Date: 2025-03-11ZHUHAI KINGSOFT OFFICE SOFTWARE +2
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411608566.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-12
Publication Date
2025-03-11

AI Technical Summary

Technical Problem

Existing spreadsheet processing software is cumbersome to operate, inefficiently and has poor user experience during cell splitting.

Method used

By responding to the split instruction to the target cell in the table, determine the target split strategy and split the target cell according to the strategy to obtain at least two split cells and replace the original cell with them.

Benefits of technology

It realizes a flexible and convenient way to split cells, improves the flexibility and editability of tables, and provides a more convenient and efficient table processing experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119598987A_ABST
    Figure CN119598987A_ABST
Patent Text Reader

Abstract

The invention relates to a table processing method and device, equipment and a storage medium, and the method comprises the steps: responding to a splitting instruction for a target cell in a table, and determining a target splitting strategy indicated by the splitting instruction; splitting the target cell according to the target splitting strategy to obtain at least two split cells; and replacing the target cell with the at least two split cells. Therefore, a flexible and convenient table cell splitting mode is realized, and by applying the mode, the flexibility and editability of the table can be improved, and more convenient and efficient table processing experience is provided for users.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computers, and in particular to a table processing method, device, electronic device and storage medium. Background Art

[0002] In existing spreadsheet processing software, when it comes to splitting a cell into multiple cells, especially when it comes to splitting a minimum cell into multiple cells, users need to insert new cells through traditional menu options or complex keyboard shortcut combinations, and manually adjust the layout structure of the table to achieve a visual cell splitting effect.

[0003] It can be seen that the existing cell splitting method is not intuitive, especially in complex situations, where users need to perform cell insertion operations and table layout adjustment operations multiple times, resulting in cumbersome operations and low efficiency. Summary of the invention

[0004] The present application provides a table processing method, device, electronic device and storage medium to solve the technical problems in the prior art of using an indirect method to achieve cell splitting effects, which is cumbersome, inefficient and has a poor user experience.

[0005] In a first aspect, the present application provides a table processing method, the method comprising:

[0006] In response to a split instruction for a target cell in a table, determining a target split strategy indicated by the split instruction;

[0007] Splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0008] The target cell is replaced by the at least two split cells.

[0009] In a possible implementation manner, the target cell is split according to the target splitting strategy to obtain at least two split cells, including:

[0010] Divide the original cell content into different content blocks according to the set rules;

[0011] Based on the number and distribution of the content blocks, the target cell is split to obtain at least two split cells.

[0012] In a possible implementation manner, the target cell is split according to the target splitting strategy to obtain at least two split cells, including:

[0013] Displaying a split line in the target cell;

[0014] In response to a drag operation on the split line, moving the split line in the target cell;

[0015] The target cell is split based on the position of the split line to obtain at least two split cells.

[0016] In a possible implementation, displaying a split line in the target cell includes:

[0017] Determine the target split mode;

[0018] A split line matching the target split pattern is displayed in the target cell.

[0019] In a possible implementation manner, after the splitting line is moved in the target cell in response to the dragging operation on the splitting line, the method further includes:

[0020] A preview effect of the split cells obtained by splitting the target cell based on the current position of the split line is displayed.

[0021] In a possible implementation manner, after splitting the target cell based on the position of the split line to obtain at least two split cells, the method further includes:

[0022] Splitting the original cell content in the target cell based on the position of the split line to obtain at least two split contents;

[0023] Each of the split contents is filled into the corresponding split cells respectively.

[0024] In a possible implementation manner, the splitting of the original cell content in the target cell based on the position of the split line to obtain at least two split contents includes:

[0025] Classifying the original cell contents on both sides of the split line in the target cell into different content groups respectively;

[0026] And, in the case where it is determined that part of the original cell content in the target cell is located on the split line, the part of the original cell content is classified into one of the content groups, or the part of the original cell content is divided into different content blocks, and different content blocks are classified into different content groups;

[0027] Each of the content groups is determined as a split content to obtain at least two split contents.

[0028] In a possible implementation manner, filling each of the split contents into the corresponding split cells respectively includes:

[0029] Each of the split contents is filled into the corresponding split cell according to the original cell style of the target cell.

[0030] In a possible implementation manner, after filling each of the split contents into the corresponding split cells respectively, the method further includes:

[0031] The size of the split cell is adjusted according to the filling content in the split cell.

[0032] In a possible implementation manner, after the target cell is split according to the target splitting strategy to obtain at least two split cells, the method further includes:

[0033] In the case where it is determined that splitting the target cell affects adjacent cells of the target cell, adding a new cell to the table according to the at least two split cells, and determining cells to be merged;

[0034] The cells to be merged are merged to obtain corresponding merged cells.

[0035] In a possible implementation manner, before splitting the target cell according to the target splitting strategy to obtain at least two split cells, the method further includes:

[0036] Detecting whether the target cell meets a preset splitting condition;

[0037] When it is determined that the target cell satisfies the splitting condition, executing the step of splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0038] When it is determined that the target cell does not satisfy the splitting condition, a prompt message indicating that splitting of the target cell is prohibited is output.

[0039] In a possible implementation manner, after the target cell is split according to the target splitting strategy to obtain at least two split cells, the method further includes:

[0040] In response to the split undo operation on the target cell, the original cell layout of the target cell is restored.

[0041] In a second aspect, the present application provides a table processing device, the device comprising:

[0042] A splitting strategy determination module, configured to determine, in response to a splitting instruction for a target cell in a table, a target splitting strategy indicated by the splitting instruction;

[0043] A cell splitting module, used to split the target cell according to the target splitting strategy to obtain at least two split cells;

[0044] The cell display module is used to replace the target cell with the at least two split cells.

[0045] In a possible implementation, the cell splitting module includes:

[0046] Content splitting unit, used to divide the original cell content into different content blocks according to set rules;

[0047] The cell splitting unit is used to split the target cell based on the number and distribution of the content blocks to obtain at least two split cells.

[0048] In a possible implementation, the cell splitting module includes:

[0049] A split line display unit, used to display a split line in the target cell;

[0050] a split line moving unit, configured to move the split line in the target cell in response to a drag operation on the split line;

[0051] A cell splitting unit is used to split the target cell based on the position of the splitting line to obtain at least two split cells

[0052] In a possible implementation manner, the split line display unit is specifically used for:

[0053] Determine the target split mode;

[0054] A split line matching the target split pattern is displayed in the target cell.

[0055] In a possible implementation, the device further includes:

[0056] A preview module is used to display a preview effect of the split cells obtained by splitting the target cell based on the current position of the split line after the split line is moved in the target cell in response to the dragging operation on the split line.

[0057] In a possible implementation, the device further includes:

[0058] A content splitting module, configured to split the original cell content in the target cell based on the position of the splitting line to obtain at least two split contents after splitting the target cell based on the position of the splitting line to obtain at least two split contents;

[0059] The content filling module is used to fill each of the split contents into the corresponding split cells.

[0060] In a possible implementation manner, the content splitting module is specifically used to:

[0061] Classifying the original cell contents on both sides of the split line in the target cell into different content groups respectively;

[0062] And, in the case where it is determined that part of the original cell content in the target cell is located on the split line, the part of the original cell content is classified into one of the content groups, or the part of the original cell content is divided into different content blocks, and different content blocks are classified into different content groups;

[0063] Each of the content groups is determined as a split content to obtain at least two split contents.

[0064] In a possible implementation manner, the content filling module is specifically used to:

[0065] Each of the split contents is filled into the corresponding split cell according to the original cell style of the target cell.

[0066] In a possible implementation, the device further includes:

[0067] The cell adjustment module is used to adjust the size of the split cells according to the filling content in the split cells after each of the split contents is filled into the corresponding split cells.

[0068] In a possible implementation, the device further includes:

[0069] A table adjustment module, configured to, after splitting the target cell according to the target splitting strategy to obtain at least two split cells, add a new cell to the table according to the at least two split cells and determine the cells to be merged if it is determined that splitting the target cell affects adjacent cells of the target cell;

[0070] The cells to be merged are merged to obtain corresponding merged cells.

[0071] In a possible implementation, the device further includes:

[0072] A detection module, used for detecting whether the target cell meets a preset splitting condition before splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0073] The split line display module is specifically used to: when it is determined that the target cell meets the split condition, execute the step of splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0074] The device also includes:

[0075] The message prompt module is used to output a prompt message indicating that the target cell is prohibited from being split when it is determined that the target cell does not meet the split condition.

[0076] In a possible implementation, the device further includes:

[0077] A recovery module is used to restore the original cell layout of the target cell in response to a split undo operation on the target cell after the target cell is replaced by the at least two split cells.

[0078] In a third aspect, the present application provides an electronic device, comprising: a processor and a memory, wherein the processor is used to execute a table processing program stored in the memory to implement the table processing method described in any one of the first aspects.

[0079] In a fourth aspect, the present application provides a storage medium storing one or more programs, wherein the one or more programs can be executed by one or more processors to implement the table processing method described in any one of the first aspects.

[0080] The above-mentioned technical scheme provided by the embodiment of the present application has the following advantages compared with the prior art: by responding to the splitting instruction of the target cell in the table, determining the target splitting strategy indicated by the splitting instruction, splitting the target cell according to the target splitting strategy, obtaining at least two split cells, and replacing the target cell with the at least two split cells, a flexible and convenient cell splitting method is realized. The application of this method not only improves the flexibility and editability of the table, but also provides users with a more convenient and efficient table processing experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0081] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0082] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0083] One or more embodiments are exemplarily described by pictures in the corresponding drawings, and these exemplified descriptions do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings represent similar elements, and unless otherwise stated, the figures in the drawings do not constitute proportional limitations.

[0084] Figure 1 A flowchart of an embodiment of a table processing method provided in an embodiment of the present application;

[0085] Figure 2 A flowchart of another table processing method provided in an embodiment of the present application;

[0086] Figure 3 A schematic diagram of the effect of splitting a target cell according to a content splitting strategy provided in an embodiment of the present application;

[0087] Figure 4 A flowchart of another table processing method provided in an embodiment of the present application;

[0088] Figure 5 This is a schematic diagram showing the effect of displaying a split line in the target cell;

[0089] Figure 6 There are two ways to split the target cell according to the different positions of the split lines, and obtain the schematic diagram of the effect of the split cell;

[0090] Figure 7 This is a schematic diagram of the effect of splitting merged cells;

[0091] Figure 8 A schematic diagram of the effect of splitting the target cell and splitting the original cell content therein;

[0092] Fig. 9 A block diagram of an embodiment of a table processing device provided in an embodiment of the present application;

[0093] Fig.10 A schematic diagram of the structure of a device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0094] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0095] The disclosure below provides many different embodiments or examples to realize the different structures of the present application. In order to simplify the disclosure of the present application, the parts and settings of specific examples are described below. Of course, they are only examples, and the purpose is not to limit the present application. In addition, the present application can repeat reference numbers and / or letters in different examples. This repetition is for the purpose of simplification and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed.

[0096] In order to solve the technical problems in the prior art of achieving cell splitting effects that are cumbersome, inefficient, and have poor user experience, the present application provides a table processing method, device, electronic device, and storage medium, which realize a flexible and convenient cell splitting method. The application of this method can not only improve the flexibility and editability of the table, but also provide users with a more convenient and efficient table processing experience.

[0097] Figure 1 The following is a flow chart of an embodiment of a table processing method provided in the present application. Figure 1 As shown, the process includes the following steps:

[0098] Step 101: In response to a split instruction for a target cell in a table, determine a target split strategy indicated by the split instruction.

[0099] The above-mentioned table can be any table, which can be a table in a traditional format, such as a table in .xls, .xlsx and other formats, or a new generation of smart table, online table, and the embodiment of the present application does not limit this.

[0100] The target cell can be any cell in the table, which can be a merged cell, i.e., a cell formed by merging at least two consecutive minimum cells in the table, or a minimum cell, which is not limited in the present embodiment. It can be seen that the technical solution provided in the present embodiment can achieve a visual splitting effect on the minimum cell.

[0101] The number of target cells may be one or more. In the case of multiple target cells, these target cells may be located in the same row or column, or may be any multiple cells in the table. This embodiment of the application does not limit this.

[0102] As an optional implementation method, the user can select one or more target cells in the table by operating the mouse or by entering cell location information, and then trigger a split instruction for the selected cells, for example, by triggering the split icon in the table toolbar to trigger the split instruction for the selected cells.

[0103] In the technical solution provided by the embodiment of the present application, in response to a split instruction for a target cell in a table, a split strategy indicated by the split instruction is determined (for the convenience of description, the split strategy indicated by the split instruction is referred to as the target split strategy below). The split strategy is a method or rule for guiding or determining how to split the structure of a cell to achieve reorganization and display of the table content.

[0104] In one embodiment, the following splitting strategies are provided: a splitting strategy based on content and a splitting strategy using a splitting line. This means that the target splitting strategy can be a splitting strategy based on content or a splitting strategy using a splitting line.

[0105] The content splitting strategy refers to: dividing the original cell content in the cell according to certain rules, splitting the cell into multiple cells, and then assigning the content blocks obtained by the division to different cells after the division, so as to achieve the reorganization and display of the cell content. Exemplarily, the division rule can be based on the type, length, format or other custom rules of the content, etc., which are not limited here.

[0106] The splitting strategy using split lines means: displaying one or more draggable split lines in a cell, and users adjust the position of the split lines by dragging, and split the cell according to the position of the split lines. It can be seen that the splitting strategy using split lines pays more attention to user interactivity and intuitiveness.

[0107] Here, as an optional implementation, when the split instruction for the target cell is triggered, the user selects the target split strategy. For example, when the split instruction for the target cell is triggered, the optional split strategies, such as the above two split strategies, are displayed in the form of a pop-up window, and then in response to the user's selection operation on the split strategy in the pop-up window, the selected split strategy is determined as the target split strategy.

[0108] As another optional implementation, when the splitting instruction for the target cell is triggered, the target splitting strategy can be set by default. Exemplarily, the splitting strategy used by the user last time is determined as the target splitting strategy used this time. Alternatively, the splitting strategy used most frequently / most times by the user is determined as the target splitting strategy used this time. The embodiment of the present application does not limit how to set the target splitting strategy.

[0109] Step 102: Split the target cell according to the target splitting strategy to obtain at least two split cells.

[0110] It can be known from the relevant description in step 101 that the splitting strategy is a method or rule for guiding or determining how to split the structure of a cell to achieve reorganization and display of the table content. Therefore, the target cell can be split according to the target splitting strategy to obtain at least two split cells. As for how to split the target cell according to the target splitting strategy to obtain at least two split cells, the cell splitting process under the two splitting strategies is explained in detail below through different embodiments, which will not be described in detail here.

[0111] Step 103: Replace the target cell with at least two split cells.

[0112] In one embodiment, at least two split cells are used as a new cell structure to directly replace the original target cell, which means that the structure and content of the original target cell are no longer retained in the table, thereby enabling reorganization of the table content.

[0113] Exemplarily, the electronic spreadsheet processing software will automatically adjust the table layout to seamlessly integrate at least two split cells into the table as new cells. In addition, the split cells can inherit certain properties of the target cell (such as borders, background colors, etc.), and can also be adjusted accordingly according to the splitting strategy, which is not limited in the embodiments of the present application.

[0114] The technical solution provided in the embodiment of the present application responds to a split instruction for a target cell in a table, determines the target splitting strategy indicated by the split instruction, splits the target cell according to the target splitting strategy, obtains at least two split cells, and replaces the target cell with the at least two split cells, thereby realizing a flexible and convenient cell splitting method. The application of this method not only improves the flexibility and editability of the table, but also provides users with a more convenient and efficient table processing experience.

[0115] Figure 2 A flowchart of another table processing method provided in an embodiment of the present application. Figure 2The process shown in Figure 1 Based on the process shown in the figure, this paper focuses on describing the specific implementation process of splitting the target cell when the target splitting strategy is the content splitting strategy. Figure 2 As shown, the process includes the following steps:

[0116] Step 201: In response to a split instruction for a target cell in a table, determine a target split strategy indicated by the split instruction.

[0117] For detailed description of step 201, please refer to Figure 1 The relevant description in the illustrated embodiment will not be repeated here.

[0118] Step 202: When the target splitting strategy is a content-based splitting strategy, the original cell content is divided into different content blocks according to a set rule.

[0119] Step 203: Split the target cell based on the number and distribution of the content blocks to obtain at least two split cells.

[0120] The content splitting strategy means: dividing the original cell content in the cell according to certain rules, and then allocating the divided content blocks to different cells respectively, so as to achieve reorganization and display of the cell content.

[0121] Accordingly, when the target splitting strategy is a content splitting strategy, the original cell content is first divided into different content blocks according to the set rules, and then the target cell is split based on the number and distribution of the content blocks to obtain at least two split cells.

[0122] Exemplarily, the setting rule may be splitting according to a preset delimiter, splitting according to a character type, splitting according to a content type, splitting according to a line, splitting according to a content semantic analysis, splitting according to a condition, and the like.

[0123] The preset delimiter can be a preset character, which can be used as the basis for splitting the string, and can be set to characters such as commas, periods, dashes, semicolons, and line breaks. For example, if the original cell content in the target cell is "abd, def" and the preset delimiter is "," the divided content blocks include: "abc" and "def".

[0124] It should be noted that the above is only a simple example of dividing the original cell content with separators. In actual applications, more complex division methods can be set, such as setting different division levels, and using different separators for division at each division level. For example, the original cell content in the target cell is "1,2; 3,4; 5,6;", and the setting rule is: perform a first-level division on the original cell content according to the semicolon, and then perform a second-level division on the first-level division result according to the comma. At this time, the divided content blocks include: "1", "2", "3", "4", "5", "6", among which "1" and "2" are the second-level division results under the same first-level division result, "3" and "4" are the second-level division results under the same first-level division result, and "5" and "6" are the second-level division results under the same first-level division result.

[0125] For another example, the original cell content in the target cell is first divided by a row separator, and then other separators, such as spaces, commas, semicolons, etc., are used to divide the cell content in a row to obtain multiple content blocks. Figure 3 In the example, the original cell content in the target cell is first divided into 6 rows using a row separator, and then in each row, the cell content is divided into 3 content blocks using spaces. The 3 content blocks correspond to name, gender, and contact number, respectively.

[0126] Segmentation by character type is to segment characters of different character types into different content blocks, and the character type may include at least one of the following: number type, letter type, punctuation type, Chinese type, etc. For example, the original cell content in the target cell is "abc123", and after segmentation by character type, the segmented content blocks include: "abc" and "123".

[0127] Division by content semantics means that after semantic analysis of the cell content, the cell content is determined to be divided into multiple content blocks. For example, the original cell content in the target cell is "first, ...; second, ...; third, ...;", and after division by content semantic analysis, the obtained content blocks include: "first, ...;" "second, ...;" "third, ...;".

[0128] Conditional splitting refers to dividing the cell content into multiple content blocks according to set conditions. Exemplarily, the set condition indicates that the cell content is divided into multiple content blocks according to a certain number of characters. For example, the original cell content in the target cell is "123456", and the set condition indicates that every 2 characters are divided into a content block, then the divided content blocks include: "12", "34", and "56".

[0129] In addition, in the above embodiment, the user can flexibly select the division rules (ie, the setting rules described above), or the user can flexibly set the division rules according to actual needs. The embodiment of the present application does not limit the specific division rules.

[0130] Splitting the target cell based on the number and distribution of content blocks to obtain at least two split cells means that: the number of split cells is consistent with the number of content blocks obtained by division, so that the divided content blocks can be respectively allocated to different split cells, and the distribution of the split cells is consistent with the distribution of the divided content blocks in the original cell content.

[0131] The distribution of content blocks in the original cell content can be one row, one column, or multiple rows and columns. In the specific implementation, it can be determined according to the position and arrangement order of the content blocks in the original cell content. For example, if the original cell content in the target cell is "123456", and the content blocks after division include: "12", "34", and "56", these content blocks are distributed in one row in the original cell content. Correspondingly, the distribution of at least two cells after division will also be one row, specifically one row and n columns, where n is the number of content blocks after division. Figure 3 Taking the target cell shown as an example, these content blocks are distributed in multiple rows and columns in the original cell content, specifically 6 rows and 2 columns, so the distribution of at least two split cells will also be 6 rows and 2 columns.

[0132] In a specific implementation, the distribution of the content blocks is affected by the above-mentioned setting rules and is determined by the division level indicated by the setting rules. For example, the number of distribution columns (or distribution rows) of the content blocks obtained by the final division is determined according to the number of content blocks obtained by the first-level division, and the number of distribution rows (or distribution columns) of the content blocks obtained by the final division is determined according to the number of content blocks obtained by the second-level division of the content blocks obtained by the first-level division.

[0133] Take the above example: the original cell content in the target cell is "1,2; 3,4; 5,6;", and the setting rule is: perform a primary division on the original cell content according to the semicolon, and then perform a secondary division on the primary division result according to the comma. At this time, the divided content blocks include: "1", "2", "3", "4", "5", "6", among which "1" and "2" are the secondary division results under the same primary division result, "3" and "4" are the secondary division results under the same primary division result, and "5" and "6" are the secondary division results under the same primary division result. After the primary division, the original cell content in the target cell is divided into 3 content blocks, and the number of content blocks obtained by the secondary division of the content blocks obtained by the primary division is 2 (the maximum number of content blocks obtained by the secondary division of each content block obtained by the primary division). Based on this, the number of distribution columns of the content blocks obtained by the final division is determined to be 3 columns, and the number of distribution rows is 2 rows, that is, the distribution of the content blocks obtained by the final division is determined to be 2 rows and 3 columns. At this time, the target cell is split into 2 rows and 3 columns of split cells.

[0134] In one embodiment, the distribution of content blocks in the original cell content can also be determined by the number of rows and columns specified by the user. For example, "1,2; 3,4; 5,6;" can be specified as a row or a column, and the separators can be specified as "," and ";". The divided content blocks include: "1", "2", "3", "4", "5", and "6".

[0135] Step 204: Replace the target cell with at least two split cells.

[0136] Continue to see Figure 3 For example, splitting the target cell may change the number of rows and columns occupied by the table, for example Figure 3 The original target cell is split into 6 rows and 2 columns, a total of 12 cells, which will affect other cells in the table, especially the adjacent cells of the target cell. The affected adjacent cells are usually cells in the same row or column as the target cell, and the affected aspects are usually the readability and aesthetics of the layout of these cells.

[0137] In this regard, in one embodiment, when it is determined that splitting a target cell affects adjacent cells of the target cell, a new cell is added to the table based on at least two split cells, and cells to be merged are determined; the cells to be merged are merged to obtain corresponding merged cells. The newly added cells are usually located in the same row / column as the split cells, and the cells to be merged usually include the newly added cells and the affected adjacent cells.

[0138] See also Figure 3, the newly added cells in the table after the split cells include A2:A6, and C1:C7 ( Figure 3 The cells to be merged include the newly added cells A2:A6 and cell A1, and the newly added cells C1:C7 and cell B7. Merge these two groups of cells to be merged separately to get Figure 3 The final effect diagram ( Figure 3 rightmost image in ).

[0139] Here is another point to add: splitting the target cell does not necessarily affect the target cell's adjacent cells. For example, if the target cell is a merged cell, and the number of rows and columns of the original sub-cells of the merged cell is greater than or equal to the number of rows and columns of the split cell, that is, if the split of the target cell does not change the number of rows / columns occupied by the table, it usually does not affect the target cell's adjacent cells. If the number of rows and columns of the split cell is greater than the number of rows and columns of the original sub-cells of the merged cell, it usually affects the target cell's adjacent cells.

[0140] For example, suppose the target cell is Figure 3 In the rightmost figure, the merged cell where "Information a" is located originally includes two sub-cells, that is, the target cell is formed by merging two minimum cells. Assume that for the target cell, the original cell content is divided into two content blocks, namely "Information" and "a". Based on the number and distribution of the two content blocks, the target cell is split into cells with one row and two columns. At this time, the splitting of the target cell does not affect the adjacent cells of the target cell.

[0141] Specifically, this embodiment describes in detail how to determine the impact of performing a split operation on a target cell on adjacent cells through the following description.

[0142] In the case where the target cell is a normal cell, if a split operation is performed, it is determined that splitting the target cell affects adjacent cells of the target cell, wherein the normal cell is the smallest cell in the table.

[0143] In the case where the target cell is a merged cell, it is further determined whether splitting the target cell affects adjacent cells of the target cell according to the distribution of the content blocks obtained by the division.

[0144] Wherein, when the number of distribution rows and columns of the content block obtained by division is less than or equal to the original number of distribution rows and columns of the sub-cells in the target cell, it is determined that splitting the target cell does not affect the adjacent cells of the target cell.

[0145] When the number of distributed rows (and / or columns) of the divided content block is greater than the original number of distributed rows (and / or columns) of the child cells in the target cell, it is determined that splitting the target cell affects the adjacent cells of the target cell.

[0146] In addition, when the number of distribution rows and columns of the divided content block is consistent with the original number of distribution rows and columns of the sub-cells in the target cell, the layout structure of the target cell can be restored to the layout structure before the merge to split the target cell into at least two split cells.

[0147] Figure 2 The process shown divides the original cell content in the target cell into different content blocks according to the set rules, splits the target cell based on the number and distribution of the content blocks, obtains at least two split cells, and replaces the target cell with at least two split cells, thereby realizing a method of automatically splitting cells according to content. This method improves the convenience and flexibility of table processing and can provide users with a more convenient and efficient table processing experience.

[0148] In one embodiment, the splitting of the target cell may be reflected in restoring the original splitting line of the target cell, or adding a splitting line to the smallest cell in the target cell.

[0149] Figure 4 A flowchart of another table processing method provided in an embodiment of the present application. Figure 4 The process shown in Figure 1 Based on the process shown in the figure, the specific implementation process of splitting the target cell is described in detail when the target splitting strategy is splitting by splitting line. Figure 4 As shown, the process includes the following steps:

[0150] Step 401: In response to a split instruction for a target cell in a table, determine a target split strategy indicated by the split instruction.

[0151] For detailed description of step 401, please refer to Figure 1 The relevant description in the illustrated embodiment will not be repeated here.

[0152] Step 402: When the target splitting strategy is a splitting line splitting strategy, a splitting line is displayed in the target cell.

[0153] Generally, the split line is a straight line segment. The direction of the split line can be horizontal, vertical, diagonal (i.e., the split line is located on the diagonal of the target cell or parallel to the diagonal of the target cell) or at any custom angle relative to the table. If the split line extends in the horizontal direction, it means that the target cell is split vertically, which can achieve the visual effect of splitting the target cell into at least two rows. For example, see Figure 5 (a) is a schematic diagram showing the effect of displaying a split line in a target cell when the target cell is split vertically. The split line extending in the vertical direction means that the target cell is split horizontally, which can achieve the visual effect of splitting the target cell into at least two columns. For example, see Figure 5 (b) is a schematic diagram showing the effect of displaying a split line in a target cell when the target cell is split horizontally. The split line is located on the diagonal line of the target cell, which means that the target cell is split diagonally. For example, see Figure 5 (c) is a schematic diagram showing the effect of displaying the split line in the target cell when the target cell is split diagonally. In practical applications, more complex splitting of the target cell can also be performed, for example, see Figure 5 (d) is a schematic diagram showing the effect of displaying a split line in a target cell when the target cell is split horizontally and vertically at the same time.

[0154] Accordingly, in one embodiment, the specific implementation of displaying a split line in a target cell includes: in response to a split instruction for a target cell in a table, determining a target split mode corresponding to the split instruction; and displaying a split line matching the target split mode in the target cell.

[0155] The target split mode is used to indicate the split direction of the target cell, including but not limited to: horizontal split mode, vertical split mode, diagonal split mode, custom angle split mode, etc. When the target split mode is the vertical split mode, the split line corresponding to the target split mode is displayed in the target cell. Figure 5 (a) The display effect shown. When the target split mode is the horizontal split mode, the split line corresponding to the target split mode is displayed in the target cell. Figure 5 (b) The display effect shown. When the target splitting mode is the diagonal splitting mode, the splitting line corresponding to the target splitting mode is displayed in the target cell. Figure 5 (c) The display effect shown. The target split mode is a custom angle split mode, which is similar to the diagonal split mode. The difference from the diagonal split mode is that the split line has a different inclination angle compared to the target cell. When the target split mode includes a horizontal split mode and a vertical split mode, the split line matching the target split mode is displayed in the target cell. Figure 5(d) The display effect shown.

[0156] Here, as an optional implementation, when the split operation on the target cell is triggered, the user selects the target split mode. For example, when the split operation on the target cell is triggered, the optional split modes are displayed in the form of a pop-up window, and then in response to the user's selection operation on the split mode in the pop-up window, the selected split mode is determined as the target split mode.

[0157] As another optional implementation, when the split operation on the target cell is triggered, a split line is displayed in the target cell according to a default split direction (such as a horizontal direction). Afterwards, the user can set the final target split mode by rotating the split line.

[0158] It can be seen from the above embodiments that in the technical solution provided in the present application, users can flexibly set the splitting mode of the target cells according to actual needs, which increases the flexibility and diversity of cell splitting, can meet the diverse needs of users, and thus improve the user experience.

[0159] Furthermore, when there are multiple target cells, a split line may be displayed in each target cell. Alternatively, when multiple target cells are located in the same row or column, one split line may be displayed in the multiple target cells.

[0160] Here, as an optional implementation method, it can be determined whether to display one split line in multiple target cells or to display a split line in each target cell according to the positional relationship of the multiple target cells. For example, when multiple target cells are located in the same row or column, one split line is displayed in the multiple target cells by default, and when multiple target cells are not located in the same row or column, a split line is displayed in each target cell by default.

[0161] As an optional implementation, when multiple target cells are located in the same row, a split line extending horizontally is displayed in the multiple target cells by default; when multiple target cells are located in the same column, a split line extending vertically is displayed in the multiple target cells by default.

[0162] As another optional implementation, the user decides whether to display a split line in multiple target cells or to display a split line in each target cell. For example, the user can choose to perform a unified split or an independent split. If multiple target cells are located in the same row or column and the user chooses to perform a unified split, a split line can be displayed in the multiple target cells, and if the user chooses to perform an independent split, a split line can be displayed in each target cell.

[0163] In addition, in one embodiment, multiple split lines can be displayed in the target cell at the same time. Wherein, as an optional implementation method, when the split operation on the target cell is triggered, the number of split lines is selected by the user. For example, the user sets the number of split lines to 2, then two split lines will be displayed in the target cell at one time. As another optional implementation method, each time in response to a split operation on the target cell in the table, a split line is displayed in the target cell. As another optional implementation method, when a split line is already displayed in the target cell, in response to a copy and paste operation on the split line, a split line is added in the target cell. Of course, the display positions of multiple split lines in the target cell are not the same, so that the user can intuitively understand the number of split lines.

[0164] Here is one more point to add, as an optional implementation, in the above implementation of displaying a split line in the target cell in response to each split operation on the target cell in the table, except for the first time when the user manually sets the target split mode, when the subsequent user triggers a split operation on the same target cell, the target split mode set for the first time can be automatically used, and a split line matching the target split mode can be displayed in the target cell. Of course, the user can also manually set the target split mode each time, that is, set the direction of the split line relative to the target cell. For example Figure 5 In the example of (d), the user triggers the split operation for the first time and selects the horizontal split mode, and triggers the split operation for the second time and selects the vertical split mode.

[0165] Step 403: In response to the dragging operation on the split line, move the split line in the target cell.

[0166] Step 404: Split the target cell based on the position of the split line to obtain at least two split cells.

[0167] Step 405: Replace the target cell with at least two split cells.

[0168] For ease of understanding, steps 403 to 405 are described in a unified manner as follows:

[0169] The dragging operation of the split line is, for example, that the user presses and moves the split line with a mouse or a finger (in the case of a touch screen) to change its position. During the process of the user dragging the split line, the position of the split line will be updated in real time, so as to provide visual feedback to the user in real time to ensure that the user can clearly see the result of his operation. In addition, in actual applications, after the user ends the operation, such as after the user releases the mouse or finger, the position of the split line can also be automatically corrected so that the split line can finally remain in the target cell.

[0170] It can be seen from the description of step 403 and step 404 that the user can flexibly move the split line in the target cell according to actual needs, and moving the split line means changing the "splitting position" of the target cell, thereby affecting the size of the split cell (such as row height, column width). In addition, in the case where the target cell has cell content, moving the split line will also affect the splitting of the cell content in the target cell. This will be explained in subsequent embodiments and will not be described in detail here.

[0171] In addition, when there are multiple target cells and split lines are displayed in each of the multiple target cells, the user can select the split line in one of the target cells at a time to perform the drag operation. At this time, the cell will only be split in the target cell selected by the user. Of course, in actual applications, the user can also select the split lines in multiple target cells at a time to perform the drag operation. For example, the user presses the mouse to hold the split line in one of the target cells to perform the drag operation, but the split lines in the other target cells can be displaced by the same amount in their respective target cells as the user drags, thereby realizing batch cell splitting.

[0172] by Figure 5 (a) as an example, see Figure 6 , showing two schematic diagrams of splitting the target cell according to the different positions of the splitting lines to obtain the effect of the split cells. Figure 6 As shown in the figure, the same number of split lines but different positions of the split lines will affect the size of the cells after splitting.

[0173] Continue to see Figure 6 For example, splitting the target cell may change the number of rows and columns occupied by the table, for example, a table that originally occupies 4 rows becomes occupies 5 rows, which may affect other cells in the table, especially the adjacent cells of the target cell. The affected adjacent cells are usually cells in the same row or column as the target cell, and the affected aspects are usually the readability and aesthetics of the layout of these cells.

[0174] In this regard, in one embodiment, when it is determined that splitting a target cell affects adjacent cells of the target cell, a new cell is added to the table based on at least two split cells, and cells to be merged are determined; the cells to be merged are merged to obtain corresponding merged cells. The newly added cells are usually located in the same row / column as the split cells, and the cells to be merged usually include the newly added cells and the affected adjacent cells.

[0175] by Figure 6 Take effect 1 in as an example, split the target cell into two cells, namely the smallest cell with "target cell 1" as the display content and the smallest cell with "target cell 2 target cell 3" as the display content. Add new cells to the table based on the two split cells, specifically add a cell below cell 5 and a cell below cell 6, then determine cell 5 and the newly added cells below it as a group of cells to be merged, determine cell 6 and the newly added cells below it as a group of cells to be merged, merge the two groups of cells to be merged, and you can get Figure 3 In the example of effect 1, after the operations of adding cells and merging cells are performed, cell 5 changes from occupying one row to occupying two rows; cell 6 also changes from occupying one row to occupying two rows.

[0176] Here is another point to add. Splitting the target cell does not necessarily affect the adjacent cells of the target cell. For example, when the target cell is a merged cell, and the number of original sub-cells of the merged cell is greater than or equal to the number of cells after splitting, that is, when the splitting of the target cell does not change the number of rows / columns occupied by the table, it usually does not affect the adjacent cells of the target cell. If the number of cells after splitting is greater than the number of original sub-cells of the merged cell, it usually affects the adjacent cells of the target cell. In addition, when the splitting direction is different from the merging direction of the target cell, it usually affects the adjacent cells of the target cell.

[0177] See also Figure 7 (a) and Figure 7 Example (c), Figure 7The target cell in (a) originally includes two sub-cells, that is, the target cell is formed by merging two minimum cells, but two horizontal split lines are set for the target cell, and the two horizontal split lines can split the target cell into three rows of cells. In this case, the adjacent cells of the target cell will be affected, including cell 5 and cell 6. At this time, according to the above description, a new cell is added below cell 5, and a new cell is added below cell 6, and then cell 5 and the newly added cells below it are determined as a group of cells to be merged, and cell 6 and the newly added cells below it are determined as a group of cells to be merged, and the two groups of cells to be merged are merged to obtain Figure 7 (c) Example.

[0178] See also Figure 8 In the example of , the target cell originally includes two sub-cells, that is, the target cell is formed by merging two minimum cells. A horizontal split line is set for the target cell, and the horizontal split line can split the target cell into two rows of cells. If the newly added split line belongs to the split line of the original target cell, it will not affect the adjacent cells of the target cell. The target cell can be split based on the split line to obtain Figure 8 (b) Example.

[0179] Specifically, this embodiment describes in detail how to determine whether to perform a split operation on a target cell to add a split line in the target cell and the impact on adjacent cells through the following description.

[0180] In the case where the target cell is a normal cell, if a split operation is performed to add a split line in the target cell, the adjacent cells of the target cell affected by splitting the target cell are determined, wherein the normal cell is the smallest cell in the table.

[0181] When the target cell is a merged cell, if a split operation is performed to add a split line in the target cell, a classification discussion is required:

[0182] Definition: A merged cell is a cell formed by merging at least two consecutive minimum cells (ordinary cells). There is an original split line in the merged cell, which is used to restore the merged cell to the original number of minimum cells (the number of minimum cells that merged to form the merged cell). The common edge of any two adjacent minimum cells in the merged cell can be determined as the original split line.

[0183] The following determines the impact of different split situations on adjacent cells based on the added split lines and number:

[0184] The first case: when the number of split lines added in the target cell is less than or equal to the number of original split lines in the target cell, it is determined that splitting the target cell does not affect adjacent cells of the target cell.

[0185] In one embodiment, the number of split lines added in the target cell is determined, and when the number of split lines is equal to the original split lines, an equal number of original split lines are restored during splitting to split the target cell into at least two split cells. The original cell content in the target cell is split based on the position of the split lines to obtain at least two split contents; each split content is filled into the corresponding split cell.

[0186] In one embodiment, when the number of split lines is less than the original split lines, the positions of the split lines are determined; and the original split lines closest to the positions of the split lines are used as the original split lines to be restored.

[0187] In one embodiment, when the number of split lines is less than the original split lines, the content after splitting is determined; based on the principle that the more space the content after splitting occupies, the more minimum cells the split cells to which the content after splitting is to be allocated occupy, the original split lines to be restored are determined. For example, the merged cell B is formed by merging the minimum cell B1, the minimum cell B2, and the minimum cell B3, wherein the merged cell B has two original split lines b1 and b2, the original split line b1 is the common edge of the minimum cell B1 and the minimum cell B2, and the original split line b2 is the common edge of the minimum cell B2 and the minimum cell B3. Assuming that the content of the merged cell B is C, it is necessary to add a split line in the merged cell to split the content C of the merged cell B into the split content C1 and the split content C2. When the split content C1 occupies more space than the split cell C2, the original split line b2 is restored to obtain the split cell D1 formed by merging the minimum cell B1 and the minimum cell B2, and the split cell D2 represented by the minimum cell B3. Furthermore, the split content C1 may be assigned to the split cell D1, and the split content C2 may be assigned to the split cell D2.

[0188] In one embodiment, when the number of split lines is less than the original split lines, the original split lines selected by the user and having the same number as the split lines are determined as the original split lines to be restored.

[0189] In the above situation, since the number of splitting lines added in the target cell is less than or equal to the number of original splitting lines in the target cell, the original splitting lines with the same number as the splitting lines can be restored, so that the layout of the cells adjacent to the target cell does not need to be changed, that is, there is no need to add or delete rows and columns, so it can be determined that splitting the target cell does not affect the adjacent cells of the target cell.

[0190] The second case: when the number of split lines added in the target cell is greater than the number of original split lines in the target cell, it is determined that splitting the target cell affects adjacent cells of the target cell.

[0191] In one embodiment, the difference between the number of split lines added in the target cell and the number of original split lines is determined, and when splitting, all original split lines are restored, and the number of split lines of the difference is added to split the target cell into at least two split cells. The original cell content in the target cell is split based on the position of the split line to obtain at least two split contents; each split content is filled into the corresponding split cell.

[0192] In one embodiment, a splitting line of the difference amount is added to any sub-cell of the target cell to further split any sub-cell into at least two split cells. Wherein, when a splitting line is added to a sub-cell, it is determined that the splitting of the sub-cell affects the adjacent cells of the sub-cell.

[0193] In one embodiment, adjacent cells of sub-cells of a target cell in a splitting direction are determined as candidate adjacent cells; a target adjacent cell is determined from the candidate adjacent cells based on the principle that the more space the content of a candidate adjacent cell occupies, the more minimum cells the candidate adjacent cell occupies; sub-cells adjacent to the target adjacent cell are determined as target sub-cells; splitting lines of the difference quantity are added to the target sub-cell to further split the target sub-cell into at least two split cells, and the space occupied by the target adjacent cell is increased.

[0194] In one embodiment, a split line for the difference amount is added to a sub-cell of the target cell selected by the user.

[0195] In the above situation, since the number of split lines added in the target cell is greater than the number of original split lines in the target cell, the extra split lines can be set in the sub-cells of the target cell that belong to the ordinary cells. This will require the layout of the adjacent cells of the sub-cells to be changed, that is, rows and columns need to be added or deleted, so that it can be determined that splitting the target cell affects the adjacent cells of the target cell, and the affected cells are the adjacent cells of the sub-cells to which the split lines are added.

[0196] The technical solution provided by the embodiment of the present application realizes an intuitive way of splitting cells by displaying a split line in the target cell in response to a split operation on the target cell in the table, moving the split line in the target cell in response to a drag operation on the split line, and splitting the target cell based on the position of the split line to obtain at least two split cells. In this way, splitting the cell by dragging the split line is not only simple to operate, but also allows the user to intuitively understand the position of the split line and can freely adjust the position of the split line as needed to adapt to different cell layout requirements, thereby improving the intuitiveness and flexibility of the cell splitting operation, making user interaction more convenient and providing a better experience.

[0197] exist Figure 1 In the process shown, the technical solution provided by the embodiment of the present application is explained as a whole by taking the splitting of the smallest cell as an example. In practical applications, the technical solution provided by the embodiment of the present application can also be applied to split the merged cells. This splitting method is significantly different from the splitting method of the merged cells in the prior art: the splitting of the merged cells in the prior art is essentially just a simple cancellation of the merge and the restoration of the cells to the original layout, while the technical solution provided by the embodiment of the present application supports the use of split lines to split the merged cells at any position and any number (referring to the number of cells after splitting) without being restricted by the original layout of the cells, thereby being able to meet the various complex splitting needs of users.

[0198] For example, see Figure 7 (a), the target cell (displayed as "target cell 1 target cell 2 target cell 3 target cell 4") is a merged cell formed by merging two minimum cells. In the prior art, splitting the target cell is essentially canceling the merge. The splitting effect is as follows: Figure 7 (b). Figure 7 (c) By applying the technical solution provided in the embodiments of the present application, merged cells can be split at any position and in any number. Figure 7 In the example of (b), the target cell is split into three minimum cells, namely, the minimum cell with "target cell 1 target cell 2" as the display content, the minimum cell with "target cell 3" as the display content, and the minimum cell with "target cell 4" as the display content.

[0199] pass Figure 4It can be seen from the relevant description in the illustrated embodiment that when splitting the target cell in the table, it involves moving the split line once or multiple times, especially when the split line is moved multiple times, which means that the user needs to adjust the position of the split line multiple times to obtain the desired splitting effect. In this regard, in one embodiment, in response to the dragging operation of the split line, after the split line is moved in the target cell, a preview effect of the split cell obtained by splitting the target cell based on the current position of the split line is displayed.

[0200] Optionally, the preview effect can be displayed in a pop-up window. The display interface in the pop-up window will be refreshed as the user moves the split line in the target cell, so that the user's operation is synchronized with the preview effect, thereby ensuring the real-time and accuracy of the preview.

[0201] The above embodiment displays a real-time preview of the cell splitting effect based on the current splitting line position when the user drags the splitting line. This instant feedback allows the user to intuitively see the splitting result, thereby quickly determining whether the position of the splitting line needs to be further adjusted, which can significantly improve operational efficiency and enhance user experience.

[0202] In an exemplary application scenario, the target cell to be split originally has cell content (for the convenience of description, referred to as the original cell content below). Therefore, when the target cell is split, it will also involve the processing of the original cell content in the target cell and the filling of the content of the split cell.

[0203] In this regard, in the technical solution of the embodiment of the present application, after the target cell is split based on the position of the splitting line to obtain at least two split cells, the original cell content in the target cell is split based on the position of the splitting line to obtain at least two split contents; each split content is filled into the corresponding split cell respectively.

[0204] In one embodiment, the specific implementation of splitting the original cell content in the target cell based on the position of the split line to obtain at least two split contents includes: classifying the original cell contents on both sides of the split line in the target cell into different content groups; and in the case where it is determined that part of the original cell content in the target cell is located on the split line, classifying the part of the original cell content into one of the content groups; and determining each content group as a split content to obtain at least two split contents.

[0205] For example, see Figure 5(a) is an example, which includes a split line for indicating that the target cell is split vertically, and the split line splits the target cell into two cells, upper and lower (for the convenience of description, they are respectively referred to as the first split cell and the second split cell in order from top to bottom), and the original cell content in the target cell is also split into two parts by the split line, namely "target cell 1" and "target cell 2 target cell 3". According to the above description, since the two parts are located on both sides of the split line, the two parts are respectively classified into different content groups, and each content group is respectively determined as a split content, so that two groups of split content are obtained: "target cell 1" and "target cell 2 target cell 3". Further, the split content "target cell 1" completely falls into the first split cell, so the split content "target cell 1" is filled into the first split cell. Similarly, the split content "target cell 2 target cell 3" completely falls into the first split cell, so the split content "target cell 2 target cell 3" is filled into the first split cell.

[0206] For example, see Figure 5 (b) is an example, which includes a split line for indicating that the target cell is to be split horizontally, and the split line splits the target cell into two cells on the left and right (for the convenience of description, they are respectively referred to as the third split cell and the fourth split cell in order from left to right), and the original cell contents in the target cell are all located on one side of the split line. Therefore, the original cell contents in the target cell are classified into a content group, and the content group is determined as a split content, so that a group of split contents is obtained: "target cell 1 target cell 2 target cell 3". Further, the split content "target cell 1 target cell 2 target cell 3" completely falls into the third split cell, so the split content "target cell 1 target cell 2 target cell 3" is filled into the third split cell, and the content in the fourth split cell is empty.

[0207] Of course, in actual applications, after the target cell and the original cell content therein are split, the user can also manually fill the empty split cell with cell content, or perform secondary editing on the content automatically filled in the split cell. The embodiments of the present application do not limit this.

[0208] For another example, see Figure 5 (c) includes a split line indicating that the target cell is split diagonally, and the split line splits the target cell into two cells (for the convenience of description, they are respectively referred to as the fifth split cell and the sixth split cell from left to right). Figure 5As shown in

[0209] (c), the cell contents "Mu" (in the first line of text), "Target Cell 3", and "Target Unit" (in the second line of text) completely fall into the fifth split cell. Therefore, the cell contents "Mu", "Target Cell 3", and "Target Unit" are grouped into one content group (for convenience of description, denoted as Content Group 1), and this Content Group 1 is filled into the fifth split cell. Similarly, the cell content "Yuan Ge 1" completely falls into the sixth split cell. Therefore, the cell content "Yuan Ge 1" is grouped into one content group (for convenience of description, denoted as Content Group 2), and this Content Group 2 is filled into the sixth split cell. Figure 5 (c), the cell contents "Biao Dan" (in the first line of text) and "Ge 2" are on the split line. At this time, there is a problem of whether to classify this part of the cell content into Content Group 1 or Content Group 2.

[0210] In response to this, as an optional implementation method, the cell content on the split line can be classified into one of the content groups according to the falling area. Specifically, determine the areas where the cell content on the split line falls into two different split cells respectively, and classify the cell content on the split line into the content group with the largest falling area. Here, the circumscribed rectangle of the text can be used to calculate the above area. For example, referring to Figure 8 (a) for an example, the cell content "Target Cell 2" falls on the split line. Assuming that through the calculation of the falling area, it is determined that the area where the cell content "Target Cell 2" falls into the first split cell is smaller than the area where it falls into the second split cell, then the cell content "Target Cell 2" is classified into the content group below the split line, and this content group is filled into the second split cell. Referring to Figure 8 (b), which is Figure 8 the schematic diagram of the split effect corresponding to

[0211] (a).

[0212] As another optional implementation method, part of the original cell content is divided into different content blocks, and different content blocks are classified into different content groups.

[0213] The preset delimiter can be a preset character, which can be used as the basis for splitting the string, and can be set to characters such as commas, periods, dashes, semicolons, and line breaks. For example, if the content of some cells on the split line is "abd, def", and the preset delimiter is "," the divided content blocks include: "abc" and "def".

[0214] In addition, the content group to which the divided content block is to be assigned can be determined according to the preset separator. For example, the original cell content is "ghabd, defop", and it can be seen that the original cell content can be separated into two parts by the preset separator: "ghabd", "defop", wherein the content block "abd" belongs to the former part, therefore, the content block "abd" is assigned to the content group where "gh" is located, and the content block "def" belongs to the latter part, therefore, the content block "def" is assigned to the content group where "op" is located.

[0215] The division by character type is to divide characters of different character types into different content blocks, and the character type may include at least one of the following: number type, letter type, punctuation type, Chinese type, etc. For example, the content of some cells located on the split line is "abc123". After the division by character type, the divided content blocks include: "abc" and "123".

[0216] In addition, the content group to which the divided content blocks are to be placed can be determined based on the character type. For example, the divided content blocks are placed in content groups with the same character type. For example, assuming that the original cell content is "defabc123456", and assuming that "def" and "456" fall on both sides of the split line, "def" and "456" are placed in different content groups. Since the character type of the content block "abc" is the same as the character type of "def", the content block "def" is placed in the content group where "def" is located, and the character type of the content block "123" is the same as the character type of "456", so the content block "123" is placed in the content group where "456" is located.

[0217] Partitioning by content semantics refers to performing semantic analysis on the cell content on the split line and then determining to divide the cell content into multiple content blocks. For example, if the cell content on the split line is "first, ...; second, ...; third, ...;", after partitioning by content semantic analysis, the resulting content blocks include: "first, ...;" "second, ...;" "third, ...;".

[0218] In addition, the content semantics can be used to determine which content group the divided content blocks belong to. Specifically, the degree of association between the cell content located on the split line and each content group can be determined respectively, and the cell content located on the split line can be classified into the content group with the highest degree of association. For example, assuming that through the calculation of semantic association, it is determined that the degree of association between the cell content "biaodan" and content group 2 is greater than its degree of association with content group 1, then the cell content "biaodan" is classified into content group 2, and the cell content "biaodan" is filled into the sixth split cell. Assuming that through the calculation of semantic association, it is determined that the degree of association between the cell content "grid 2" and content group 1 is greater than its degree of association with content group 2, then the cell content "biaodan" is classified into content group 1, and the cell content "grid 2" is filled into the fifth split cell.

[0219] At this point, "target cell 2 target cell 3" is classified into content group 1, and content group 1 is filled into the fifth split cell, and "target cell 1" is classified into content group 2, and content group 2 is filled into the sixth split cell. Among them, the fifth split cell and the sixth split cell are split by the split line extending along the diagonal line of the target cell, which does not affect the underlying data structure of the target cell, and can be understood as visually generating a diagonal split display effect.

[0220] In addition, in the above embodiments, the user can flexibly select the division rule (ie, the setting rule described above), or the user can flexibly set the division rule according to actual needs.

[0221] The above-mentioned embodiment splits the original cell content in the target cell based on the position of the split line, and fills the split content into the corresponding split cell, providing a method that can directly split the cell content and automatically allocate the cell content according to the position of the split line. In this method, the user can intuitively understand the splitting effect of the original cell content in the target cell, so that the position of the split line can be freely adjusted according to the content splitting requirements to adapt to different cell content requirements. It has good intuitiveness and flexibility, and user interaction is more convenient and the experience is better.

[0222] The above embodiment is only an exemplary description of splitting the target cell and filling the split cells with content. In practical applications, there may be other ways. For example, after splitting the target cell into at least two cells, the original cell content in the target cell may be copied and filled into each of the split cells. The present application embodiment does not limit this.

[0223] Based on any of the above embodiments, the present application also provides the following embodiments:

[0224] In one embodiment, the specific implementation of filling each split content into the corresponding split cell includes: filling each split content into the corresponding split cell according to the original cell style of the target cell. The cell style refers to the font, font size, font color, background color, text alignment, etc. of the content in the cell.

[0225] By filling each split content into the corresponding split cell according to the original cell style of the target cell, the consistency of the cell style before and after the cell split can be maintained, which can ensure the overall consistency and coordination of the table.

[0226] In one embodiment, after each split content is filled into the corresponding split cell, the method further includes: adjusting the size of the split cell according to the filling content in the split cell. Among them, adjusting the size of the split cell can be to reduce the size of the split cell or to increase the size of the split cell. Reducing the size of the split cell usually occurs in the scene where the content in the cell is relatively small and the cell is slightly empty (with a large blank area) from a visual effect. Increasing the size of the split cell usually occurs in the scene where the content in the cell overflows the cell or the content in the cell is relatively crowded.

[0227] See for example Figure 8 In the example of (a), the method described in the above embodiment can classify "target cell 2" and "target cell 3" into one content group and fill them into the fourth split cell. However, if the size of the fourth split cell is not adjusted, "target cell 2 target cell 3" will not be fully displayed. By adjusting the size of the split cell according to the filling content in the split cell, the cell content can be completely contained within the border of the split cell (such as Figure 8 (b) Example).

[0228] In the above embodiment, after filling each split content into the corresponding split cell, the size of the split cell is adjusted according to the filling content in the split cell, so that the split cells can be kept beautiful and the overall consistency and coordination of the table can be ensured.

[0229] In one embodiment, after the target cell is split based on the position of the split line to obtain at least two split cells, the method further includes: in response to an undo operation of splitting the target cell, restoring the original cell layout of the target cell.

[0230] The user can click the undo button or use the shortcut key to indicate the undo of the split operation on the target cell. Restoring the original cell layout of the cell includes restoring the size, position and content layout of the cell, as well as any format or style changed by the split.

[0231] It can be seen that the embodiment of the present application provides complete functions of cell splitting and splitting cancellation, which can meet the actual usage needs of users to the greatest extent and improve the user experience.

[0232] In one embodiment, before displaying the split line in the target cell, it also includes: detecting whether the target cell meets the preset split condition; if it is determined that the target cell meets the split condition, executing the step of displaying the split line in the target cell; if it is determined that the target cell does not meet the split condition, outputting a prompt message indicating that splitting of the target cell is prohibited.

[0233] The preset splitting condition is: the current login account of the table has the splitting condition for the target cell. That is to say, the permission check is performed on the split cell operation triggered by the user. If it is determined that the current login account (also the initiator of the split operation) has the permission to perform the split operation on the target cell, the target cell is split to obtain at least two split cells. On the contrary, if it is determined that the current login account does not have the permission to perform the split operation on the target cell, the split operation on the target cell is refused.

[0234] Optionally, the current login account has the permission to split the target cell, including but not limited to the following situations: the current login account is the creator of the table. Usually, the creator of the table has all permissions to the table and can perform all reasonable operations on the table; the current login account is granted editing permissions to any cell in the table by the creator of the table; the current login account is granted editing permissions to the target cell; the current login account is granted the permission of the collaborative account that manages the table to the collaborative permissions of the table, that is, the current account can set the collaborative permissions of the collaborative account of the table; the current login account has editing permissions to the target cell, etc.

[0235] The above embodiments help prevent unauthorized users from making inappropriate modifications to tables, and help maintain the integrity of table data, especially in a team collaboration environment where different users may have different roles and permissions. Through the permission verification mechanism in the above embodiments, it can be ensured that users can only split tables within their permissions, thereby avoiding work conflicts and unnecessary coordination costs. This helps improve the smoothness of team collaboration.

[0236] Fig. 9This is a block diagram of an embodiment of a table processing device provided in an embodiment of the present application. Fig. 9 As shown, the device comprises:

[0237] A splitting strategy determination module 91 is used to determine a target splitting strategy indicated by the splitting instruction in response to a splitting instruction for a target cell in a table;

[0238] A cell splitting module 92, configured to split the target cell according to the target splitting strategy to obtain at least two split cells;

[0239] The cell display module 93 is used to replace the target cell with the at least two split cells.

[0240] In a possible implementation, the cell splitting module 92 includes:

[0241] Content splitting unit, used to divide the original cell content into different content blocks according to set rules;

[0242] The cell splitting unit is used to split the target cell based on the number and distribution of the content blocks to obtain at least two split cells.

[0243] In a possible implementation, the cell splitting module 92 includes:

[0244] A split line display unit, used to display a split line in the target cell;

[0245] a split line moving unit, configured to move the split line in the target cell in response to a drag operation on the split line;

[0246] A cell splitting unit is used to split the target cell based on the position of the splitting line to obtain at least two split cells

[0247] In a possible implementation manner, the split line display unit is specifically used for:

[0248] Determine the target split mode;

[0249] A split line matching the target split pattern is displayed in the target cell.

[0250] In a possible implementation, the device further includes:

[0251] A preview module is used to display a preview effect of the split cells obtained by splitting the target cell based on the current position of the split line after the split line is moved in the target cell in response to the dragging operation on the split line.

[0252] In a possible implementation, the device further includes:

[0253] A content splitting module, configured to split the original cell content in the target cell based on the position of the splitting line to obtain at least two split contents after splitting the target cell based on the position of the splitting line to obtain at least two split contents;

[0254] The content filling module is used to fill each of the split contents into the corresponding split cells.

[0255] In a possible implementation manner, the content splitting module is specifically used to:

[0256] Classifying the original cell contents on both sides of the split line in the target cell into different content groups respectively;

[0257] And, in the case where it is determined that part of the original cell content in the target cell is located on the split line, the part of the original cell content is classified into one of the content groups, or the part of the original cell content is divided into different content blocks, and different content blocks are classified into different content groups;

[0258] Each of the content groups is determined as a split content to obtain at least two split contents.

[0259] In a possible implementation manner, the content filling module is specifically used to:

[0260] Each of the split contents is filled into the corresponding split cell according to the original cell style of the target cell.

[0261] In a possible implementation, the device further includes:

[0262] The cell adjustment module is used to adjust the size of the split cells according to the filling content in the split cells after each of the split contents is filled into the corresponding split cells.

[0263] In a possible implementation, the device further includes:

[0264] A table adjustment module, configured to, after splitting the target cell according to the target splitting strategy to obtain at least two split cells, add a new cell to the table according to the at least two split cells and determine the cells to be merged if it is determined that splitting the target cell affects adjacent cells of the target cell;

[0265] The cells to be merged are merged to obtain corresponding merged cells.

[0266] In a possible implementation, the device further includes:

[0267] A detection module, used for detecting whether the target cell meets a preset splitting condition before splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0268] The split line display module is specifically used to: when it is determined that the target cell meets the split condition, execute the step of splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0269] The device also includes:

[0270] The message prompt module is used to output a prompt message indicating that the target cell is prohibited from being split when it is determined that the target cell does not meet the split condition.

[0271] In a possible implementation, the device further includes:

[0272] A recovery module is used to restore the original cell layout of the target cell in response to a split undo operation on the target cell after the target cell is replaced by the at least two split cells.

[0273] like Fig.10 As shown, an embodiment of the present application provides a device, including a processor 111, a communication interface 112, a memory 113 and a communication bus 114, wherein the processor 111, the communication interface 112, and the memory 113 communicate with each other through the communication bus 114.

[0274] Memory 113, used for storing computer programs;

[0275] In one embodiment of the present application, the processor 111 is used to implement the table processing method provided by any one of the aforementioned method embodiments when executing the program stored in the memory 113, including:

[0276] In response to a split instruction for a target cell in a table, determining a target split strategy indicated by the split instruction;

[0277] Splitting the target cell according to the target splitting strategy to obtain at least two split cells;

[0278] The target cell is replaced by the at least two split cells.

[0279] An embodiment of the present application further provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the table processing method provided in any of the aforementioned method embodiments are implemented.

[0280] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0281] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a general hardware platform, and of course, by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the relevant technology can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0282] It should be understood that the terms used herein are only for the purpose of describing specific example embodiments and are not intended to be limiting. Unless the context clearly indicates otherwise, the singular forms "one", "an" and "said" as used herein may also be meant to include plural forms. The terms "include", "comprise", "contain", and "have" are inclusive, and therefore specify the existence of stated features, steps, operations, elements and / or parts, but do not exclude the existence or addition of one or more other features, steps, operations, elements, parts, and / or combinations thereof. The method steps, processes, and operations described herein are not interpreted as necessarily requiring them to be performed in the specific order described or illustrated, unless the execution order is clearly indicated. It should also be understood that additional or alternative steps may be used.

[0283] The above description is only a specific implementation of the present application, so that those skilled in the art can understand or implement the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest range consistent with the principles and novel features applied for herein.

Claims

1. A table processing method, characterized in that: The method comprises: In response to a split instruction for a target cell in a table, determining a target split strategy indicated by the split instruction; Splitting the target cell according to the target splitting strategy to obtain at least two split cells; The target cell is replaced by the at least two split cells.

2. The method according to claim 1, characterized in that The target cell is split according to the target splitting strategy to obtain at least two split cells, including: Divide the original cell content into different content blocks according to the set rules; Based on the number and distribution of the content blocks, the target cell is split to obtain at least two split cells.

3. The method according to claim 1, characterized in that The target cell is split according to the target splitting strategy to obtain at least two split cells, including: Displaying a split line in the target cell; In response to a drag operation on the split line, moving the split line in the target cell; The target cell is split based on the position of the split line to obtain at least two split cells.

4. The method according to claim 3, characterized in that Displaying a split line in the target cell, including: Determine the target split mode; A split line matching the target split pattern is displayed in the target cell.

5. The method according to claim 3, characterized in that: After moving the split line in the target cell in response to the dragging operation on the split line, the method further includes: A preview effect of the split cells obtained by splitting the target cell based on the current position of the split line is displayed.

6. The method according to claim 3, characterized in that: After the target cell is split based on the position of the split line to obtain at least two split cells, the method further includes: Splitting the original cell content in the target cell based on the position of the split line to obtain at least two split contents; Each of the split contents is filled into the corresponding split cells respectively.

7. The method according to claim 6, characterized in that The step of splitting the original cell content in the target cell based on the position of the split line to obtain at least two split contents includes: Classifying the original cell contents on both sides of the split line in the target cell into different content groups respectively; And, in the case where it is determined that part of the original cell content in the target cell is located on the split line, the part of the original cell content is classified into one of the content groups, or the part of the original cell content is divided into different content blocks, and different content blocks are classified into different content groups; Each of the content groups is determined as a split content to obtain at least two split contents.

8. The method according to claim 6, characterized in that The step of filling each of the split contents into the corresponding split cells respectively includes: Each of the split contents is filled into the corresponding split cell according to the original cell style of the target cell.

9. The method according to claim 6, characterized in that After filling each of the split contents into the corresponding split cells respectively, the method further includes: The size of the split cell is adjusted according to the filling content in the split cell.

10. The method according to claim 1, characterized in that After the target cell is split according to the target splitting strategy to obtain at least two split cells, the method further includes: In the case where it is determined that splitting the target cell affects adjacent cells of the target cell, adding a new cell to the table according to the at least two split cells, and determining cells to be merged; The cells to be merged are merged to obtain corresponding merged cells.

11. The method according to claim 1, characterized in that: Before splitting the target cell according to the target splitting strategy to obtain at least two split cells, the method further includes: Detecting whether the target cell meets a preset splitting condition; When it is determined that the target cell satisfies the splitting condition, executing the step of splitting the target cell according to the target splitting strategy to obtain at least two split cells; When it is determined that the target cell does not satisfy the splitting condition, a prompt message indicating that splitting of the target cell is prohibited is output.

12. The method according to claim 1, characterized in that After replacing the target cell with the at least two split cells, the method further comprises: In response to the split undo operation on the target cell, the original cell layout of the target cell is restored.

13. A table processing device, characterized in that: The device comprises: A splitting strategy determination module, configured to determine, in response to a splitting instruction for a target cell in a table, a target splitting strategy indicated by the splitting instruction; A cell splitting module, used to split the target cell according to the target splitting strategy to obtain at least two split cells; The cell display module is used to replace the target cell with the at least two split cells.

14. An electronic device, characterized in that: include: A processor and a memory, wherein the processor is used to execute a table processing program stored in the memory to implement the table processing method according to any one of claims 1 to 12.

15. A storage medium, characterized in that: The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the table processing method according to any one of claims 1 to 12.