[go: up one dir, main page]

CN111985203B - Document processing method, document processing device and electronic equipment - Google Patents

Document processing method, document processing device and electronic equipment Download PDF

Info

Publication number
CN111985203B
CN111985203B CN202010815995.2A CN202010815995A CN111985203B CN 111985203 B CN111985203 B CN 111985203B CN 202010815995 A CN202010815995 A CN 202010815995A CN 111985203 B CN111985203 B CN 111985203B
Authority
CN
China
Prior art keywords
content
content blocks
blocks
document processing
sequence
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010815995.2A
Other languages
Chinese (zh)
Other versions
CN111985203A (en
Inventor
刘志添
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co Ltd filed Critical Vivo Mobile Communication Co Ltd
Priority to CN202010815995.2A priority Critical patent/CN111985203B/en
Publication of CN111985203A publication Critical patent/CN111985203A/en
Application granted granted Critical
Publication of CN111985203B publication Critical patent/CN111985203B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/258Heading extraction; Automatic titling; Numbering
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/189Automatic justification

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本申请公开了一种文档处理方法、文档处理装置和电子设备,属于信息处理技术领域。其中,所述文档处理方法包括:获取内容块以及每一所述内容块对应的内容标题和序号;根据所述内容标题和所述序号的优先级,对所述内容块进行重新排版。在本申请实施例中,通过使每一内容块对应于一个内容标题和一个序号,从而使文档中的所有内容块可以按照内容标题和序号的既定优先级进行重新排版,实现了文档的自动、准确重新排版的目的,可以有效提高文档的处理效率。

The present application discloses a document processing method, a document processing device and an electronic device, which belong to the field of information processing technology. The document processing method includes: obtaining content blocks and content titles and serial numbers corresponding to each content block; and rearranging the content blocks according to the priorities of the content titles and serial numbers. In an embodiment of the present application, by making each content block correspond to a content title and a serial number, all content blocks in the document can be rearranged according to the established priorities of the content titles and serial numbers, thereby achieving the purpose of automatic and accurate rearrangement of the document, and effectively improving the processing efficiency of the document.

Description

Document processing method, document processing device and electronic equipment
Technical Field
The application belongs to the technical field of information processing, and particularly relates to a document processing method, a document processing device and electronic equipment.
Background
In daily learning, working and other scenes, editing, searching and rearrangement of documents are often involved, and the documents contain various kinds of information such as pictures, characters, image-text combinations and the like. Editing of a document takes Word, power Point, visio, excel and Photoshop of Office series as examples, and can support contents in various formats, however, for a rearranged version of the document, no mature scheme can realize quick and accurate rearrangement of the document in the market at present.
Disclosure of Invention
The embodiment of the application aims to provide a document processing method, a document processing device and electronic equipment, which can solve the problems that in the prior art, manual operation is required for document rearrangement, the operation process is complicated and automatic typesetting cannot be realized.
In order to solve the technical problems, the application is realized as follows:
In a first aspect, an embodiment of the present application provides a document processing method, including:
acquiring a content block and a content title and a sequence number corresponding to each content block;
And re-typesetting the content blocks according to the priorities of the content titles and the serial numbers.
In a second aspect, an embodiment of the present application provides a document processing apparatus including:
The acquisition module is used for acquiring the content blocks and the content titles and serial numbers corresponding to each content block;
And the typesetting module is used for typesetting the content blocks again according to the priorities of the content titles and the serial numbers.
In a third aspect, an embodiment of the present application provides an electronic device, including a processor, a memory, and a program or instructions stored on the memory and executable on the processor, the program or instructions implementing the steps of the document processing method according to the first aspect when executed by the processor.
In a fourth aspect, embodiments of the present application provide a readable storage medium having stored thereon a program or instructions which when executed by a processor implement the steps of the document processing method according to the first aspect.
In a fifth aspect, an embodiment of the present application provides a chip, where the chip includes a processor and a communication interface, where the communication interface is coupled to the processor, and the processor is configured to execute a program or instructions to implement a document processing method according to the first aspect.
In the embodiment of the application, each content block corresponds to one content title and one sequence number, so that all the content blocks in the document can be rearranged according to the set priority of the content title and the sequence number, the purpose of automatic and accurate rearrangement of the document is realized, and the processing efficiency of the document can be effectively improved.
Drawings
FIG. 1 is a schematic flow chart of a document processing method according to an embodiment of the present application;
FIG. 2 is a schematic diagram of content blocks in an initial document provided by an embodiment of the present application;
FIG. 3 is a schematic view of a document after being rearranged according to an embodiment of the present application;
FIG. 4 is a schematic diagram of a content block after opening a privacy option according to an embodiment of the present application;
FIG. 5 is a schematic diagram showing a comparison between before and after document rearrangement according to an embodiment of the present application;
FIG. 6 is a schematic diagram of a document processing apparatus according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 8 is a schematic hardware structure of an electronic device according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all embodiments of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The terms first, second and the like in the description and in the claims, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged, as appropriate, such that embodiments of the present application may be implemented in sequences other than those illustrated or described herein, and that the objects identified by "first," "second," etc. are generally of a type, and are not limited to the number of objects, such as the first object may be one or more. Furthermore, in the description and claims, "and/or" means at least one of the connected objects, and the character "/", generally means that the associated object is an "or" relationship.
The document processing method, the document processing device and the electronic equipment provided by the embodiment of the application are described in detail through specific embodiments and application scenes thereof with reference to the accompanying drawings.
Referring to fig. 1, a flow chart of a document processing method according to an embodiment of the application is shown. As shown in fig. 1, the document processing method in the embodiment of the present application may include the steps of:
And 11, acquiring the content blocks and the content titles and serial numbers corresponding to each content block.
Referring to fig. 2, a schematic diagram of a content block in an initial document according to an embodiment of the present application is shown. As shown in fig. 2, in the embodiment of the present application, the content blocks may be text paragraphs, pictures, tables, image-text combinations, and the like, each content block is correspondingly provided with a content title and a sequence number, where the content title may be a summary of information expressed by the content block, and the sequence number is used to sort the content blocks, and the content title and the sequence number corresponding to each content block may be located in a previous row of each content block.
As shown in fig. 2, the first content block in fig. 2 is in the form of a graphic combination, in fig. 2, "tag=mew star" means that the content corresponding to the content block is entitled "mew star", and the content title is consistent with the information expressed by the content block, and "level=1.1" in fig. 2 means that the serial number corresponding to the content block is "1.1". Content titles and sequence numbers of other content blocks in fig. 2 and so on.
And 12, rearranging the content blocks according to the priorities of the content titles and the serial numbers.
Referring to fig. 3, a schematic diagram of a document after being rearranged according to an embodiment of the present application is shown. As shown in FIG. 3, since each content block is correspondingly provided with a content title and a sequence number, the document can be rearranged and displayed according to the priorities of the content titles and the sequence numbers, and as can be seen from FIG. 3, the format of the document after being rearranged is uniform, the logic arrangement among the content blocks is more accurate, the tedious process of manually adjusting the format and the sequence of the content blocks is omitted, and the processing speed of the document is improved.
In the embodiment of the application, the priorities of the content titles and the sequence numbers can be divided into two cases that the priorities of the content titles are higher than the priorities of the sequence numbers and the priorities of the sequence numbers are higher than the priorities of the content titles, and in general, the case that the priorities of the content titles are higher than the priorities of the sequence numbers of the content blocks are represented by the fact that the importance degree of the content of the user on the content blocks is higher than the importance degree of the sequence numbers of the content blocks, and the case that the priorities of the sequence numbers are higher than the priorities of the content titles is opposite to the importance degree of the content blocks, and the priorities of the content titles and the sequence numbers can be preset and can also be adjusted according to different requirements when the document processing is carried out.
The following describes two cases of priority of the content title and sequence number, respectively.
In the embodiment of the present application, the sequence numbers are divided into a plurality of levels, and the step of rearranging the content blocks according to the priorities of the content titles and the sequence numbers includes:
under the condition that the priority of the serial numbers is higher than that of the content titles, content blocks corresponding to the serial numbers of the same level are aggregated to obtain a plurality of aggregation units;
sequencing the aggregation units according to the sequence number level;
and sequencing the content blocks in each aggregation unit according to the sequence number corresponding to each content block from small to large.
Specifically, the sequence numbers of the content blocks may be divided into a plurality of levels, and the Level of the sequence number corresponding to each content block is uniquely determined, and as illustrated in fig. 2, the levels of the sequence numbers "1.1" and "1.2" in "level=1.1" and "1.2" are the same, and as such, the levels of the sequence numbers "2.1" and "2.2" in "level=2.1" are the same, and the levels of the sequence numbers "1.1" and "1.2" are higher than the levels of the sequence numbers "2.1" and "2.2".
Based on the above hierarchical setting of the sequence numbers, when the priority of the sequence numbers is higher than the priority of the content titles, it is indicated that the importance of the content blocks by the user is lower than that of the sequence numbers of the content blocks, that is, the order of the content blocks tends to be more accurate, so when the content blocks are rearranged, firstly, the content blocks corresponding to the sequence numbers of the same level need to be preferentially aggregated to obtain a plurality of aggregation units, for example, the content blocks corresponding to the sequence numbers "1.1" and the content blocks corresponding to the sequence numbers "1.2" are aggregated into one aggregation unit, and the content blocks corresponding to the sequence numbers "2.1" and the content blocks corresponding to the sequence numbers "2.2" are aggregated into another aggregation unit, and generally, the hierarchical number of the sequence numbers corresponds to the number of aggregation units; then, since the ranks of the sequence numbers corresponding to the content blocks in the same aggregation unit are the same, but the ranks of the sequence numbers corresponding to the different aggregation units are naturally different, thereby, all the aggregation units can be ordered according to the ranks of the sequence numbers, for example, since the ranks of the sequence numbers "1.1" and the sequence numbers "1.2" are higher than the ranks of the sequence numbers "2.1" and the sequence numbers "2.2", the aggregation units formed by aggregating the content blocks corresponding to the sequence numbers "1.1" and the content blocks corresponding to the sequence numbers "1.2" are arranged in front of the aggregation units formed by aggregating the content blocks corresponding to the sequence numbers "2.1" and the content blocks corresponding to the sequence numbers "2.2", and so on, finally, for the content blocks aggregated into each aggregation unit, the sequence numbers corresponding to each content block are ordered according to the sequence from small to large sequence, for example, the value of the sequence numbers "1.1" is smaller than the value of the sequence numbers "1.2", the content blocks corresponding to the sequence number '1.1' are arranged in front of the content blocks corresponding to the sequence number '1.2', and the like, so that the ordering of the content blocks in all aggregation units is finally completed, and then the content blocks are output to the document according to the finally obtained arrangement sequence of the content blocks, namely, the document after the rearrangement is obtained, and the document can be displayed according to the order. By the document processing method, automatic document rearrangement can be realized, the tedious process of manually adjusting content blocks is omitted, and optionally, a uniform format can be set for the content blocks corresponding to the sequence numbers of each level, so that the condition that the formats of partial content blocks are not uniform is avoided, the typesetting of the whole document is tidier and more attractive, and the reading is convenient.
In the embodiment of the present application, optionally, the step of aggregating content blocks corresponding to serial numbers of the same level to obtain a plurality of aggregation units includes:
and under the condition that the number of the content blocks corresponding to the serial numbers of the same level is larger than a preset value, selecting the content blocks with the number equal to the preset value from the content blocks corresponding to the serial numbers of the same level for aggregation.
That is, in the process of aggregating content blocks corresponding to the same-level sequence numbers, when the number of content blocks corresponding to the same-level sequence numbers is greater than a preset value, the aggregation unit cannot accommodate all content blocks corresponding to the same-level sequence numbers, and at this time, content blocks with the same number as the preset value are selected from content blocks corresponding to the same-level sequence numbers for aggregation, so that the number of content blocks contained in the aggregation unit formed by aggregation is the corresponding preset value, thereby realizing control of the number of content blocks in the aggregation unit and achieving the purpose of simplifying documents. The preset value of the number of the content blocks contained in each aggregation unit can be set by a user according to the conditions of the number of the content blocks in the original document, and by setting the preset value of the number of the content blocks contained in each aggregation unit, the purpose of simplifying the document can be achieved by selecting part of the content blocks from the document to be typeset and displayed again when the document content blocks are more.
In the embodiment of the present application, the step of selecting, from the content blocks corresponding to the serial numbers of the same level, a content block with the number equal to the preset value for aggregation includes:
and under the condition that the number of the content blocks of the same content titles is larger than the preset value, selecting the content blocks of the same content titles with the number equal to the preset value from small to large according to the sequence number of the content blocks to aggregate.
Specifically, when the number of content blocks corresponding to the serial numbers of the same level is greater than the preset value, and the number of content blocks of the same content title is also greater than the preset value, the content blocks equal to the preset value are selected from the content blocks of the same content title according to the sequence of the serial numbers of the content blocks from small to large for aggregation, so that when the number of the content blocks corresponding to the serial numbers of the same level is greater, the content blocks corresponding to the content blocks of the same content title are preferentially selected for aggregation, and the content association degree of each content block in an aggregation unit obtained by aggregation is higher.
Optionally, when the number of content blocks corresponding to the sequence numbers of the same level is greater than the preset value, and the number of content blocks of the same content title is less than the preset value, only the content blocks with the number equal to the preset value are selected from the content blocks corresponding to the sequence numbers of the content blocks of the same level from small to large for aggregation, so that when the content blocks of the same content title are fewer, the content blocks are selected from small to large for aggregation, and sequence of sequence numbers of the content blocks in an aggregation unit obtained by aggregation is continuous, and arrangement logic among the content blocks is more prominent.
In this embodiment of the present application, optionally, the preset value of the number of content blocks included in each aggregation unit may be an upper threshold, that is, at most, the preset value is not exceeded, but may be less than the preset value.
In the embodiment of the present application, the step of rearranging the content blocks according to the priorities of the content titles and the sequence numbers includes:
Under the condition that the priority of the serial number is lower than the priority of the content title, content blocks corresponding to the same content title are aggregated to obtain a plurality of aggregation units;
Sorting the aggregation units according to the preset sequence of the content titles;
and sequencing the content blocks in each aggregation unit according to the sequence number corresponding to each content block from small to large.
Specifically, each content block corresponds to a content title, as shown in fig. 2, for example, "tag=mew" means that the content title corresponding to the content block is "mew star", and "tag=maw" means that the content title corresponding to the content block is "maw", and generally, based on the content title setting of such content block, when the priority of the sequence number is lower than that of the content title, the importance degree of the user on the content of the content block is higher than that of the sequence number of the content block, that is, the content between adjacent content blocks tends to be more similar, therefore, when the content blocks are rearranged, firstly, the content blocks corresponding to the same content title need to be aggregated to obtain a plurality of aggregation units, for example, the content blocks with the content title of "maw" are aggregated to one aggregation unit, and the content title of the content block with the "maw" is aggregated to another aggregation unit, generally, the number of different content titles corresponds to the number of aggregation units, the number of the aggregation units can be ensured by such aggregation unit, the content title of the content title corresponding to the preset content title is higher than that the content title of the content title corresponding to the preset unit in the sequence number of the aggregation unit, and the content title of the content title can be the same as the content title, and the content title corresponding to the content title of the content title is ranked in the same order, and the content title is higher than the content title corresponding to the content title of the content title is, and the content title corresponding to the content title is different in the content title sequence with the content title sequence title is different in the content title order, the method comprises the steps of arranging the aggregation units with the content title of "Miaoxing person" in front of the aggregation units with the content title of "Miaoxing person" by adopting the preset sequence of the reverse order of the sound sequence after the sound sequence of "diffuse" in the content title of "diffuse" of Miaoxing person ", arranging the aggregation units with the content title of" diffuse "in front of the aggregation units of" Miaoxing person "and the like, realizing the arrangement of the sequence among different aggregation units, finally, aiming at the content blocks aggregated into each aggregation unit, arranging according to the sequence from small to large, for example, the value of the sequence number corresponding to each content block is smaller than the value of the sequence number of" 1.1", so that the content blocks corresponding to the sequence number of" 1.1 "are arranged in front of the content blocks corresponding to the sequence number of" 1.2", and the like, finally completing the arrangement of the content blocks in all the aggregation units, and outputting the document after the rearrangement according to the arrangement sequence of the finally obtained content blocks, namely, displaying according to the arrangement. By the document processing method, automatic document rearrangement can be realized, the tedious process of manually adjusting content blocks is omitted, and optionally, a uniform format can be set for the content blocks corresponding to each content title, so that the condition that the formats of partial content blocks are not uniform is avoided, the whole document typesetting is tidier and more attractive, and the reading is convenient.
In the embodiment of the present application, the step of aggregating content blocks corresponding to the same content title to obtain a plurality of aggregation units includes:
And under the condition that the number of content blocks corresponding to the same content title is larger than a preset value, selecting and aggregating the content blocks with the number equal to the preset value according to the sequence from the sequence number of the content blocks to the sequence number of the content blocks.
That is, in the process of aggregating the content blocks corresponding to the same content title, when the number of content blocks corresponding to the same content title is greater than a preset value, it means that the aggregation unit cannot accommodate all the content blocks corresponding to the same content title, and then the content blocks equal to the preset value should be selected from the content blocks corresponding to the same content title for aggregation, so that the number of content blocks included in the aggregation unit formed by aggregation is the corresponding preset value, thereby realizing control of the number of content blocks in the aggregation unit and achieving the purpose of simplifying documents. The preset value of the number of the content blocks contained in each aggregation unit can be set by a user according to the conditions of the number of the content blocks in the original document, and by setting the preset value of the number of the content blocks contained in each aggregation unit, the purpose of simplifying the document can be achieved by selecting part of the content blocks from the document to be typeset and displayed again when the document content blocks are more.
Also, in this embodiment of the present application, optionally, the preset value of the number of content blocks included in each aggregation unit may be an upper threshold, that is, at most, not exceed the preset value, but may be less than the preset value.
Optionally, in the process of selecting and aggregating content blocks with the number equal to the preset value from content blocks corresponding to the same content title, the content blocks with the number equal to the preset value can be selected and aggregated according to the sequence from small to large of the sequence numbers of the content blocks, so that the sequence numbers of the content blocks in an aggregation unit obtained by aggregation can be ensured to be more orderly, and the arrangement logic among the content blocks is more prominent.
In the embodiment of the present application, after the step of rearranging the content block, the method further includes:
Acquiring configuration information of rendering options corresponding to each content block, wherein the rendering options comprise at least one of sequence number hiding options and privacy options;
And rendering the sequenced sequence numbers and the content blocks according to the configuration information.
That is, before the steps of sorting, format processing and the like of all the content blocks are finished and finally displayed, configuration information of rendering options corresponding to each content block needs to be further acquired, the rendering options may include a hidden option and at least one of the options, the configuration information of the rendering options corresponding to each content block may be configured while the content block is created by the page is edited, for example, the hidden option includes two options of hiding and non-hiding, when the hiding is selected, the serial number of the content block may be hidden, and when the non-hiding is selected, the ordered serial number is displayed, and when the non-hiding is selected, the privacy option includes two options of opening and closing, for example, when the opening is selected, the corresponding content block may be rendered, so that a mosaic appears when the final display of the content block is performed, and when the closing is selected, the content block is not rendered, and the content of the content block is normally displayed. Optionally, a default option can be set, rendering is directly performed according to configuration information of the default option when rendering is performed each time, and if different rendering effects are required by a user, the rendering option is modified.
Fig. 4 is a schematic diagram of a content block after opening a privacy option according to an embodiment of the present application. As shown in fig. 4, after the privacy option is opened, the content block is demosaiced at the final display, thereby achieving the purpose of privacy protection.
Referring to fig. 5, a schematic diagram of comparison between before and after document rearrangement is provided in an embodiment of the present application. As shown in FIG. 5, the left page is an initial editing page, a user can create any content block and a content title and sequence number corresponding to the content block on the page, and the right page is a document obtained by re-typesetting all the content blocks in the left page by adopting the document processing method in the embodiment of the application, so that the whole document page is uniform in format and clear in logic, and is convenient for the user to read.
In the embodiment of the application, each content block corresponds to one content title and one sequence number, so that all the content blocks in the document can be rearranged according to the set priority of the content title and the sequence number, the purpose of automatic and accurate rearrangement of the document is realized, and the processing efficiency of the document can be effectively improved.
It should be noted that, in the document processing method provided in the embodiment of the present application, the execution body may be a document processing apparatus, or a control module for executing the document processing method in the document processing. In the embodiment of the application, the document processing device is taken as an example for executing a document loading processing method by the document processing device, and the document processing device provided by the embodiment of the application is described.
Referring to fig. 6, a schematic diagram of a document processing apparatus according to an embodiment of the present application is shown. As shown in fig. 6, another embodiment of the present application further provides a document processing apparatus, the document processing apparatus 60 may include:
an obtaining module 61, configured to obtain content blocks and content titles and sequence numbers corresponding to each of the content blocks;
And the typesetting module 62 is configured to rearrange the content blocks according to the content titles and the priorities of the sequence numbers.
Optionally, the serial numbers are divided into a plurality of levels, and the typesetting module 62 includes:
the first classification unit is used for aggregating the content blocks corresponding to the serial numbers of the same level under the condition that the priority of the serial numbers is higher than that of the content titles, so as to obtain a plurality of aggregation units;
The first ordering unit is used for ordering the aggregation units according to the grades of the sequence numbers;
And the first typesetting unit is used for sequencing the content blocks in each aggregation unit according to the sequence from the small sequence number to the large sequence number.
Optionally, the first classification unit includes:
and the first classification subunit is used for selecting and aggregating the content blocks with the number equal to the preset value from the content blocks corresponding to the serial numbers of the same level under the condition that the number of the content blocks corresponding to the serial numbers of the same level is larger than the preset value.
Optionally, the classifying subunit includes:
And the first classification micro unit is used for selecting and aggregating the content blocks of the same content title with the number equal to the preset value according to the sequence from the small number to the large number of the content blocks under the condition that the number of the content blocks of the same content title is larger than the preset value.
Optionally, the typesetting module 62 includes:
The second classification unit is used for aggregating the content blocks corresponding to the same content title under the condition that the priority of the serial number is lower than the priority of the content title, so as to obtain a plurality of aggregation units;
The second ordering unit is used for ordering the aggregation units according to the preset sequence of the content titles;
And the second typesetting unit is used for sequencing the content blocks in each aggregation unit according to the sequence from small to large corresponding to each content block.
Optionally, the second classification unit includes:
And the second classification subunit is used for selecting and aggregating the content blocks with the number equal to the preset value according to the sequence from the small sequence number to the large sequence number of the content blocks under the condition that the number of the content blocks corresponding to the same content title is larger than the preset value.
Optionally, the method further comprises:
the configuration module is used for acquiring configuration information of rendering options corresponding to each content block, wherein the rendering options comprise at least one of sequence number hiding options and privacy options;
and the rendering module is used for rendering the sequenced sequence numbers and the content blocks according to the configuration information.
In the embodiment of the application, each content block corresponds to one content title and one sequence number, so that all the content blocks in the document can be rearranged according to the set priority of the content title and the sequence number, the purpose of automatic and accurate rearrangement of the document is realized, and the processing efficiency of the document can be effectively improved.
The document processing device in the embodiment of the application can be a device, a component in a terminal, an integrated circuit or a chip. The device may be a mobile electronic device or a non-mobile electronic device. By way of example, the mobile electronic device may be a mobile phone, a tablet computer, a notebook computer, a palm computer, a vehicle-mounted electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook or a Personal Digital Assistant (PDA), etc., and the non-mobile electronic device may be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a Television (TV), a teller machine, a self-service machine, etc., and the embodiments of the present application are not limited in particular.
The document processing device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an ios operating system, or other possible operating systems, and the embodiment of the present application is not limited specifically.
The document processing device provided by the embodiment of the present application can implement each process implemented by the embodiments of the document processing methods of fig. 1 to 5, and in order to avoid repetition, a description is omitted here.
Optionally, as shown in fig. 7, the embodiment of the present application further provides an electronic device 70, including a processor 71, a memory 72, and a program or an instruction stored in the memory 72 and capable of running on the processor 71, where the program or the instruction implements each process of the above-mentioned embodiment of the document processing method when executed by the processor 71, and the process can achieve the same technical effects, and for avoiding repetition, a description is omitted herein.
The electronic device in the embodiment of the application includes the mobile electronic device and the non-mobile electronic device.
Fig. 8 is a schematic diagram of a hardware structure of an electronic device implementing an embodiment of the present application.
The electronic device 80 includes, but is not limited to, a radio frequency unit 81, a network module 82, an audio output unit 83, an input unit 84, a sensor 85, a display unit 86, a user input unit 87, an interface unit 88, a memory 89, and a processor 810.
Those skilled in the art will appreciate that the electronic device 80 may also include a power source (e.g., a battery) for powering the various components, which may be logically connected to the processor 810 by a power management system to perform functions such as managing charge, discharge, and power consumption by the power management system. The electronic device structure shown in fig. 8 does not constitute a limitation of the electronic device, and the electronic device may include more or less components than shown, or may combine certain components, or may be arranged in different components, which are not described in detail herein.
A user input unit 87, configured to obtain content blocks and content titles and serial numbers corresponding to each of the content blocks;
A processor 810 for rearranging the content blocks according to the priorities of the content titles and the sequence numbers;
And a display unit 86 for displaying the document after the rearrangement.
In the embodiment of the application, each content block corresponds to one content title and one sequence number, so that all the content blocks in the document can be rearranged according to the set priority of the content title and the sequence number, the purpose of automatic and accurate rearrangement of the document is realized, and the processing efficiency of the document can be effectively improved.
Optionally, the sequence number is divided into a plurality of levels, and the processor 810 is further configured to:
under the condition that the priority of the serial numbers is higher than that of the content titles, content blocks corresponding to the serial numbers of the same level are aggregated to obtain a plurality of aggregation units;
sequencing the aggregation units according to the sequence number level;
And sequencing the content blocks in each aggregation unit according to the sequence from small to large of the sequence numbers corresponding to the content blocks, and displaying the sequenced sequence numbers and content blocks.
Optionally, the processor 810 is further configured to select, when the number of content blocks corresponding to the sequence numbers of the same level is greater than a preset value, content blocks equal to the preset value from the content blocks corresponding to the sequence numbers of the same level for aggregation.
Optionally, the step of selecting, from the content blocks corresponding to the serial numbers of the same level, a number of content blocks equal to the preset value for aggregation includes:
And under the condition that the number of the content blocks of the same content titles is larger than the preset value, selecting the content blocks of the same content titles with the number equal to the preset value from small to large according to the sequence of the sequence numbers of the content blocks to aggregate.
Optionally, the processor 810 is further configured to aggregate content blocks corresponding to the same content title to obtain a plurality of aggregation units if the priority of the sequence number is lower than the priority of the content title;
Sorting the aggregation units according to the preset sequence of the content titles;
and sequencing the content blocks in each aggregation unit according to the sequence number corresponding to each content block from small to large.
Optionally, the processor 810 is further configured to:
And under the condition that the number of content blocks corresponding to the same content title is larger than a preset value, selecting and aggregating the content blocks with the number equal to the preset value according to the sequence from the sequence number of the content blocks to the sequence number of the content blocks.
Optionally, the processor 810 is further configured to:
Acquiring configuration information of rendering options corresponding to each content block, wherein the rendering options comprise at least one of sequence number hiding options and privacy options;
And rendering the sequenced sequence numbers and the content blocks according to the configuration information.
It should be appreciated that in embodiments of the present application, the input unit 84 may include a graphics processor (Graphics Processing Unit, GPU) 841 and a microphone 842, the graphics processor 841 processing image data of still pictures or video obtained by an image capture device (e.g., a camera) in a video capture mode or an image capture mode. The display unit 86 may include a display panel 861, and the display panel 861 may be configured in the form of a liquid crystal display, an organic light emitting diode, or the like. The user input unit 87 includes a touch panel 871 and other input devices 872. The touch panel 871 is also called a touch screen. The touch panel 871 may include two parts, a touch detection device and a touch controller. Other input devices 872 may include, but are not limited to, a physical keyboard, function keys (e.g., volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and so forth, which are not described in detail herein. Memory 89 may be used to store software programs as well as various data including, but not limited to, application programs and an operating system. The processor 810 may integrate an application processor that primarily handles operating systems, user interfaces, applications, etc., with a modem processor that primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 810.
The embodiment of the application also provides a readable storage medium, on which a program or an instruction is stored, which when executed by a processor, implements each process of the above-mentioned document processing method embodiment, and can achieve the same technical effects, and in order to avoid repetition, the description is omitted here.
Wherein the processor is a processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium such as a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and the like.
The embodiment of the application further provides a chip, which comprises a processor and a communication interface, wherein the communication interface is coupled with the processor, and the processor is used for running programs or instructions to realize the processes of the embodiment of the document processing method, and can achieve the same technical effects, so that repetition is avoided, and the description is omitted here.
It should be understood that the chips referred to in the embodiments of the present application may also be referred to as system-on-chip chips, chip systems, or system-on-chip chips, etc.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element. Furthermore, it should be noted that the scope of the methods and apparatus in the embodiments of the present application is not limited to performing the functions in the order shown or discussed, but may also include performing the functions in a substantially simultaneous manner or in an opposite order depending on the functions involved, e.g., the described methods may be performed in an order different from that described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. ROM/RAM, magnetic disk, optical disk) comprising instructions for causing a terminal (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to perform the method according to the embodiments of the present application.
The embodiments of the present application have been described above with reference to the accompanying drawings, but the present application is not limited to the above-described embodiments, which are merely illustrative and not restrictive, and many forms may be made by those having ordinary skill in the art without departing from the spirit of the present application and the scope of the claims, which are to be protected by the present application.

Claims (14)

1.一种文档处理方法,其特征在于,包括:1. A document processing method, comprising: 获取内容块以及每一所述内容块对应的内容标题和序号;Obtaining content blocks and content titles and serial numbers corresponding to each of the content blocks; 根据所述内容标题和所述序号的优先级,对所述内容块进行重新排版;Rearranging the content blocks according to the priorities of the content titles and the serial numbers; 所述序号分为多个等级,所述根据所述内容标题和所述序号的优先级,对所述内容块进行重新排版的步骤包括:The serial numbers are divided into multiple levels, and the step of rearranging the content blocks according to the priorities of the content titles and the serial numbers comprises: 在所述序号的优先级高于所述内容标题的优先级的情况下,对相同等级的序号所对应的内容块进行聚合,得到若干聚合单元;In the case where the priority of the sequence number is higher than the priority of the content title, aggregating the content blocks corresponding to the sequence numbers of the same level to obtain a plurality of aggregation units; 将所述若干聚合单元按照序号的等级进行排序;Sorting the plurality of polymerization units according to the levels of the serial numbers; 对每一所述聚合单元中的内容块按照各内容块对应的序号由小到大的顺序进行排序。The content blocks in each of the aggregation units are sorted in ascending order according to the sequence numbers corresponding to the content blocks. 2.根据权利要求1所述的文档处理方法,其特征在于,所述对相同等级的序号所对应的内容块进行聚合,得到若干聚合单元的步骤包括:2. The document processing method according to claim 1, wherein the step of aggregating content blocks corresponding to serial numbers of the same level to obtain a plurality of aggregated units comprises: 在相同等级的序号所对应的内容块的数量大于预设值的情况下,从相同等级的序号所对应的内容块中选取与所述预设值相等数量的内容块进行聚合。When the number of content blocks corresponding to serial numbers of the same level is greater than a preset value, content blocks of a number equal to the preset value are selected from the content blocks corresponding to serial numbers of the same level for aggregation. 3.根据权利要求2所述的文档处理方法,其特征在于,所述从相同等级的序号所对应的内容块中选取与所述预设值相等数量的内容块进行聚合的步骤包括:3. The document processing method according to claim 2, wherein the step of selecting a number of content blocks equal to the preset value from the content blocks corresponding to the sequence numbers of the same level for aggregation comprises: 在相同内容标题的内容块的数量大于所述预设值的情况下,按照所述内容块的序号由小到大的顺序选取与所述预设值相等数量的相同内容标题的内容块进行聚合。When the number of content blocks with the same content title is greater than the preset value, content blocks with the same content title equal to the preset value are selected for aggregation in ascending order of the sequence numbers of the content blocks. 4.根据权利要求1所述的文档处理方法,其特征在于,所述根据所述内容标题和所述序号的优先级,对所述内容块进行重新排版的步骤包括:4. The document processing method according to claim 1, wherein the step of rearranging the content blocks according to the priorities of the content titles and the sequence numbers comprises: 在所述序号的优先级低于所述内容标题的优先级的情况下,对相同内容标题所对应的内容块进行聚合,得到若干聚合单元;In the case where the priority of the sequence number is lower than the priority of the content title, aggregating the content blocks corresponding to the same content title to obtain a plurality of aggregation units; 将所述若干聚合单元按照所述内容标题的预设顺序进行排序;Sorting the plurality of aggregation units according to a preset order of the content titles; 对每一所述聚合单元中的内容块按照各内容块对应的序号由小到大的顺序进行排序。The content blocks in each of the aggregation units are sorted in ascending order according to the sequence numbers corresponding to the content blocks. 5.根据权利要求4所述的文档处理方法,其特征在于,所述对相同内容标题所对应的内容块进行聚合,得到若干聚合单元的步骤包括:5. The document processing method according to claim 4, characterized in that the step of aggregating content blocks corresponding to the same content title to obtain a plurality of aggregated units comprises: 在相同内容标题所对应的内容块的数量大于预设值的情况下,按照所述内容块的序号由小到大的顺序选取与所述预设值相等数量的内容块进行聚合。When the number of content blocks corresponding to the same content title is greater than a preset value, content blocks equal to the preset value are selected for aggregation in ascending order of the sequence numbers of the content blocks. 6.根据权利要求1所述的文档处理方法,其特征在于,所述对所述内容块进行重新排版的步骤之后,还包括:6. The document processing method according to claim 1, characterized in that after the step of rearranging the content block, it further comprises: 获取每一所述内容块对应的渲染选项的配置信息,所述渲染选项包括序号隐藏选项和隐私选项中的至少一项;Acquire configuration information of rendering options corresponding to each of the content blocks, wherein the rendering options include at least one of a sequence number hiding option and a privacy option; 根据所述配置信息,对排序后的序号和内容块进行渲染。The sorted sequence numbers and content blocks are rendered according to the configuration information. 7.一种文档处理装置,其特征在于,包括:7. A document processing device, comprising: 获取模块,用于内容块以及每一所述内容块对应的内容标题和序号;An acquisition module, used for content blocks and content titles and serial numbers corresponding to each of the content blocks; 排版模块,用于根据所述内容标题和所述序号的优先级,对所述内容块进行重新排版;A layout module, used for rearranging the content blocks according to the priorities of the content titles and the sequence numbers; 所述序号分为多个等级,所述排版模块包括:The serial numbers are divided into multiple levels, and the typesetting module includes: 第一分类单元,用于在所述序号的优先级高于所述内容标题的优先级的情况下,对相同等级的序号所对应的内容块进行聚合,得到若干聚合单元;A first classification unit is used to aggregate content blocks corresponding to sequence numbers of the same level to obtain a plurality of aggregation units when the priority of the sequence number is higher than the priority of the content title; 第一排序单元,用于将所述若干聚合单元按照序号的等级进行排序;A first sorting unit, used to sort the plurality of aggregation units according to the levels of the sequence numbers; 第一排版单元,用于对每一所述聚合单元中的内容块按照各内容块对应的序号由小到大的顺序进行排序。The first layout unit is used to sort the content blocks in each of the aggregation units in ascending order according to the sequence numbers corresponding to the content blocks. 8.根据权利要求7所述的文档处理装置,其特征在于,所述第一分类单元包括:8. The document processing device according to claim 7, wherein the first classification unit comprises: 第一分类子单元,用于在相同等级的序号所对应的内容块的数量大于预设值的情况下,从相同等级的序号所对应的内容块中选取与所述预设值相等数量的内容块进行聚合。The first classification subunit is used to select content blocks of a number equal to the preset value from the content blocks corresponding to the serial numbers of the same level for aggregation when the number of content blocks corresponding to the serial numbers of the same level is greater than the preset value. 9.根据权利要求8所述的文档处理装置,其特征在于,所述分类子单元包括:9. The document processing device according to claim 8, wherein the classification subunit comprises: 第一分类微单元,用于在相同内容标题的内容块的数量大于所述预设值的情况下,按照所述内容块的序号由小到大的顺序选取与所述预设值相等数量的相同内容标题的内容块进行聚合。The first classification micro-unit is used to select and aggregate content blocks with the same content title equal to the preset value in order of the sequence numbers of the content blocks from small to large when the number of content blocks with the same content title is greater than the preset value. 10.根据权利要求7所述的文档处理装置,其特征在于,所述排版模块包括:10. The document processing device according to claim 7, wherein the typesetting module comprises: 第二分类单元,用于在所述序号的优先级低于所述内容标题的优先级的情况下,对相同内容标题所对应的内容块进行聚合,得到若干聚合单元;a second classification unit, configured to aggregate content blocks corresponding to the same content title to obtain a plurality of aggregation units when the priority of the sequence number is lower than the priority of the content title; 第二排序单元,用于将所述若干聚合单元按照所述内容标题的预设顺序进行排序;A second sorting unit, used to sort the plurality of aggregation units according to a preset order of the content titles; 第二排版单元,用于对每一所述聚合单元中的内容块按照各内容块对应的序号由小到大的顺序进行排序。The second layout unit is used to sort the content blocks in each of the aggregation units in ascending order according to the sequence numbers corresponding to the content blocks. 11.根据权利要求10所述的文档处理装置,其特征在于,所述第二分类单元包括:11. The document processing device according to claim 10, wherein the second classification unit comprises: 第二分类子单元,用于在相同内容标题所对应的内容块的数量大于预设值的情况下,按照所述内容块的序号由小到大的顺序选取与所述预设值相等数量的内容块进行聚合。The second classification subunit is used to select and aggregate content blocks of a number equal to the preset value in ascending order of the sequence numbers of the content blocks when the number of content blocks corresponding to the same content title is greater than a preset value. 12.根据权利要求7所述的文档处理装置,其特征在于,还包括:12. The document processing device according to claim 7, further comprising: 配置模块,用于获取每一所述内容块对应的渲染选项的配置信息,所述渲染选项包括序号隐藏选项和隐私选项中的至少一项;A configuration module, configured to obtain configuration information of a rendering option corresponding to each of the content blocks, wherein the rendering option includes at least one of a sequence number hiding option and a privacy option; 渲染模块,用于根据所述配置信息,对排序后的序号和内容块进行渲染。A rendering module is used to render the sorted sequence numbers and content blocks according to the configuration information. 13.一种电子设备,其特征在于,包括处理器,存储器及存储在所述存储器上并可在所述处理器上运行的程序或指令,所述程序或指令被所述处理器执行时实现如权利要求1-6任一项所述的文档处理方法的步骤。13. An electronic device, characterized in that it comprises a processor, a memory, and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the document processing method according to any one of claims 1 to 6. 14.一种可读存储介质,其特征在于,所述可读存储介质上存储程序或指令,所述程序或指令被处理器执行时实现如权利要求1-6任一项所述的文档处理方法的步骤。14. A readable storage medium, characterized in that the readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the document processing method according to any one of claims 1 to 6 are implemented.
CN202010815995.2A 2020-08-14 2020-08-14 Document processing method, document processing device and electronic equipment Active CN111985203B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010815995.2A CN111985203B (en) 2020-08-14 2020-08-14 Document processing method, document processing device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010815995.2A CN111985203B (en) 2020-08-14 2020-08-14 Document processing method, document processing device and electronic equipment

Publications (2)

Publication Number Publication Date
CN111985203A CN111985203A (en) 2020-11-24
CN111985203B true CN111985203B (en) 2024-12-10

Family

ID=73434456

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010815995.2A Active CN111985203B (en) 2020-08-14 2020-08-14 Document processing method, document processing device and electronic equipment

Country Status (1)

Country Link
CN (1) CN111985203B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114997117A (en) * 2021-03-02 2022-09-02 北京字跳网络技术有限公司 Document editing method, device, terminal and non-transitory storage medium
CN115688693A (en) * 2021-07-21 2023-02-03 珠海金山办公软件有限公司 Document processing method, device, equipment and storage medium
CN114707470B (en) * 2022-04-20 2024-12-27 北京字跳网络技术有限公司 Document editing method, device, equipment and storage medium
US20250307527A1 (en) * 2022-10-31 2025-10-02 Beijing Zitiao Network Technology Co., Ltd. Method, apparatus, device and storage medium for document presentation

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110235123A (en) * 2017-02-02 2019-09-13 华为技术有限公司 Content aware power savings for web browsing using selective loading priority
CN111079402A (en) * 2019-12-31 2020-04-28 北大方正集团有限公司 Document hierarchy dividing method, document hierarchy dividing device, and readable storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102662921B (en) * 2012-03-29 2016-02-03 华为技术有限公司 A kind of document processing method, device and editing machine
CN103546505B (en) * 2012-07-12 2018-03-06 百度在线网络技术(北京)有限公司 The method, system and device that Segment is according to priority sequentially shown
US10203865B2 (en) * 2014-08-25 2019-02-12 International Business Machines Corporation Document content reordering for assistive technologies by connecting traced paths through the content
CN106802880B (en) * 2015-11-25 2020-12-04 创新先进技术有限公司 A kind of electronic document content display, processing method and device
CN110390091A (en) * 2018-04-18 2019-10-29 成都野望数码科技有限公司 A kind of typesetting document structure tree method, device and equipment

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110235123A (en) * 2017-02-02 2019-09-13 华为技术有限公司 Content aware power savings for web browsing using selective loading priority
CN111079402A (en) * 2019-12-31 2020-04-28 北大方正集团有限公司 Document hierarchy dividing method, document hierarchy dividing device, and readable storage medium

Also Published As

Publication number Publication date
CN111985203A (en) 2020-11-24

Similar Documents

Publication Publication Date Title
CN111985203B (en) Document processing method, document processing device and electronic equipment
US11023666B2 (en) Narrative-based media organizing system for transforming and merging graphical representations of digital media within a work area
US7546554B2 (en) Systems and methods for browsing multimedia content on small mobile devices
US11010034B2 (en) Automatic presentation of slide design suggestions
US20080144107A1 (en) Method for arranging a collection of visual content
US20170140250A1 (en) Content file image analysis
US11461943B1 (en) Mosaic display systems and methods for intelligent media search
US20140181646A1 (en) Dynamic layout system for remote content
CN113747230B (en) Audio and video processing method and device, electronic equipment and readable storage medium
KR20180073644A (en) Mobile user interface
CN103279496A (en) Terminal and display method of associated information
CN113157753B (en) Display method, device and electronic equipment
US20120109609A1 (en) Online media and presentation interaction method
CN115658209A (en) Notification message display method and device and electronic equipment
CN111724455A (en) Image processing method and electronic device
CN106469036B (en) Information display method and client
WO2019018062A1 (en) Organizing images automatically into image grid layout
CN117194653A (en) Word processing methods and devices
US8892560B2 (en) Intuitive management of electronic files
CN111859202A (en) Information collection method, device and electronic device
CN117311885A (en) Image viewing methods and devices
CN114416664A (en) Information display method, information display device, electronic apparatus, and readable storage medium
CN112925576B (en) Item link processing method, device, electronic device and storage medium
CN117666897A (en) Image display method, device, electronic equipment and readable storage medium
CN117453329A (en) Image display method, display device and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant