Specific embodiment
In order that the technical problem to be solved in the present invention, technical scheme and beneficial effect become more apparent, below in conjunction with
Drawings and Examples, the present invention will be described in further detail.It should be appreciated that specific embodiment described herein is only used
To explain the present invention, it is not intended to limit the present invention.
A kind of method of attaching of text is the embodiment of the invention provides, the executive agent of the method can be electronic equipment,
Fig. 1 is the flow chart of the method for attaching of text provided in an embodiment of the present invention, as shown in figure 1, the method comprising the steps of S110 is extremely
Step S140.
Step S110, obtains the content of text for replicating.
The content of text of duplication is usually that user is determined by adjusting the radio check mark in document, and user can be adjusted
Two positions of radio check mark in document, the text in the middle of two radio check marks is the content of text of duplication.
Step S120, parses content of text, determines the text type of content of text.
The feature of the text can be analyzed when parsing text content, text type is determined by feature.Such as text
This content is to intert 2 dashes in the middle of 11 bit digitals or 11 bit digitals, then the corresponding text type of this feature is phone
Number;If content of text includes " .com ", " .cn " or other domain suffix, the corresponding text type of this feature is
Domain name, further, can continue to segment text type by domain name, and such as text includes " .weibo.com ", then the spy
Corresponding text type is levied for microblogging.
Step S130, it is determined that the application program matched with text type.
A kind of text type may can be applied to one or more application program, therefore, it can to search with
All application programs of text type matching are supplied to user to select, for example, telephone number can match dialing, short message, communication
The program such as record and wechat, microblogging can match the program such as browser and microblogging client.
Step S140, starts application program, and content of text is pasted in the application, generates and show preview interface.
Locally presence is being determined, and after the application program of matched text type, the application journey of matching can called
Sequence, and perform paste operation.If only one of which application program is matching, start this application program;If many
Individual application program is matching, then start this multiple application program.
By the embodiment of the present invention, the application program of matching can be called to enter with the text type of automatic identification content of text
Row is pasted, and generates preview graph for user's selection.User need to only select required application program, eliminate manual switching application
The step of program and paste text, improve the convenience of paste operation.
The preferred embodiment of the present invention provides a kind of method of attaching of text, and the method can be embodiment illustrated in fig. 1
Preferred implementation.The method includes:
Step S110, obtains the content of text for replicating.
The content of text of duplication is usually that user is determined by adjusting the radio check mark in document, and user can be adjusted
Two positions of radio check mark in document, the text in the middle of two radio check marks is the content of text of duplication.
Step S120, parses content of text, determines the text type of content of text.
The feature of the text can be analyzed when parsing text content, text type is determined by feature.Wherein, text
This content can be numeral, word or webpage link address etc., and the embodiment of the present invention is not especially limited herein.Such as text
Content is to intert 2 dashes in the middle of 11 bit digitals or 11 bit digitals, then the corresponding text type of this feature is phone number
Code;If content of text includes " .com ", " .cn " or other domain suffix, the corresponding text type of this feature is domain
Name, further, can continue to segment text type by domain name, and such as text includes " .weibo.com ", then this feature
Corresponding text type is microblogging.
Step S130, it is determined that the application program matched with text type.
A kind of text type may can be applied to one or more application program, therefore, it can to search with
All application programs of text type matching are supplied to user to select, for example, telephone number can match dialing, short message, communication
The program such as record and wechat, microblogging can match the program such as browser and microblogging client.
Having various ways can determine the application program matched with text type, such as by checking the power of each application program
Limit information, or by default mapping table etc..
Fig. 2 is the flow chart of the method that matching application program is searched for by authority information provided in an embodiment of the present invention.Should
Method is a kind of preferred implementation of step S130, as shown in Fig. 2 the method includes:
Step S1301, reads local application list, and local application list includes multiple application programs.
The all application programs included on the electronic equipment are have recorded in local application list.
Step S1302, reads the authority information of each application program respectively.
Every kind of application program all has authority information, and the application program for example having reads telephone number, some application programs
Read memorandum etc..In the electronic equipment having, authority information is further divided into default privilege information and user's authorization privilege
To read telephone number and reading geographical position, user prohibits reading ground to the default privilege information of information, such as application program
Reason position, then user's authorization privilege information is reading telephone number.The present embodiment can read default privilege information, that is, pass through
Default privilege information knows that each application program has the ability for processing which information.
Step S1303, judges whether text type matches authority information.
If it is determined that replicating the text type of text, such as text type is telephone number, then be can decide whether
Having telephone number can match authority information, through comparing, it is determined that " reading telephone number " can be matched, that is, read telephone number this
One authority information may use telephone number.
Step S1304, it is determined that after text type matching authority information, determining that text type matching authority information is corresponding
Application program.
It is determined that after authority information involved by text type, the authority information of each application program is read one by one, so that it is determined that
Which application program includes the authority information, for example, determine that text type is telephone number, it is determined that the authority information being related to is to read
After taking telephone number, you can read the authority information of each application program, judge which application program needs to read telephone number.Need
The application program for reading telephone number is exactly the application program matched with content of text.
Fig. 3 is the flow chart of the method that matching application program is searched for by mapping table provided in an embodiment of the present invention.
The method is another preferred implementation of step S130, as shown in figure 3, the method includes:
Step S1305, reads default mapping table, and mapping table includes that text type is right with application program
Should be related to.
Mapping table can be related hardware manufacturers or software producer provides, note in the mapping table
The corresponding application program of various text types is recorded, further, the mapping table can provide calling for each application program
The information such as interface.Such as mapping table directly have recorded the corresponding application program of telephone number, including:It is dialing, short message, logical
News record and wechat etc..
Step S1306, search application program corresponding with text type in mapping table.
It is determined that after corresponding application program, can be searched for by above-mentioned local application list or calling interface
Application program.Such as mapping table have recorded corresponding application program includes dialing, short message, address list and wechat, then can
Check locally there is above-mentioned which application program with by local application list;Or can be by checking each calling interface
Situation, the unobstructed application program of calling interface information is the application program for being present in local and matched text type.
Step S140, starts application program, and content of text is pasted in the application, generates and show preview interface.
Locally presence is being determined, and after the application program of matched text type, the application journey of matching can called
Sequence, and perform paste operation.If only one of which application program is matching, start this application program;If many
Individual application program is matching, then start this multiple application program.
Fig. 4 is the flow chart of the method for calling application program to perform paste operation provided in an embodiment of the present invention, the method
It is a kind of preferred implementation of step S140, is a kind of processing mode to multiple matching reference program.As shown in figure 4, should
Method includes:
Step S1401, backstage starts multiple application programs matched with text type.
The application program of matching is probably multiple, and this step starts the application program of all matchings on backstage.
Step S1402, performs paste operation in multiple application programs, generates preview interface.
Pasted in the search box or input frame of each application program and replicate text, generate corresponding preview interface, for example will
Telephone number is input in dialing, address list and wechat, and in dial-up program, preview interface is the telephone number for directly displaying;
In address list, preview interface is the corresponding associated person information of the telephone number;In wechat, preview interface is the telephone number
Corresponding micro-signal information.When the search box in each application program is pasted replicates text, can also be directly initiated after stickup
Function of search, Search Results are illustrated in preview interface, user is more intuitively seen difference in different preview interfaces
Search Results, shown and subsequent operation so as to facilitate user to select the application program that is more suitable for carry out foreground.
Step S1403, preview interface is shown on foreground.
After the preview interface of the program of being applied, preview interface is included on foreground, the application program of multiple matching can
Preview graph is generated with tiling or partly overlapping mode.
Step S1404, if detect choosing operation to preview interface, the corresponding application journey of the preview interface that will be chosen
Sequence switches to foreground and is shown.
User can choose the application program operated needed for determining in preview graph by click etc., and electronic equipment is in detection
To after choosing, the application program can be switched to foreground.
Preferably, in order to reduce occupancy of the unrelated application program to resource, can be cut in the application program for needing user
After shifting to foreground, unchecked preview interface is closed, and the corresponding application program of unchecked preview interface is removed on backstage.
Further, user can be allowed by specific operation, application program is retained in backstage, it is default detecting
After operation, corresponding application program is retained on backstage.For example, the preview graph of step S1403 generations includes 4 application programs,
User makes the action slided to the left to first application program, and click determination is carried out to second application program, then can be by
First application program remains in backstage, and second application program is switched into foreground, by the 3rd and the 4th application
Program is removed from backstage.By the implementation, the convenience of paste operation can be further improved.
In a kind of preferred implementation, user can be allowed to operate multiple application programs simultaneously by way of split screen.Should
Implementation may comprise steps of:
Step 1:If choosing multiple preview interfaces, multiple screen areas are screened into, each preview interface chosen
One screen area of correspondence.
Step 2:The corresponding application program of preview interface that will respectively choose respectively is included in corresponding screen area.
By the embodiment of the present invention, the application program of matching can be called to enter with the text type of automatic identification content of text
Row is pasted, and generates preview graph for user's selection.User need to only select required application program, eliminate manual switching application
The step of program and paste text, improve the convenience of paste operation.
A kind of sticker of text is the embodiment of the invention provides, the device can be used to perform the stickup of above-mentioned text
Method, Fig. 5 is the structured flowchart of the sticker of text provided in an embodiment of the present invention, as shown in figure 5, the device includes obtaining
Module 510, parsing module 520, determining module 530 and starting module 540.
Acquisition module 510 is used to obtain the content of text for replicating.
Parsing module 520 is used to parse content of text, determines the text type of content of text.
Determining module 530 is used for the application program for determining to be matched with text type.
Starting module 540 is used to start application program, and content of text is pasted in the application, generates and show preview
Interface.
Preferably, determining module 530 includes:First reading unit, it is locally applied for reading local application list
Program listing includes multiple application programs;Second reading unit, the authority information for reading each application program respectively;Judge
Unit, for judging whether text type matches authority information;Determining unit, for it is determined that text type matching authority information
Afterwards, the corresponding application program of text type matching authority information is determined.
Preferably, determining module 530 includes:3rd reading unit, for reading default mapping table, corresponding relation
Table includes the corresponding relation of text type and application program;Search unit, for search in mapping table with text class
The corresponding application program of type.
Preferably, starting module 540 includes:Start unit, multiple applications matched with text type are started for backstage
Program;Application unit, for performing paste operation in multiple application programs, generates preview interface;Display unit, for preceding
Platform shows preview interface;Switch unit, for detect to preview interface choose operation after, the preview interface pair that will be chosen
The application program answered switches to foreground and is shown.
Preferably, starting module 540 also includes:Clearing cell, it is for closing unchecked preview interface and clear on backstage
Except the corresponding application program of unchecked preview interface.
Preferably, switch unit includes:Split screen subelement, for after multiple preview interfaces are chosen, screening into many
Individual screen area, preview interface one screen area of correspondence that each is chosen;Display subelement, for pre- by what is respectively chosen respectively
The corresponding application program in interface of looking at is displayed in corresponding screen area.
By the embodiment of the present invention, the application program of matching can be called to enter with the text type of automatic identification content of text
Row is pasted, and generates preview graph for user's selection.User need to only select required application program, eliminate manual switching application
The step of program and paste text, improve the convenience of paste operation.
Fig. 6 is the structured flowchart of the electronic equipment that another embodiment of the present invention is provided.Electronic equipment 600 shown in Fig. 6
Including:At least one processor 601, memory 602, at least one network interface 604 and other users interface 603.Electronics sets
Each component in standby 600 is coupled by bus system 605.It is understood that bus system 605 is used to realize these components
Between connection communication.Bus system 605 is also believed in addition to including data/address bus including power bus, controlling bus and state
Number bus.But for the sake of for clear explanation, various buses are all designated as bus system 605 in figure 6.
Wherein, user interface 603 can include display, keyboard or pointing device (for example, mouse, trace ball
(trackball), touch-sensitive plate or touch-screen etc..
It is appreciated that the memory 602 in the embodiment of the present invention can be volatile memory or nonvolatile memory,
Or may include both volatibility and nonvolatile memory.Wherein, nonvolatile memory can be read-only storage (Read-
Only Memory, ROM), programmable read only memory (Programmable ROM, PROM), the read-only storage of erasable programmable
Device (Erasable PROM, EPROM), Electrically Erasable Read Only Memory (Electrically EPROM, EEPROM) or
Flash memory.Volatile memory can be random access memory (Random Access Memory, RAM), and it is used as outside height
Speed caching.By exemplary but be not restricted explanation, the RAM of many forms can use, such as static RAM
(Static RAM, SRAM), dynamic random access memory (Dynamic RAM, DRAM), Synchronous Dynamic Random Access Memory
(Synchronous DRAM, SDRAM), double data speed synchronous dynamic RAM (Double Data Rate
SDRAM, DDRSDRAM), enhanced Synchronous Dynamic Random Access Memory (Enhanced SDRAM, ESDRAM), synchronized links
Dynamic random access memory (Synchlink DRAM, SLDRAM) and direct rambus random access memory (Direct
Rambus RAM, DRRAM).The memory 602 of system and method described herein be intended to including but not limited to these and it is any its
It is adapted to the memory of type.
In some embodiments, memory 602 stores following element, can perform module or data structure, or
Person their subset, or their superset:Operating system 6021 and application program 6022.
Wherein, operating system 6021, comprising various system programs, such as ccf layer, core library layer, driving layer etc. are used for
Realize various basic businesses and process hardware based task.Application program 6022, comprising various application programs, such as media
Player (Media Player), browser (Browser) etc., for realizing various applied business.Realize the embodiment of the present invention
The program of method may be embodied in application program 6022.
In embodiments of the present invention, by the program for calling memory 602 to store or instruction, specifically, can be application
The program stored in program 6022 or instruction, processor 601 are used to obtain the content of text for replicating;Parsing content of text, it is determined that
The text type of content of text;It is determined that the application program matched with text type;Start application program, content of text is pasted onto
In application program, preview interface is generated and shown.
The method that the embodiments of the present invention are disclosed can apply in processor 601, or be realized by processor 601.
Processor 601 is probably a kind of IC chip, the disposal ability with signal.In implementation process, the above method it is each
Step can be completed by the instruction of the integrated logic circuit of the hardware in processor 601 or software form.Above-mentioned treatment
Device 601 can be general processor, digital signal processor (Digital Signal Processor, DSP), special integrated electricity
Road (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field
Programmable Gate Array, FPGA) or other PLDs, discrete gate or transistor logic,
Discrete hardware components.Can realize or perform disclosed each method in the embodiment of the present invention, step and logic diagram.It is general
Processor can be microprocessor or the processor can also be any conventional processor etc..With reference to embodiment of the present invention institute
The step of disclosed method, can be embodied directly in hardware decoding processor and perform completion, or with the hardware in decoding processor
And software module combination performs completion.Software module may be located at random access memory, and flash memory, read-only storage may be programmed read-only
In the ripe storage medium in this area such as memory or electrically erasable programmable memory, register.The storage medium is located at
Memory 602, processor 601 reads the information in memory 602, with reference to the step of its hardware completion above method.
It is understood that embodiments described herein can with hardware, software, firmware, middleware, microcode or its
Combine to realize.Realized for hardware, processing unit can be realized in one or more application specific integrated circuits (Application
Specific Integrated Circuits, ASIC), digital signal processor (Digital Signal Processing,
DSP), digital signal processing appts (DSP Device, DSPD), programmable logic device (Programmable Logic
Device, PLD), field programmable gate array (Field-Programmable Gate Array, FPGA), general processor,
In controller, microcontroller, microprocessor, other electronic units for performing the application function or its combination.
Realized for software, can be by the skill that performs the module (such as process, function etc.) of this paper functions to realize this paper
Art.Software code is storable in memory and by computing device.Memory can be within a processor or outside processor
Realize in portion.
Alternatively, processor 601 determines that the operation of the application program matched with text type includes:Read locally applied journey
Sequence table, local application list includes multiple application programs;The authority information of each application program is read respectively;Judge text
Whether this type matches authority information;It is determined that after text type matching authority information, determining that text type matches authority information
Corresponding application program.
Alternatively, processor 601 determines that the operation of the application program matched with text type includes:Read default correspondence
Relation table, mapping table includes the corresponding relation of text type and application program;Search in mapping table with text
The corresponding application program of type.
Alternatively, processor 601 starts application program, and content of text is pasted in the application, generates and shows and be pre-
The operation at interface look at includes:Backstage starts multiple application programs matched with text type;Performed in multiple application programs viscous
Patch operation, generates preview interface;Preview interface is shown on foreground;If detect choosing operation to preview interface, will choose
The corresponding application program of preview interface switch to foreground and shown.
Alternatively, processor 601 switches to foreground and carries out display in the corresponding application program of preview interface that will be chosen
Afterwards, it is additionally operable to:Unchecked preview interface is closed, and the corresponding application program of unchecked preview interface is removed on backstage.
Alternatively, if processor 601 is detected chooses operation to preview interface, the preview interface that will be chosen is corresponding
Application program switches to the operation that foreground shown to be included:If choosing multiple preview interfaces, multiple screens are screened into
Region, preview interface one screen area of correspondence that each is chosen;The corresponding application program of preview interface that will respectively choose respectively
It is displayed in corresponding screen area.
Electronic equipment 600 can realize each process of electronic equipment realization in previous embodiment, to avoid repeating, here
Repeat no more.
Electronic equipment provided in an embodiment of the present invention can call answering for matching with the text type of automatic identification content of text
Pasted with program, and generated preview graph and selected for user.User need to only select required application program, eliminate manually
The step of switching application program and paste text, improve the convenience of paste operation.
It is apparent to those skilled in the art that, for convenience of description and succinctly, only with above-mentioned each work(
The division of energy unit is carried out for example, in practical application, as needed can distribute by different functions above-mentioned functions
Unit is completed, will the internal structure of device be divided into different functional unit or modules, with complete it is described above whole or
Person's partial function.Each functional unit in embodiment can be integrated in a processing unit, or unit is independent
It is physically present, it is also possible to which two or more units are integrated in a unit, above-mentioned integrated unit both can be using hard
The form of part is realized, it would however also be possible to employ the form of SFU software functional unit is realized.In addition, the specific name of each functional unit is also
For the ease of mutually differentiation, the protection domain of the application is not limited to.The specific work process of unit in said apparatus, can
With reference to the corresponding process in aforementioned means embodiment, will not be repeated here.
Those of ordinary skill in the art are it is to be appreciated that the list of each example described with reference to the embodiments described herein
Unit and algorithm steps, can be realized with the combination of electronic hardware or computer software and electronic hardware.These functions are actually
Performed with hardware or software mode, depending on the application-specific and design constraint of technical scheme.Professional and technical personnel
Described function, but this realization can be realized it is not considered that exceeding using different device to each specific application
The scope of the present invention.
In embodiment provided by the present invention, it should be understood that disclosed device and device, can be by other
Mode is realized.For example, device embodiment described above is only schematical, for example, the division of module or unit, only
It is a kind of division of logic function, there can be other dividing mode when actually realizing, such as multiple units or component can be combined
Or another system is desirably integrated into, or some features can be ignored, or do not perform.Another, shown or discussed phase
Coupling or direct-coupling or communication connection between mutually can be by some interfaces, the INDIRECT COUPLING or communication of device or unit
Connection, can be electrical, mechanical or other forms.
The unit illustrated as separating component can be or may not be physically separate, be shown as unit
Part can be or may not be physical location, you can with positioned at a place, or can also be distributed to multiple networks
On unit.Some or all of unit therein can be according to the actual needs selected to realize the purpose of this embodiment scheme.
In addition, during each functional unit in each embodiment of the invention can be integrated in a processing unit, it is also possible to
It is that unit is individually physically present, it is also possible to which two or more units are integrated in a unit.Above-mentioned integrated list
Unit can both be realized in the form of hardware, it would however also be possible to employ the form of SFU software functional unit is realized.
If integrated unit, can to realize in the form of SFU software functional unit and as independent production marketing or when using
To store in a computer read/write memory medium.Based on such understanding, the technical scheme essence of the embodiment of the present invention
On all or part of the part that is contributed to prior art in other words or the technical scheme can be with the shape of software product
Formula is embodied, and the computer software product is stored in a storage medium, including some instructions are used to so that a calculating
It is real that machine equipment (can be personal computer, server, or network equipment etc.) or processor (processor) perform the present invention
Apply all or part of step of each embodiment device of example.And foregoing storage medium includes:USB flash disk, mobile hard disk, read-only storage
Device (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disc or light
Disk etc. is various can be with the medium of store program codes.
The above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although with reference to the foregoing embodiments
The present invention has been described in detail, it will be understood by those within the art that:It still can be to foregoing each implementation
Technical scheme described in example is modified, or carries out equivalent to which part technical characteristic;And these modification or
Replace, do not make the spirit and scope of essence disengaging each embodiment technical scheme of the embodiment of the present invention of appropriate technical solution.
These are only presently preferred embodiments of the present invention, be not intended to limit the invention, it is all it is of the invention spirit and
Any modification, equivalent and improvement for being made within principle etc., should be included within the scope of the present invention.