Specific embodiment
In order to which those skilled in the art is made to more fully understand the technical solution in this specification, below in conjunction with this explanation
Attached drawing in book embodiment is clearly and completely described the technical solution in this specification embodiment, it is clear that described
Embodiment be merely a part but not all of the embodiments of the present application.Based on this specification embodiment, this field
Those of ordinary skill's all other embodiments obtained without creative efforts, should all belong to the application
The range of protection.
Fig. 1 is the schematic diagram that the picture that the scheme of this specification is related under a kind of practical application scene scales process.
Pending picture (the high definition figure e.g., obtained based on Retina display technologies is inserted into edit page (e.g., the RichText Edition page)
Piece) after, determine the size of pending picture currently shown;Further, corresponding scaling is determined according to current display size
Boundary, such as the high definition dimension of picture are 100 × 100, and the size on corresponding scaling boundary is 50 × 50;Based on for pending
The adjusting operation (e.g., drag operation and/or clicking operation) of picture, the pending picture automatic absorbing to preset scaling
Boundary.In operating process is zoomed in and out to pending picture, the scaling that operating personnel specify pending picture is not needed to
Size, the size that pending picture meeting automatic absorbing is limited to corresponding adjusting boundary, effectively improves and is adjusted in edit page
The efficiency of whole dimension of picture.
It is applied it should be noted that edit page can be browser edit page, mailbox edit page, text editing
Edit page etc. RichText Edition page;Pending picture can be the high definition picture for having higher pixel.The present embodiment skill
Art scheme can be applied to the terminal device that mobile phone, computer etc. support the RichText Edition page.
Based on above-mentioned scene, the scheme of this specification is described in detail below.
Fig. 2 is a kind of flow diagram of picture Zoom method that provides of this specification embodiment, and this method specifically can be with
Include the following steps:
Step S202:Determine to be shown in the size of the pending picture in edit page;Wherein, the pending picture is shown
Show that the size in the edit page is more than the original size of the pending picture.
In edit page, it may be necessary to text and picture into edlin, if pending in the inserting edition page
Picture is the high definition picture with higher pixel, then display size can be more than original size (for example, picture in edit page
Beyond the frame of edit page).So as to just need to be adjusted the size of the pending picture.
For example, it is assumed that pending picture is the high definition picture obtained based on Retina display technologies.And assume that this is pending
For picture when being shown in the display equipment for supporting Retina display technologies, Pixel Dimensions are for 50 × 50 (that is, the pending picture
Original size).If on certain terminal device for not supporting Retina display technologies, for the pending picture into edlin,
Such as:Insert it into edit page, then the Pixel Dimensions that the pending picture is shown in the edit page for 100 ×
100。
It should be noted that size mentioned here can be based on determined by pixel size or based on li
Size determined by rice or millimeter;In the case where resolution ratio determines, pixel and centimetre between correspondence also determine that.
Step S204:According to the size of the pending picture, setting is corresponding to the scaling boundary of the pending picture.
As shown in the above, the size that the size of pending picture refers to be shown in edit page (is not adjusted
Size), be shown in size in edit page commonly greater than original size, usual user needs to reduce in edit page to treat
Handle the size of picture.Certainly, if user wants the pending picture of the displaying being more clear, pending picture can also be based on
Size, operation further is amplified to pending picture.
Scaling boundary is determined based on the frame of pending picture or boundary line.Such as:Pending picture is 2 times of high definitions
Rectangle picture, need to narrow down to original size, then, can the vertex based on the pending picture upper left corner, by pending figure
After the long margin frame and Wide frame of piece all narrow down to the half of original length and width, obtained rectangular area, so that it may be considered that this is treated
Handle the corresponding one group of scaling boundary of picture.
Step S206:When triggering for the pending picture adjusting operation when, by the pending picture adjust to
The scaling boundary, it is adjusted after picture.
It is readily appreciated that, adjusting operation mentioned here may include:Operations, and the operation such as drag, draw, drag and/or click
Any one or a plurality of frame of pending picture can be directed to.
Due to set scaling boundary, when adjusting pending dimension of picture, can according to the active position of zoom operations,
Direction distance with reference to scaling etc. determines need which scaling boundary be automatically adjusted to.
It should be noted that the pixel that the picture after adjusting can have original size identical, it is possible to have than original
The more or fewer pixels of size.
By above-mentioned steps, in edit page, boundary is scaled for the pending picture setting with higher pixel, when
After triggering is for the zoom operations of the pending picture, which is automatically adjusted to the corresponding size in scaling boundary, energy
Enough regulated efficiencies effectively promoted to dimension of picture.
In this specification one or more embodiment, according to the size of the pending picture, setting corresponds to described
The scaling boundary of pending picture, can specifically include:According to having for the size of the pending picture and the edit page
Display area is imitated, setting is corresponding to multigroup scaling boundary of the pending picture;Alternatively, the ruler according to the pending picture
Very little original size and the effective display area domain of the edit page, setting is corresponding to one group of scaling side of the pending picture
Boundary.
It is readily appreciated that, in order to meet the different zoom demand of user, can determine to correspond to different rulers for pending picture
Very little multigroup scaling boundary.In general, one group of scaling boundary may include a plurality of boundary for forming the pending picture,
It can be at least one boundary, can also be the mark point for the position for playing instruction scaling boundary.
In general, the pixel quantity of the high definition picture obtained based on Retina display technologies, typically with size picture
2 times of pixel quantity or 3 times.The pending picture pixels shown in the equipment for supporting Retina display technologies are through overcompression
Afterwards, it is shown according to original size.However, for not supporting the equipment of Retina display technologies, in its edit page
Effective display area domain in the pending picture pixels size that shows be 2 times or 3 times of original size.Amplify to being based on n times
The pending picture that obtains of display technology when carrying out reduction operation, the size of diminution can be 1/n, the drawdown ratio based on 1/n
Example, it may be determined that corresponding scaling boundary.Also, the scaling boundary can realize the contracting to the length and width equal proportion of pending picture
It is small, the Aspect Ratio of pending picture will not be changed.
It, will when adjusting operation of the triggering for the pending picture in this specification one or more embodiment
The pending picture is adjusted to the scaling boundary, can specifically be included:When triggering is for the tune of the pending picture
During section operation, determine the active position for adjusting operation and/or adjust direction;Based on the active position and/or the tune
Direction is saved, by the pending picture automatic absorbing to the scaling boundary.
Wherein, the triggering mode of adjusting operation, can be triggered by finger, stylus or mouse.It is to adjust operation
Drag operation, for clicking or double-clicking, specifically, drag operation can pull vertex or the frame of pending picture, click
Or double click operation can be directed to the corresponding scaling boundary of pending picture and be operated.
The active position, it can be understood as adjusting acts on the position on pending picture.It is, of course, also possible to
Some position in the effective coverage of zoom function is supported by the control of finger or stylus triggering with zoom function or triggering
It puts.Direction is adjusted it is to be understood that action direction when being adjusted by finger, mouse or stylus.
It, can be by the vertex of the pending picture of mouse drag, and towards scaling for example, adjusting operation is drag operation
The direction of boundary position pulls.Behind the direction for determining to pull, user discharges the drag operation of mouse, pending picture
By automatic absorbing to scaling boundary.
In this specification one or more embodiment, if Fig. 3 is one group of scaling boundary that this specification embodiment provides
To the schematic diagram that picture zooms in and out, behind one group scaling boundary of the setting corresponding to the pending picture, based on the work
With position and/or direction is adjusted, by the pending picture automatic absorbing to the scaling boundary, can specifically be included:Base
In the active position and/or direction is adjusted, monitoring is for the adjustable range of the pending picture;When the adjustable range is big
When default automatic adjustment threshold value, by the automatic absorbing of the pending picture to the scaling boundary.
As shown in figure 3, monitoring operates corresponding adjustable range a for the adjusting of pending picture, it is assumed that preset automatic
Adjusting threshold value is b;When user carries out drag operation, also, the distance dragged is a for the lower right corner of pending picture, then,
After user drags to the position of a > b, user discharges the drag operation, and pending picture can be with automatic absorbing to preset contracting
Put boundary.
In this specification one or more embodiment, if Fig. 4 is multigroup scaling boundary that this specification embodiment provides
To the schematic diagram that picture zooms in and out, behind multigroup scaling boundary of the setting corresponding to the pending picture, based on the work
With position and/or direction is adjusted, by the pending picture automatic absorbing to the scaling boundary, can specifically be included:Base
In the active position and/or direction is adjusted, monitoring is for the adjustable range of the pending picture;According to it is described adjust away from
From, determine the pending picture boundary and it is multiple it is described scaling boundary between interval;The pending picture is inhaled automatically
It is attached to the nearest scaling boundary of spacing distance.
In practical applications, in order to meet the diversified demand of user, as shown in figure 4, RichText Edition page can be based on
Face sets multigroup scaling boundary for pending picture, for example, diminution half can be set, (first scales side in such as figure
Boundary), can also amplify 2 times (in such as figures second scaling boundaries).When during pending picture is zoomed in and out, needing to sentence
Disconnected user wants which scaling boundary zoomed to.
Judgment method, one of which embodiment can include:When monitoring user is adjusted for pending picture
The position of adjustable range and adjusting operation end point further, judges the position of current end point and each scaling side
The interval (for example, the vertical range of the position of end point to each scaling boundary) on boundary, also, make minimum scaling boundary is spaced
For target scale boundary;After determining target scale boundary, pending picture with automatic absorbing or can spring back to corresponding scaling
Boundary.
Another embodiment can include:Monitoring and the boundary line of more currently pending picture and multigroup scaling boundary
Gap size between line;Wherein, each group of scaling boundary determines each group scaling boundary respectively simultaneously comprising a plurality of boundary line
Minimum interval between boundary line and the boundary line of currently pending picture, further, then to minimum interval that each group determines
It is compared;Target scale boundary is determined according to comparison result;By pending picture automatic absorbing or spring back to corresponding contracting
Put boundary.
In edit page, the scaling boundary of pending picture of the setting with higher pixel, when triggering is waited to locate for this
After the zoom operations for managing picture, which is automatically adjusted to scaling boundary, can effectively be promoted to dimension of picture
Regulated efficiency promotes user experience.
Based on same thinking, also a kind of picture device for zooming of this specification embodiment, as shown in figure 5, the device is specific
It can include:
Measurement module 501 determines to be shown in the size of the pending picture in edit page;Wherein, the figure to be regulated
Piece is shown in the original size that size in the edit page is more than the pending picture;
Setting module 502, according to the size of the pending picture, setting is corresponding to the scaling side of the pending picture
Boundary;
When adjusting operation of the triggering for the pending picture, the pending picture is adjusted for adjustment module 503
To the scaling boundary, it is adjusted after picture.
Further, the setting module 502, according to the size of the pending picture, setting is waited to locate corresponding to described
The scaling boundary of picture is managed, can specifically be included:The setting module 502, according to the size of the pending picture with it is described
The effective display area domain of edit page, setting is corresponding to multigroup scaling boundary of the pending picture;Alternatively, the setting mould
Block 502, according to the original size of the size of the pending picture and the effective display area domain of the edit page, setting corresponds to
In one group of scaling boundary of the pending picture.
The adjustment module 503, when adjusting operation of the triggering for the pending picture, by the pending picture
It adjusts to the scaling boundary, can specifically include:When adjusting operation of the triggering for the pending picture, institute is determined
It states the active position for adjusting operation and/or adjusts direction;Based on the active position and/or the adjusting direction, treated described
Picture automatic absorbing is handled to the scaling boundary.
Further, it is treated for described in based on the active position and/or adjusting direction, the adjustment module 503, monitoring
The adjusting for handling picture operates corresponding adjustable range;It, will when the adjustable range is more than default automatic adjustment threshold value
The automatic absorbing of the pending picture is to the scaling boundary.
Further, it is treated for described in based on the active position and/or adjusting direction, the adjustment module 503, monitoring
Handle the adjustable range of picture;According to adjustable range, determine between the pending picture boundary and multiple scaling boundaries
Interval, by the pending picture automatic absorbing to the nearest scaling boundary of spacing distance.
Further, the edit page includes:The text editing page and/or the RichText Edition page.
Based on same thinking, this specification embodiment also provides a kind of electronic equipment, including:
At least one processor;And
The memory being connect at least one processor communication;Wherein,
The memory is stored with the instruction that can be performed by least one processor, and described instruction is by described at least one
A processor performs, so that at least one processor can:
Determine to be shown in the size of the pending picture in edit page;Wherein, the pending picture is shown in described
Size in edit page is more than the original size of the pending picture;
According to the size of the pending picture, setting is corresponding to the scaling boundary of the pending picture;
When adjusting operation of the triggering for the pending picture, the pending picture is adjusted to the scaling side
At boundary, it is adjusted after picture.
It is above-mentioned that this specification specific embodiment is described.Other embodiments are in the scope of the appended claims
It is interior.In some cases, the action recorded in detail in the claims or step can be come according to different from the sequence in embodiment
It performs and still can realize desired result.In addition, the process described in the accompanying drawings not necessarily require show it is specific suitable
Sequence or consecutive order could realize desired result.In some embodiments, multitasking and parallel processing be also can
With or it may be advantageous.
Each embodiment in this specification is described by the way of progressive, identical similar portion between each embodiment
Point just to refer each other, and the highlights of each of the examples are difference from other examples.Especially for device,
For electronic equipment, nonvolatile computer storage media embodiment, since it is substantially similar to embodiment of the method, so description
It is fairly simple, the relevent part can refer to the partial explaination of embodiments of method.
Device that this specification embodiment provides, electronic equipment, nonvolatile computer storage media with method are corresponding
, therefore, device, electronic equipment, nonvolatile computer storage media also there is the Advantageous similar with corresponding method to imitate
Fruit, since the advantageous effects of method being described in detail above, which is not described herein again corresponding intrument,
The advantageous effects of electronic equipment, nonvolatile computer storage media.
In the 1990s, the improvement of a technology can be distinguished clearly be on hardware improvement (for example,
Improvement to circuit structures such as diode, transistor, switches) or software on improvement (improvement for method flow).So
And with the development of technology, the improvement of current many method flows can be considered as directly improving for hardware circuit.
Designer nearly all obtains corresponding hardware circuit by the way that improved method flow is programmed into hardware circuit.Cause
This, it cannot be said that the improvement of a method flow cannot be realized with hardware entities module.For example, programmable logic device
(Programmable Logic Device, PLD) (such as field programmable gate array (Field Programmable Gate
Array, FPGA)) it is exactly such a integrated circuit, logic function determines device programming by user.By designer
Voluntarily programming a digital display circuit " integrated " on a piece of PLD, designs and make without asking chip maker
Dedicated IC chip.Moreover, nowadays, substitution manually makes IC chip, this programming is also used instead mostly " patrols
Volume compiler (logic compiler) " software realizes that software compiler used is similar when it writes with program development,
And the source code before compiling also write by handy specific programming language, this is referred to as hardware description language
(Hardware Description Language, HDL), and HDL is also not only a kind of, but there are many kind, such as ABEL
(Advanced Boolean Expression Language)、AHDL(Altera Hardware Description
Language)、Confluence、CUPL(Cornell University Programming Language)、HDCal、JHDL
(Java Hardware Description Language)、Lava、Lola、MyHDL、PALASM、RHDL(Ruby
Hardware Description Language) etc., VHDL (Very-High-Speed are most generally used at present
Integrated Circuit Hardware Description Language) and Verilog.Those skilled in the art also should
This understands, it is only necessary to method flow slightly programming in logic and is programmed into integrated circuit with above-mentioned several hardware description languages,
The hardware circuit for realizing the logical method flow can be readily available.
Controller can be implemented in any suitable manner, for example, controller can take such as microprocessor or processing
The computer of computer readable program code (such as software or firmware) that device and storage can be performed by (micro-) processor can
Read medium, logic gate, switch, application-specific integrated circuit (Application Specific Integrated Circuit,
ASIC), the form of programmable logic controller (PLC) and embedded microcontroller, the example of controller include but not limited to following microcontroller
Device:ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20 and Silicone Labs C8051F320, are deposited
Memory controller is also implemented as a part for the control logic of memory.It is also known in the art that in addition to
Pure computer readable program code mode is realized other than controller, can be made completely by the way that method and step is carried out programming in logic
Controller is obtained in the form of logic gate, switch, application-specific integrated circuit, programmable logic controller (PLC) and embedded microcontroller etc. to come in fact
Existing identical function.Therefore this controller is considered a kind of hardware component, and various to being used to implement for including in it
The device of function can also be considered as the structure in hardware component.Or even, the device for being used to implement various functions can be regarded
For either the software module of implementation method can be the structure in hardware component again.
System, device, module or the unit that above-described embodiment illustrates can specifically realize by computer chip or entity,
Or it is realized by having the function of certain product.A kind of typical realization equipment is computer.Specifically, computer for example may be used
Think personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media play
It is any in device, navigation equipment, electronic mail equipment, game console, tablet computer, wearable device or these equipment
The combination of equipment.
For convenience of description, it is divided into various units during description apparatus above with function to describe respectively.Certainly, implementing this
The function of each unit is realized can in the same or multiple software and or hardware during specification one or more embodiment.
It should be understood by those skilled in the art that, this specification embodiment can be provided as method, system or computer program
Product.Therefore, this specification embodiment can be used complete hardware embodiment, complete software embodiment or with reference to software and hardware
The form of the embodiment of aspect.Wherein include computer in one or more moreover, this specification embodiment can be used and can be used
It is real in the computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) of program code
The form for the computer program product applied.
This specification is with reference to the method, equipment (system) and computer program product according to this specification embodiment
Flowchart and/or the block diagram describes.It should be understood that it can be realized by computer program instructions every in flowchart and/or the block diagram
The combination of flow and/or box in one flow and/or box and flowchart and/or the block diagram.These computers can be provided
Program instruction is to the processor of all-purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices
To generate a machine so that the instruction performed by computer or the processor of other programmable data processing devices generates use
In the dress of function that realization is specified in one flow of flow chart or multiple flows and/or one box of block diagram or multiple boxes
It puts.
These computer program instructions, which may also be stored in, can guide computer or other programmable data processing devices with spy
Determine in the computer-readable memory that mode works so that the instruction generation being stored in the computer-readable memory includes referring to
Enable the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one box of block diagram or
The function of being specified in multiple boxes.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that counted
Series of operation steps are performed on calculation machine or other programmable devices to generate computer implemented processing, so as in computer or
The instruction offer performed on other programmable devices is used to implement in one flow of flow chart or multiple flows and/or block diagram one
The step of function of being specified in a box or multiple boxes.
In a typical configuration, computing device includes one or more processors (CPU), input/output interface, net
Network interface and memory.
Memory may include computer-readable medium in volatile memory, random access memory (RAM) and/or
The forms such as Nonvolatile memory, such as read-only memory (ROM) or flash memory (flash RAM).Memory is computer-readable medium
Example.
Computer-readable medium includes permanent and non-permanent, removable and non-removable media can be by any method
Or technology come realize information store.Information can be computer-readable instruction, data structure, the module of program or other data.
The example of the storage medium of computer includes, but are not limited to phase transition internal memory (PRAM), static RAM (SRAM), moves
State random access memory (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electric erasable
Programmable read only memory (EEPROM), fast flash memory bank or other memory techniques, CD-ROM read-only memory (CD-ROM),
Digital versatile disc (DVD) or other optical storages, magnetic tape cassette, the storage of tape magnetic rigid disk or other magnetic storage apparatus
Or any other non-transmission medium, available for storing the information that can be accessed by a computing device.It defines, calculates according to herein
Machine readable medium does not include temporary computer readable media (transitory media), such as data-signal and carrier wave of modulation.
It should also be noted that, term " comprising ", "comprising" or its any other variant are intended to nonexcludability
Comprising so that process, method, commodity or equipment including a series of elements are not only including those elements, but also wrap
Include other elements that are not explicitly listed or further include for this process, method, commodity or equipment it is intrinsic will
Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that wanted including described
Also there are other identical elements in the process of element, method, commodity or equipment.
This specification can be described in the general context of computer executable instructions, such as journey
Sequence module.Usually, program module include routines performing specific tasks or implementing specific abstract data types, program, object,
Component, data structure etc..Specification can also be put into practice in a distributed computing environment, in these distributed computing environment,
By performing task by communication network and connected remote processing devices.In a distributed computing environment, program module can
To be located in the local and remote computer storage media including storage device.
Each embodiment in this specification is described by the way of progressive, identical similar portion between each embodiment
Point just to refer each other, and the highlights of each of the examples are difference from other examples.Especially for system reality
For applying example, since it is substantially similar to embodiment of the method, so description is fairly simple, related part is referring to embodiment of the method
Part explanation.
The foregoing is merely this specification embodiments, are not limited to the application.For those skilled in the art
For, the application can have various modifications and variations.All any modifications made within spirit herein and principle are equal
Replace, improve etc., it should be included within the scope of claims hereof.