CN109857388A - Code generating method, device, server and computer-readable medium - Google Patents

Code generating method, device, server and computer-readable medium Download PDF

Info

Publication number
CN109857388A
CN109857388A CN201910024809.0A CN201910024809A CN109857388A CN 109857388 A CN109857388 A CN 109857388A CN 201910024809 A CN201910024809 A CN 201910024809A CN 109857388 A CN109857388 A CN 109857388A
Authority
CN
China
Prior art keywords
picture
information
source file
mentioned
attribute information
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.)
Granted
Application number
CN201910024809.0A
Other languages
Chinese (zh)
Other versions
CN109857388B (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.)
Beijing Urban Network Neighbor Information Technology Co Ltd
Beijing City Network Neighbor Technology Co Ltd
Original Assignee
Beijing City Network Neighbor Technology 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 Beijing City Network Neighbor Technology Co Ltd filed Critical Beijing City Network Neighbor Technology Co Ltd
Priority to CN201910024809.0A priority Critical patent/CN109857388B/en
Publication of CN109857388A publication Critical patent/CN109857388A/en
Application granted granted Critical
Publication of CN109857388B publication Critical patent/CN109857388B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Processing Or Creating Images (AREA)

Abstract

The embodiment of the present application discloses code generating method, device, server and computer-readable medium.The embodiment of this method includes: to obtain picture source file to be processed;Extract the attribute information of each element and each element in the picture source file;The attribute information is parsed, the positional relationship information of each element is generated;Based on the positional relationship information, each element is laid out;Based on layout result and the attribute information, the program code for also original picture is generated.This embodiment improves the development efficiency of webpage.

Description

Code generating method, device, server and computer-readable medium
Technical field
The invention relates to field of computer technology, and in particular to code generating method, device, server and calculating Machine readable medium.
Background technique
User interface (User Interface, UI) can be generally considered as being the human-computer interaction to software or webpage, operation The whole design of logic, beautiful interface.Outstanding user interface not only can allow software or webpage to become have individual character to have grade, also Can allow the operation of software or webpage it is more comfortable, it is simple, naturally, fully demonstrating positioning and feature of software or webpage etc. in turn Deng.
In the development process of software or webpage, it is often necessary to be first designed by visual designer to user interface, shape It is completed according to user-interface design original text from user-interface design original text at picture source file (i.e. UI designs original text), then by front end engineer To the reduction work of code.It is particularly important to the parsing work of user-interface design original text in the reduction work, it generally requires to consume The a few hours even days of time, low efficiency, and it is higher to the skill requirement of front end engineer.
Summary of the invention
The embodiment of the present application proposes code generating method, device, server and computer-readable medium, existing to solve It is low to the parsing working efficiency of picture source file in technology, and to the higher problem of the skill requirement of front end engineer.
In a first aspect, the embodiment of the present application provides a kind of code generating method, it is applied to server, this method comprises: Obtain picture source file to be processed;Extract the attribute information of each element and each element in picture source file;To attribute information It is parsed, generates the positional relationship information between element;Based on positional relationship information, each element is laid out;Based on layout As a result and attribute information, generation are used for the program code of also original picture.
In some embodiments, attribute information further includes element position information and element size information;And attribute is believed Breath is parsed, and the positional relationship information between element is generated, comprising: is based on element position information and element size information, is generated The corresponding box model information of each element;Based on box model information, element position information and element size information, element is generated Between positional relationship information, wherein positional relationship information includes the distance between the corresponding box model of element.
In some embodiments, it is based on positional relationship information, determines the columns of every row element to be laid out, comprising: be based on Positional relationship information determines every row element to be laid out with the presence or absence of coincidence relation, wherein coincidence relation includes all being overlapped to close System and local coincidence relation;The element of coincidence relation will be present as a column, there is no the elements of coincidence relation to make by each For a column, the columns of every row element to be laid out is counted, is laid out according to element of the identified columns to every row.
In some embodiments, attribute information includes element covering sequence;And it is being based on positional relationship information, to each member After element is laid out, method further include: according to element covering sequence, the layout result of each element is adjusted.
In some embodiments, the attribute information of each element and each element in picture source file is extracted, comprising: to picture Source file is pre-processed, wherein pretreatment include at least one of the following: each element in picture source file is checked, Each element in picture source file is stored;Each element is extracted, and extracts the attribute letter of each element from picture source file Breath.
In some embodiments, pretreatment further includes the corresponding picture to be restored of storage picture source file;And it is generating After the also program code of original picture, this method further include: program code of the operation for also original picture, after generating reduction Picture;Picture after reduction and picture to be restored are compared, determine the reduction degree of picture after reduction;Based on reduction degree and preset The comparison of numerical value determines whether the program code for also original picture is qualified.
In some embodiments, after generating reduction after picture, this method further include: determine after reduction picture with to also The pixel value difference of original picture.
In some embodiments, picture source file to be processed is obtained, comprising: send in response to receiving storage server Parsing task message, picture source file to be processed is obtained from storage server;And it is being based on layout result and attribute Information, after generating the program code for going back original picture, this method further include: the program code that will be used for also original picture is sent To storage server.
In some embodiments, this method further include: carried out according to treatment process of the default dimension to picture source file real When monitor, wherein default dimension includes at least one of the following: abnormality, reduction success rate, time-consuming information.
Second aspect, the embodiment of the present application provide a kind of code generating unit, are applied to server, which includes: Acquiring unit is configured to obtain picture source file to be processed;Extraction unit is configured to extract each in picture source file The attribute information of element and each element;Resolution unit is configured to parse attribute information, and the position generated between element is closed It is information;Layout units are configured to be laid out each element based on positional relationship information;Code generating unit is configured At layout result and attribute information is based on, the program code for also original picture is generated.
In some embodiments, attribute information further includes element position information and element size information;And resolution unit, Include: the first generation module, is configured to generate the corresponding box of each element based on element position information and element size information Model information;Second generation module is configured to based on box model information, element position information and element size information, raw At the positional relationship information between element, wherein positional relationship information includes the distance between the corresponding box model of element.
In some embodiments, layout modules, comprising: the first determining module is configured to based on positional relationship information, really Fixed every row element to be laid out whether there is coincidence relation, wherein coincidence relation includes that whole coincidence relations and part superposition close System;Second determining module is configured to will be present the element of coincidence relation as a column, and by each, there is no coincidence relations Element counts the columns of every row element to be laid out, is laid out according to element of the identified columns to every row as a column.
In some embodiments, attribute information includes element covering sequence;And device further include: adjustment unit, quilt It is configured to be adjusted the layout result of each element according to element covering sequence.
In some embodiments, extraction unit is further configured to: being pre-processed to picture source file, wherein pre- Processing include at least one of the following: each element in picture source file is checked, to each element in picture source file into Row storage;Each element is extracted, and extracts the attribute information of each element from picture source file.
In some embodiments, pretreatment further includes the corresponding picture to be restored of storage picture source file;And the device Further include: running unit is configured to run the program code for also original picture, generates picture after reduction;First determines list Member, picture is compared with picture to be restored after being configured to restore, and determines the reduction degree of picture after reduction;Second determines list Member is configured to based on reduction degree compared with default value, determines whether the program code for also original picture is qualified.
In some embodiments, the device further include: third determination unit, be configured to determine reduction after picture with to also The pixel value difference of original picture.
In some embodiments, acquiring unit is further configured to: the solution in response to receiving storage server transmission Task message is analysed, picture source file to be processed is obtained from storage server;And device further include: storage unit, quilt It is configured to the program code for being used for also original picture being sent to storage server.
In some embodiments, device further include: monitoring unit is configured to according to default dimension to picture source file Treatment process monitored in real time, wherein default dimension include at least one of the following: abnormality, reduction success rate, time-consuming Information.
The third aspect, the embodiment of the present application provide a kind of server, comprising: one or more processors;Storage device, One or more programs are stored thereon with, when one or more programs are executed by one or more processors, so that one or more A processor realizes the method such as any embodiment in above-mentioned first aspect.
Fourth aspect, the embodiment of the present application provide a kind of computer-readable medium, are stored thereon with computer program, should The method such as any embodiment in above-mentioned first aspect is realized when program is executed by processor.
Code generating method and device provided by the embodiments of the present application, after getting picture source file to be processed, The attribute information of each element and each element in picture source file can be extracted;Then, attribute information can be parsed, it is raw Each element is laid out to be based on positional relationship information at the positional relationship information between element;Finally, based on layout knot Fruit and attribute information generate the program code for also original picture.It is thus possible to without being accomplished manually the solution to picture source file Analyse work, the skill requirement for reducing the workload of front end engineer, reducing front end engineer;Meanwhile improving picture source The resolution speed of file improves webpage development efficiency.
Detailed description of the invention
By reading a detailed description of non-restrictive embodiments in the light of the attached drawings below, the application's is other Feature, objects and advantages will become more apparent upon:
Fig. 1 is the flow chart according to one embodiment of the code generating method of the application;
Fig. 2 is the flow chart according to another embodiment of the code generating method of the application;
Fig. 3 is the interaction schematic diagram executed between the server and storage server of code generating method in the application;
Fig. 4 is the structural schematic diagram according to one embodiment of the code generating unit of the application;
Fig. 5 is adapted for the structural schematic diagram for the computer system for realizing the server of the embodiment of the present application.
Specific embodiment
The application is described in further detail with reference to the accompanying drawings and examples.It is understood that this place is retouched The specific embodiment stated is used only for explaining related invention, rather than the restriction to the invention.It also should be noted that in order to Convenient for description, part relevant to related invention is illustrated only in attached drawing.
It should be noted that in the absence of conflict, the features in the embodiments and the embodiments of the present application can phase Mutually combination.The application is described in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
Referring to FIG. 1, it illustrates the processes 100 according to one embodiment of the code generating method of the application.The generation Code generating method can be applied to server, comprising the following steps:
Step 101, picture source file to be processed is obtained.
In the present embodiment, the available picture source to be processed of the executing subject (such as server) of code generating method File.Wherein, above-mentioned picture source file can be the user-interface design original text for user interface, can also be with advertisement design original text Deng, the present invention to the application scenarios of picture without limitation.As an example, above-mentioned picture source file can be a kind of Sketch (arrow Measure design tool) source file or PhotoShop source file etc..
In practice, multiple element may include in picture source file.For example, slice, figure layer, polar plot, text etc..This Place, is not specifically limited the type of picture source file, version, content, capacity etc..
In the present embodiment, the element in above-mentioned picture source file to be processed may include at least one of following: figure layer, Polar plot, slice, text.
In some optional implementations of the present embodiment, above-mentioned executing subject can be with storage server communication link It connects.Wherein, above-mentioned storage server can be used for storing one or more picture source files of current pending processing, can also be with For storing the above-mentioned executing subject program code that treated for also original picture.It is sent in response to receiving storage server Parsing task message, above-mentioned executing subject can obtain picture source file to be processed from above-mentioned storage server.
Step 102, the attribute information of each element and each element in picture source file is extracted.
In the present embodiment, above-mentioned executing subject can extract each element and above-mentioned each element in above-mentioned picture source file Attribute information.It should be noted that above-mentioned attribute information can include but is not limited to: element position information, element size letter Breath, index information, style information, text information etc..The type to the attribute information of each element and content etc. are not made specifically herein Limitation.
Herein, for different types of picture source file, element and attribute information can be carried out in different ways It extracts.As an example, if picture source file is Sketch source file, the script write in advance and existing the can be passed through Tripartite's tool (such as SketchTools), according to the information in the document specification of Sketch source file, to for Sketch source file In each element and the attribute information of each element extract.
In some optional implementations of the present embodiment, wherein above-mentioned attribute information may include that element covering is suitable Sequence.Arrangement of each element successively from the bottom to top layer that above-mentioned element covering sequence can be in above-mentioned picture source file is suitable Sequence.For example, including two pictorial elements in picture to be restored.The portion of a part the first pictorial element of covering of second pictorial element Subregion.Then element covering sequence can be followed successively by the first pictorial element, the second pictorial element.
In above-mentioned implementation, above-mentioned executing subject can extract above-mentioned each element and above-mentioned attribute as follows Information: the first step can pre-process above-mentioned picture source file.Wherein, above-mentioned pretreatment includes at least one of the following: pair Each element in above-mentioned picture source file is checked, is stored to each element in above-mentioned picture source file.As an example, It can be by the script write in advance according to the attribute information of each element in the document specification of Sketch source file, to each element In slice element, figure layer element, polar plot element etc. carry out inspection operation;Third party's tool (such as Sketch can be passed through Tools) in each element slice element and polar plot element carry out storage operation.In addition, above-mentioned pretreatment can also include Edition upgrading operation to Sketch source file, it is also possible to which Sketch source file is exported as picture to be restored in case of after It is continuous to use, and slice element and polar plot element are exported as into picture in case the use when being subsequently generated program code.It needs Bright, the figure layer element in picture source file can not be changed in pretreatment operation.Second step extracts above-mentioned each member Element, and extract from above-mentioned picture source file the attribute information of above-mentioned each element.
Step 103, attribute information is parsed, generates the positional relationship information between element.
In the present embodiment, due to may include the information such as element position information, element size information in attribute information, because This, above-mentioned executing subject can be according to attribute information, positional relationship between calculating elements, to generate positional relationship information.Herein, Positional relationship information can serve to indicate that the relative position between element.For example, positional relationship information may include the phase between element It adjusts the distance.
As an example, can be using the top left co-ordinate of terminal interface point as coordinate origin.It will be apart from above-mentioned coordinate origin Nearest element is as the first element, using the element closed on above-mentioned first element as second element.Then, can be determined The relative distance of Was Used and the first element.Above-mentioned distance may include lateral distance and fore-and-aft distance.Above-mentioned distance can be used Coordinate difference characterizes.And so on, it can determine the distance between each adjacent element.So that it is determined that the position of element is closed out System.It should be noted that coordinate origin herein is not specifically limited, can according to need to set.
Step 104, it is based on positional relationship information, each element is laid out.
In the present embodiment, above-mentioned executing subject can be based on above-mentioned positional relationship information, carry out cloth to above-mentioned each element Office.For example, a Column Layout, two Column Layouts, multiple row layout etc. can be carried out.
Specifically, due to that can determine the relative position between element by above-mentioned positional relationship information.Therefore, this is utilized Positional relationship information can determine every row element to be laid out with the presence or absence of coincidence relation.Above-mentioned coincidence relation may include All overlapping, part overlapping etc..Later, the element that coincidence relation can will be present in above-mentioned executing subject is arranged as one, will be each It is a there is no the element of coincidence relation as it is independent one column, count the columns of every row element to be laid out.Finally, according to above-mentioned column It is several that above-mentioned each element is laid out.
As an example, element ui1, ui2, ui3, ui4, ui5 for including in picture source file.Element ui1 and ui2 are located at vertical Coordinate is the row of y1, i.e., includes two elements of ui1 and ui2 in the row of ordinate y1.It is y2 that element ui3 and ui4, which are located at ordinate, Row, i.e., comprising using tri- elements of ui3, ui4, ui5 in the row of ordinate y2.Herein, if being based on positional relationship information, major elements Ui1, ui2 be not present overlapping relation, then for ordinate be y1 row, two column arrangements can be carried out, be respectively arranged element ui1 and Element ui2.In addition, there are coincidence relations by major elements ui3, ui4, and element ui5 and each element are not if being based on positional relationship information Overlapping, then can be using element ui3, ui4 as a column, and using element ui5 as an individual column, the row for being y2 to ordinate is carried out Two column arrangements.Wherein column arrangement element ui3, a ui4, another column arrange element ui5.
It, can also be according to above-mentioned element after obtaining layout result in some optional implementations of the present embodiment Covering sequence, the layout result of above-mentioned each element are adjusted.It is thus possible to make in the coverage condition and picture to be restored of element Element coverage condition match.Herein, it when carrying out arrangement operation to element, can be arranged according to preset rendering order Column operation.In general, preset rendering order can be from top left to bottom right, not limit specifically rendering order herein System.
Step 105, it is based on layout result and attribute information, generates the program code for also original picture.
In the present embodiment, above-mentioned executing subject can be generated according to layout result and above-mentioned attribute information for restoring The program code of picture.Wherein, layout result may include that the element position information, element size information, position of each element are closed It is the information such as the order of information, place figure layer.Above-mentioned attribute information may include element size information, index information, pattern letter Breath, text information, colouring information etc..
Here, the program code for also original picture can present picture after reduction after operation.It is above-mentioned to be used to restore The program code of picture can be the code of appointed language.As an example, the program code for also original picture can be HTML (HyperText Markup Language, HyperText Markup Language) code.In practice, element can be converted into HTML Label in code.For example, label is if element is image<img>.Later, attribute of an element information can be converted to Property Name and attribute value are added in the corresponding label of the element.The program code for also original picture is generated as a result,.
It should be noted that above-mentioned executing subject can only automatically generate code related with also original picture, remaining function Or the code of event can be based on the method manual compiling of the prior art.
In some optional implementations of the present embodiment, after generating for the also program code of original picture, on Stating executing subject can also be performed following steps:
Firstly, the above-mentioned program code for also original picture of operation, to generate picture after reduction.
Later, picture after above-mentioned reduction and above-mentioned picture to be restored can be compared, determines picture after above-mentioned reduction Reduction degree.In practice, above-mentioned reduction degree can be used for characterizing the similarity degree of picture and above-mentioned picture to be restored after reduction.This Place, above-mentioned reduction degree can be adopted and be determined in various manners.As an example, can the pixel value to two picture same positions carry out The ratio of the quantity of the position to match and picture pixels point total quantity is determined as reduction degree by matching.It should be noted that also The method of determination of former degree is not limited to above-mentioned example, can also be determined according to other preset rules, be not construed as limiting herein.
Finally, determining that the above-mentioned program code for also original picture is based on above-mentioned reduction degree compared with default value No qualification.Herein, if above-mentioned reduction degree is not less than above-mentioned default value, the above-mentioned program code for also original picture can be determined It is qualified.Conversely, can then determine unqualified.In practice, determine it is unqualified after, above-mentioned executing subject can also be generated and be returned Warning message.
In some optional implementations of the present embodiment, the program code for also original picture is operationally stated, it is raw After picture after reduction, above-mentioned executing subject can also determine the pixel difference of picture and above-mentioned picture to be restored after above-mentioned reduction Value.Herein, it can be RGB difference.In practice, the object that pixel value difference can be supported to calculate for carrying browser can be used (such as Canvas object) Lai Jinhang difference calculates.Also calculus of differences mode can be directly used, generate picture after above-mentioned reduction With the difference image of above-mentioned picture to be restored.To obtain the pixel value difference of each pixel.
In some optional implementations of the present embodiment, after generating for the also program code of original picture, on Storage server can also be sent to for the above-mentioned program code for being used for also original picture by stating executing subject, so that user transfers and looks into It sees.Here, the program that storage server can be used for storing picture source file to be processed and treated for also original picture Code.
In some optional implementations of the present embodiment, treatment process of the above-mentioned executing subject to picture source file In, the processing to picture source file can also be monitored in real time according to default dimension.Wherein, above-mentioned default dimension can wrap It includes at least one of following: abnormality, reduction success rate, time-consuming information.As an example, abnormality may include that can not generate It is taken long time for the also program code of original picture, for the program code generation of also original picture.Reduction success rate can be Generate the ratio for the also total amount of the number of the program code of original picture and acquired picture source file to be processed.It is time-consuming Information can be from picture source file is got to the total duration generated for the also program code of original picture.
The method provided by the above embodiment of the application can be extracted after getting picture source file to be processed The attribute information of each element and above-mentioned each element in above-mentioned picture source file;Then, above-mentioned attribute information can be solved Analysis, generates the positional relationship information between above-mentioned element, to be based on above-mentioned positional relationship information, carries out cloth to above-mentioned each element Office;Finally, being based on layout result and above-mentioned attribute information, the program code for also original picture is generated.It is thus possible to be not necessarily to people Work completes the parsing work to picture source file, the technical ability for reducing the workload of front end engineer, reducing front end engineer It is required that;Meanwhile the resolution speed of picture source file is improved, improve webpage development efficiency.
With further reference to Fig. 2, it illustrates the processes 200 of another embodiment of code generating method.The code building The process 200 of method.The following steps are included:
Step 201, picture source file to be processed is obtained.
In the present embodiment, the executing subject (such as server) of code generating method can be with storage server communication link It connects.Wherein, above-mentioned storage server can be used for storing one or more picture source files of current pending processing, can also be with For storing the above-mentioned executing subject program code that treated for also original picture.It is sent in response to receiving storage server Parsing task message, above-mentioned executing subject can obtain picture source file to be processed from above-mentioned storage server.
Herein, the element in above-mentioned picture source file to be processed may include at least one of following: figure layer, polar plot, Slice, text.
Step 202, the attribute information of each element and each element in picture source file is extracted.
In the present embodiment, above-mentioned executing subject can extract above-mentioned each element and above-mentioned attribute letter as follows Breath:
The first step can pre-process above-mentioned picture source file.Wherein, above-mentioned pretreatment includes following at least one : each element in above-mentioned picture source file is checked, each element in above-mentioned picture source file is stored.As Example, can be right by the script write in advance according to the attribute information of each element in the document specification of Sketch source file Slice element, figure layer element, polar plot element in each element etc. carry out inspection operation;It can be by third party's tool (such as Sketch Tools) in each element slice element and polar plot element carry out storage operation.In addition, above-mentioned pretreatment may be used also To be operated comprising the edition upgrading to Sketch source file, it is also possible to which Sketch source file is exported as picture to be restored In case subsequent use, and slice element and polar plot element are exported as into picture in case the use when being subsequently generated program code. It should be noted that the figure layer element in picture source file can not be changed in pretreatment operation.
Second step extracts above-mentioned each element, and the attribute information of above-mentioned each element is extracted from above-mentioned picture source file.
It should be noted that above-mentioned attribute information may include element covering sequence.Further, it is also possible to include other letters Breath.For example, can include but is not limited to: element position information, element size information, index information, style information, text information Deng.The type to the attribute information of each element and content etc. are not specifically limited herein.
Step 203, based on the element position information and element size information in attribute information, the corresponding box of each element is generated Submodel information.
In the present embodiment, above-mentioned executing subject can extract element position information and member from the attribute information of each element Plain dimension information.Herein, element position information may include the coordinate of element.Element size information may include element width and It is high.Then, it can be based on extracted element position information and element size information, generate the corresponding box model letter of each element Breath.
In practice, box model is commonly used CSS (Cascading Style Sheets, layer in webpage design Stacking style table) a kind of thinking model used in technology.Box model is also known as frame model (Box Model), and it comprises elements Content (content), inset spacing (padding), frame (border), outer back gauge (margin) several elements.
In known picture source file in the case where the element position information and element size information of each element, above-mentioned execution Main body can determine the information such as inset spacing, frame, outer back gauge in the corresponding box model of each element, to generate box mould Type information.Herein, box model information can be the code for being used to indicate box model.It may include box model in the code In each element value.
Step 204, it is based on box model information, element position information and element size information, generates the position between element Relation information.
In the present embodiment, due to may include the information such as value, the value of outer rim of interior frame in box model information, In the case where the element size information of known element, the size of the corresponding box model of each element can be determined.Known each In the case where the element position information of element, the positional relationship of the corresponding box model of each element can be determined.Based on each member The size of the corresponding box model of element and position, that is, can determine the information such as the distance between the corresponding box model of element.Herein, position Set the information such as the distance between the box model that relation information can be determined.
Step 205, it is based on positional relationship information, determines every row element to be laid out with the presence or absence of coincidence relation.
In the present embodiment, due to that can determine the relative position between element by above-mentioned positional relationship information.Therefore, Using the positional relationship information, every row element to be laid out can be determined with the presence or absence of coincidence relation.Above-mentioned coincidence relation can To include whole coincidence relations and local coincidence relation.
Step 206, the element of coincidence relation will be present as a column, using each there is no the element of coincidence relation as One column, count the columns of every row element to be laid out, are laid out according to element of the identified columns to every row.
In the present embodiment, the element that coincidence relation can will be present in above-mentioned executing subject is arranged as one, not by each There are the elements of coincidence relation as an independent column, counts the columns of every row element to be laid out.Finally, according to above-mentioned columns pair Above-mentioned each element is laid out.
As an example, element ui1, ui2, ui3, ui4, ui5 for including in picture source file.Element ui1 and ui2 are located at vertical Coordinate is the row of y1, i.e., includes two elements of ui1 and ui2 in the row of ordinate y1.It is y2 that element ui3 and ui4, which are located at ordinate, Row, i.e., comprising using tri- elements of ui3, ui4, ui5 in the row of ordinate y2.Herein, if being based on positional relationship information, major elements Ui1, ui2 be not present coincidence relation, then for ordinate be y1 row, two column arrangements can be carried out, be respectively arranged element ui1 and Element ui2.In addition, there are coincidence relations by major elements ui3, ui4, and element ui5 and each element are not if being based on positional relationship information Overlapping, then can be using element ui3, ui4 as a column, and using element ui5 as an individual column, the row for being y2 to ordinate is carried out Two column arrangements.Wherein column arrangement element ui3, a ui4, another column arrange element ui5.
Step 207, according to element covering sequence, the layout result of each element is adjusted.
In the present embodiment, above-mentioned executing subject can carry out the layout result of each element according to element covering sequence Adjustment.It is thus possible to which the coverage condition of element is made to match with the element coverage condition in picture to be restored.
Herein, when carrying out arrangement operation to element, arrangement operation can be carried out according to preset rendering order.In general, Preset rendering order can be from top left to bottom right, to be not specifically limited herein to rendering order.
Step 208, it is based on layout result and attribute information, generates the program code for also original picture.
It in the present embodiment, can be according to layout result adjusted and above-mentioned after being adjusted to layout result Attribute information generates the program code for also original picture.Wherein, layout result adjusted may include the element of each element The information such as order of location information, element size information, positional relationship information, place figure layer.Above-mentioned attribute information may include Element size information, index information, style information, text information, colouring information etc..
Step 209, the program code for being used for also original picture is sent to storage server.
In the present embodiment, after generating for the also program code of original picture, above-mentioned executing subject can also will be upper It states and is sent to storage server for the program code of also original picture, so that user transfers and checks.Here, storage server can Picture source file to be processed and the program code that treated for also original picture for storage.
From figure 2 it can be seen that compared with the corresponding embodiment of Fig. 1, the process of the code generating method in the present embodiment 200 relate to the step of generating box model information, generating the positional relationship information between element using box model information.By This, may not need the parsing work being accomplished manually to picture source file, reduces the workload of front end engineer, reduces front end The skill requirement of engineer;Meanwhile the resolution speed of picture source file is improved, improve webpage development efficiency.In addition, also relating to And the step that is interacted with storage server.As a result, in the development process of software or webpage, visual designer and front end engineering Teacher can improve on the whole the development efficiency of software or webpage with concurrent job.
It with continued reference to Fig. 3, Fig. 3 is executed according to the present embodiment between the server and storage server of code generating method Interaction schematic diagram.Here, the server for executing code generating method is properly termed as resolution server.
As shown in figure 3, Vision Design engineer can upload the picture source file of design completion into storage server.It deposits Server is stored up after receiving picture source file, has sent parsing task message to resolution server first.Herein, task is parsed Message can be used for that resolution server is notified to carry out pulling for picture source file.
Later, resolution server can obtain picture source file from storage server, and carry out to the picture source file The processing such as pretreatment, parsing.Finally, the program code for also original picture is generated.
Finally, the above-mentioned program code for being used for also original picture can be sent to above-mentioned storage service by above-mentioned resolution server In the specified directory of device, above-mentioned storage server can store the above-mentioned program code for also original picture.At this point, preceding End engineer can just download and using the above-mentioned program code for also original picture.
As a result, in the development process of software or webpage, visual designer and front end engineer can be with concurrent jobs, from whole The development efficiency of software or webpage is improved on body.
With further reference to Fig. 4, as the realization to method shown in above-mentioned each figure, this application provides a kind of code building dresses The one embodiment set, the Installation practice is corresponding with embodiment of the method shown in FIG. 1, which specifically can be applied to take It is engaged in device.
As shown in figure 4, code generating unit 400 described in the present embodiment includes: acquiring unit 401, it is configured to obtain Picture source file to be processed;Extraction unit 402, each element for being configured to extract in above-mentioned picture source file and above-mentioned each member The attribute information of element, wherein the element in above-mentioned picture source file includes figure layer and at least one of following: polar plot, slice, text This, above-mentioned attribute information includes element covering sequence;Resolution unit 403 is configured to parse above-mentioned attribute information, raw At the positional relationship information between element;Layout units 404 are configured to based on above-mentioned positional relationship information, to above-mentioned each element It is laid out;Code generating unit 406 is configured to generate based on layout result and above-mentioned attribute information for also original picture Program code.
In some optional implementations of the present embodiment, above-mentioned attribute information may include element position information and member Plain dimension information.Above-mentioned resolution unit 403 may include the first generation module and the second generation module (not shown).Its In, above-mentioned first generation module is configured to above-mentioned element position information and above-mentioned element size information, in generation State the corresponding box model information of each element.Above-mentioned second generation module be configured to above-mentioned box model information, Above-mentioned element position information and element size information generate the positional relationship information between element, wherein above-mentioned positional relationship information Including the distance between the corresponding box model of element.
In some embodiments, above-mentioned layout modules may include: the first determining module, be configured to based on above-mentioned position Relation information determines every row element to be laid out with the presence or absence of coincidence relation, wherein above-mentioned coincidence relation includes all being overlapped to close System and local coincidence relation;Second determining module is configured to will be present the element of coincidence relation as a column, not by each There are the elements of coincidence relation as a column, the columns of every row element to be laid out is counted, according to identified columns to every row Element be laid out.
In some embodiments, above-mentioned attribute information includes element covering sequence;And the device can also include adjustment Unit (not shown).Wherein, above-mentioned adjustment unit may be configured to according to above-mentioned element covering sequence, to above-mentioned each member The layout result of element is adjusted.
In some optional implementations of the present embodiment, said extracted unit 402 can be further configured to: right Above-mentioned picture source file is pre-processed, wherein above-mentioned pretreatment is included at least one of the following: in above-mentioned picture source file Each element is checked, is stored to each element in above-mentioned picture source file;Extract above-mentioned each element, and from above-mentioned picture The attribute information of above-mentioned each element is extracted in source file.
In some optional implementations of the present embodiment, above-mentioned pretreatment further includes storing above-mentioned picture source file pair The picture to be restored answered.And the device can also include running unit, the first determination unit and the second determination unit (in figure It is not shown).Wherein, above-mentioned running unit may be configured to run the above-mentioned program code for also original picture, generate reduction Picture afterwards;First determination unit is configured to based on picture after above-mentioned reduction compared with above-mentioned picture to be restored, determines above-mentioned The reduction degree of picture after reduction;Second determination unit is configured to based on above-mentioned reduction degree compared with default value, in determination Whether state qualified for the program code of also original picture.
In some optional implementations of the present embodiment, which can also be including third determination unit (in figure not It shows).Wherein, above-mentioned third determination unit may be configured to determine the picture of picture and above-mentioned picture to be restored after above-mentioned reduction Plain difference.
In some optional implementations of the present embodiment, above-mentioned acquiring unit 401 can be further configured to: be rung Ying Yu receives the parsing task message of storage server transmission, and picture source document to be processed is obtained from above-mentioned storage server Part.And the device can also include storage unit (not shown).Wherein, said memory cells may be configured to by The above-mentioned program code for also original picture is sent to above-mentioned storage server.
In some optional implementations of the present embodiment, which can also include: that monitoring unit (does not show in figure Out).Wherein, above-mentioned monitoring unit may be configured to be supervised in real time according to treatment process of the default dimension to picture source file Control, wherein above-mentioned default dimension includes at least one of the following: abnormality, reduction success rate, time-consuming information.
The device provided by the above embodiment of the application, acquiring unit 401 get picture source file to be processed it Afterwards, extraction unit 402 can extract the attribute information of each element and above-mentioned each element in above-mentioned picture source file.Then, it solves Analysis unit 403 can parse above-mentioned attribute information, the positional relationship information between above-mentioned element be generated, so as to layout units 404 are based on above-mentioned positional relationship information, are laid out to above-mentioned each element.Finally, code generating unit 405 can be based on layout As a result with above-mentioned attribute information, the program code for also original picture is generated.It is thus possible to without being accomplished manually to picture source document The parsing work of part, the skill requirement for reducing the workload of front end engineer, reducing front end engineer;Meanwhile it improving The resolution speed of picture source file improves webpage development efficiency.
Below with reference to Fig. 5, it illustrates the computer systems 500 for the server for being suitable for being used to realize the embodiment of the present application Structural schematic diagram.Server shown in Fig. 5 is only an example, should not function and use scope band to the embodiment of the present application Carry out any restrictions.
As shown in figure 5, computer system 500 includes central processing unit (CPU) 501, it can be read-only according to being stored in Program in memory (ROM) 502 or be loaded into the program in random access storage device (RAM) 503 from storage section 508 and Execute various movements appropriate and processing.In RAM 503, also it is stored with system 500 and operates required various programs and data. CPU 501, ROM 502 and RAM 503 are connected with each other by bus 504.Input/output (I/O) interface 505 is also connected to always Line 504.
I/O interface 505 is connected to lower component: the importation 506 including keyboard, mouse etc.;Including such as liquid crystal Show the output par, c 507 of device (LCD) etc. and loudspeaker etc.;Storage section 508 including hard disk etc.;And including such as LAN The communications portion 509 of the network interface card of card, modem etc..Communications portion 509 is executed via the network of such as internet Communication process.Driver 510 is also connected to I/O interface 505 as needed.Detachable media 511, such as disk, CD, magneto-optic Disk, semiconductor memory etc. are mounted on as needed on driver 510, in order to from the computer program root read thereon According to needing to be mounted into storage section 508.
Particularly, in accordance with an embodiment of the present disclosure, it may be implemented as computer above with reference to the process of flow chart description Software program.For example, embodiment of the disclosure includes a kind of computer program product comprising be carried on computer-readable medium On computer program, which includes the program code for method shown in execution flow chart.In such reality It applies in example, which can be downloaded and installed from network by communications portion 509, and/or from detachable media 511 are mounted.When the computer program is executed by central processing unit (CPU) 501, limited in execution the present processes Above-mentioned function.It should be noted that computer-readable medium described herein can be computer-readable signal media or Computer readable storage medium either the two any combination.Computer readable storage medium for example can be --- but Be not limited to --- electricity, magnetic, optical, electromagnetic, infrared ray or semiconductor system, device or device, or any above combination. The more specific example of computer readable storage medium can include but is not limited to: have one or more conducting wires electrical connection, Portable computer diskette, hard disk, random access storage device (RAM), read-only memory (ROM), erasable type may be programmed read-only deposit Reservoir (EPROM or flash memory), optical fiber, portable compact disc read-only memory (CD-ROM), light storage device, magnetic memory Part or above-mentioned any appropriate combination.In this application, computer readable storage medium, which can be, any include or stores The tangible medium of program, the program can be commanded execution system, device or device use or in connection.And In the application, computer-readable signal media may include in a base band or the data as the propagation of carrier wave a part are believed Number, wherein carrying computer-readable program code.The data-signal of this propagation can take various forms, including but not It is limited to electromagnetic signal, optical signal or above-mentioned any appropriate combination.Computer-readable signal media can also be computer Any computer-readable medium other than readable storage medium storing program for executing, the computer-readable medium can send, propagate or transmit use In by the use of instruction execution system, device or device or program in connection.Include on computer-readable medium Program code can transmit with any suitable medium, including but not limited to: wireless, electric wire, optical cable, RF etc., Huo Zheshang Any appropriate combination stated.
Flow chart and block diagram in attached drawing are illustrated according to the system of the various embodiments of the application, method and computer journey The architecture, function and operation in the cards of sequence product.In this regard, each box in flowchart or block diagram can generation A part of one module, program segment or code of table, a part of the module, program segment or code include one or more use The executable instruction of the logic function as defined in realizing.It should also be noted that in some implementations as replacements, being marked in box The function of note can also occur in a different order than that indicated in the drawings.For example, two boxes succeedingly indicated are actually It can be basically executed in parallel, they can also be executed in the opposite order sometimes, and this depends on the function involved.Also it to infuse Meaning, the combination of each box in block diagram and or flow chart and the box in block diagram and or flow chart can be with holding The dedicated hardware based system of functions or operations as defined in row is realized, or can use specialized hardware and computer instruction Combination realize.
Being described in unit involved in the embodiment of the present application can be realized by way of software, can also be by hard The mode of part is realized.Described unit also can be set in the processor, for example, can be described as: a kind of processor packet Include acquiring unit, extraction unit, resolution unit, layout units and code generating unit.Wherein, the title of these units is at certain In the case of do not constitute restriction to the unit itself.
As on the other hand, present invention also provides a kind of computer-readable medium, which be can be Included in device described in above-described embodiment;It is also possible to individualism, and without in the supplying device.Above-mentioned calculating Machine readable medium carries one or more program, when said one or multiple programs are executed by the device, so that should Device: picture source file to be processed is obtained;Extract the attribute letter of each element and each element in the picture source file Breath;The attribute information is parsed, the positional relationship information of each element is generated;Based on the positional relationship information, The each element is laid out;Based on layout result and the attribute information, the program code for also original picture is generated.
Above description is only the preferred embodiment of the application and the explanation to institute's application technology principle.Those skilled in the art Member is it should be appreciated that invention scope involved in the application, however it is not limited to technology made of the specific combination of above-mentioned technical characteristic Scheme, while should also cover in the case where not departing from foregoing invention design, it is carried out by above-mentioned technical characteristic or its equivalent feature Any combination and the other technical solutions formed.Such as features described above has similar function with (but being not limited to) disclosed herein Can technical characteristic replaced mutually and the technical solution that is formed.

Claims (20)

1. a kind of code generating method, which is characterized in that be applied to server, which comprises
Obtain picture source file to be processed;
Extract the attribute information of each element and each element in the picture source file;
The attribute information is parsed, the positional relationship information between element is generated;
Based on the positional relationship information, each element is laid out;
Based on layout result and the attribute information, the program code for also original picture is generated.
2. code generating method according to claim 1, which is characterized in that the attribute information further includes element position letter Breath and element size information;And
It is described that the attribute information is parsed, generate the positional relationship information between element, comprising:
Based on the element position information and the element size information, the corresponding box model information of each element is generated;
Based on the box model information, the element position information and the element size information, the position between element is generated Relation information, wherein the positional relationship information includes the distance between the corresponding box model of element.
3. code generating method according to claim 1, which is characterized in that it is described to be based on the positional relationship information, really The columns of fixed every row element to be laid out, comprising:
Based on the positional relationship information, determine every row element to be laid out with the presence or absence of coincidence relation, wherein the coincidence is closed System includes whole coincidence relations and local coincidence relation;
The element of coincidence relation will be present as a column, the element that coincidence relation is not present in each counts every as a column The columns of row element to be laid out, is laid out according to element of the identified columns to every row.
4. code generating method according to claim 1, which is characterized in that the attribute information includes that element covering is suitable Sequence;And
It is based on the positional relationship information described, after being laid out to each element, the method also includes:
According to the element covering sequence, the layout result of each element is adjusted.
5. code generating method according to claim 1, which is characterized in that each in the extraction picture source file The attribute information of element and each element, comprising:
The picture source file is pre-processed, wherein the pretreatment is included at least one of the following: to the picture source document Each element in part is checked, is stored to each element in the picture source file;
The each element is extracted, and extracts the attribute information of each element from the picture source file.
6. code generating method according to claim 5, which is characterized in that the pretreatment further includes storing the picture The corresponding picture to be restored of source file;And
After described generate for the also program code of original picture, the method also includes:
The operation program code for also original picture, generates picture after reduction;
Picture after the reduction and the picture to be restored are compared, determine the reduction degree of picture after the reduction;
Based on the reduction degree compared with default value, determine whether the program code for also original picture is qualified.
7. code generating method according to claim 6, which is characterized in that after generation reduction after picture, institute State method further include:
Determine the pixel value difference of picture and the picture to be restored after the reduction.
8. code generating method according to claim 1, which is characterized in that it is described to obtain picture source file to be processed, Include:
In response to receiving the parsing task message of storage server transmission, figure to be processed is obtained from the storage server Piece source file;And
It is based on layout result and the attribute information described, after generating the program code for going back original picture, the method Further include:
The program code for being used for also original picture is sent to the storage server.
9. code generating method according to claim 1, which is characterized in that the method also includes:
It is monitored in real time according to treatment process of the default dimension to picture source file, wherein the default dimension includes following At least one of: abnormality, reduction success rate, time-consuming information.
10. a kind of code generating unit, which is characterized in that be applied to server, described device includes:
Acquiring unit is configured to obtain picture source file to be processed;
Extraction unit, the attribute information of each element and each element that are configured to extract in the picture source file;
Resolution unit is configured to parse the attribute information, generates the positional relationship information between element;
Layout units are configured to be laid out each element based on the positional relationship information;
Code generating unit is configured to generate the program generation for also original picture based on layout result and the attribute information Code.
11. code generating unit according to claim 10, which is characterized in that the attribute information further includes element position Information and element size information;And
The resolution unit, comprising:
First generation module is configured to generate each member based on the element position information and the element size information The corresponding box model information of element;
Second generation module is configured to based on the box model information, the element position information and the element size Information generates the positional relationship information between element, wherein the positional relationship information includes between the corresponding box model of element Distance.
12. code generating unit according to claim 10, which is characterized in that the layout modules, comprising:
First determining module is configured to determine every row element to be laid out with the presence or absence of weight based on the positional relationship information Conjunction relationship, wherein the coincidence relation includes whole coincidence relations and local coincidence relation;
Second determining module is configured to will be present the element of coincidence relation as a column, coincidence relation is not present in each Element as a column, count the columns of every row element to be laid out, cloth carried out to the element of every row according to identified columns Office.
13. code generating unit according to claim 10, which is characterized in that the attribute information includes that element covering is suitable Sequence;And
Described device further include:
Adjustment unit is configured to be adjusted the layout result of each element according to the element covering sequence.
14. code generating unit according to claim 10, which is characterized in that the extraction unit is further configured At:
The picture source file is pre-processed, wherein the pretreatment is included at least one of the following: to the picture source document Each element in part is checked, is stored to each element in the picture source file;
The each element is extracted, and extracts the attribute information of each element from the picture source file.
15. code generating unit according to claim 14, which is characterized in that the pretreatment further includes storing the figure The corresponding picture to be restored of piece source file;And
Described device further include:
Running unit is configured to run the program code for also original picture, generates picture after reduction;
First determination unit is configured to compare in picture after the reduction and the picture to be restored, determines described go back The reduction degree of picture after original;
Second determination unit is configured to based on the reduction degree compared with default value, is determined described for also original picture Program code it is whether qualified.
16. code generating unit according to claim 15, which is characterized in that described device further include:
Third determination unit is configured to determine the pixel value difference of picture and the picture to be restored after the reduction.
17. code generating unit according to claim 10, which is characterized in that the acquiring unit is further configured At:
In response to receiving the parsing task message of storage server transmission, figure to be processed is obtained from the storage server Piece source file;And
Described device further include:
Storage unit is configured to the program code for being used for also original picture being sent to the storage server.
18. code generating unit according to claim 10, which is characterized in that described device further include:
Monitoring unit is configured to monitor in real time according to treatment process of the default dimension to picture source file, wherein described Default dimension includes at least one of the following: abnormality, reduction success rate, time-consuming information.
19. a kind of server characterized by comprising
One or more processors;
Storage device is stored thereon with one or more programs,
When one or more of programs are executed by one or more of processors, so that one or more of processors are real The now method as described in any in claim 1-9.
20. a kind of computer-readable medium, is stored thereon with computer program, which is characterized in that the program is executed by processor Method of the Shi Shixian as described in any in claim 1-9.
CN201910024809.0A 2019-01-10 2019-01-10 Code generation method, device, server and computer readable medium Active CN109857388B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910024809.0A CN109857388B (en) 2019-01-10 2019-01-10 Code generation method, device, server and computer readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910024809.0A CN109857388B (en) 2019-01-10 2019-01-10 Code generation method, device, server and computer readable medium

Publications (2)

Publication Number Publication Date
CN109857388A true CN109857388A (en) 2019-06-07
CN109857388B CN109857388B (en) 2021-06-15

Family

ID=66894456

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910024809.0A Active CN109857388B (en) 2019-01-10 2019-01-10 Code generation method, device, server and computer readable medium

Country Status (1)

Country Link
CN (1) CN109857388B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110321126A (en) * 2019-07-08 2019-10-11 北京三快在线科技有限公司 The method and apparatus for generating page code
CN110442333A (en) * 2019-07-11 2019-11-12 北京磨刀刻石科技有限公司 Method and apparatus based on design drawing automatically generating program code
CN112116681A (en) * 2019-06-19 2020-12-22 腾讯科技(深圳)有限公司 Image generation method and device, computer equipment and storage medium
CN113535151A (en) * 2020-04-14 2021-10-22 北京京东振世信息技术有限公司 Code generation method and device
CN113742619A (en) * 2020-11-13 2021-12-03 北京沃东天骏信息技术有限公司 Page layout determination method and device, electronic equipment and storage medium
CN114647476A (en) * 2022-03-31 2022-06-21 北京百度网讯科技有限公司 Page rendering method, device, equipment, storage medium and program
CN116798053A (en) * 2023-07-20 2023-09-22 上海合芯数字科技有限公司 Icon generation method and device

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20090003731A1 (en) * 2006-06-30 2009-01-01 Sharp Kabushiki Kaisha Image data providing apparatus, image display apparatus, image display system, method for controlling image data providing apparatus, method for controlling image display apparatus, control program, and recording medium
CN103744674A (en) * 2014-01-06 2014-04-23 北京奇虎科技有限公司 Method and device for generating hypertext markup language (HTML) procedure code
CN104166556A (en) * 2014-08-27 2014-11-26 北京金山安全软件有限公司 Software interface replacing method and device and terminal
CN106484408A (en) * 2016-09-29 2017-03-08 电子科技大学 A kind of node relationships figure display methods based on HTML5 and system
CN107357942A (en) * 2017-09-04 2017-11-17 山东达创网络科技股份有限公司 A kind of source code auxiliary Core Generator and its generation method
US20170337038A1 (en) * 2016-05-20 2017-11-23 Microsoft Technology Licensing, Llc Augmenting an original class with an augmenting class
US20180300298A1 (en) * 2002-09-10 2018-10-18 Sqgo Innovations, Llc System and method for provisioning a mobile software application to a mobile device
US10108432B1 (en) * 2009-04-16 2018-10-23 Intuit Inc. Generating a script based on user actions
CN110427187A (en) * 2019-07-31 2019-11-08 山东浪潮通软信息科技有限公司 A kind of list visual layout method based on the parsing of HTML Custom Attributes

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180300298A1 (en) * 2002-09-10 2018-10-18 Sqgo Innovations, Llc System and method for provisioning a mobile software application to a mobile device
US20090003731A1 (en) * 2006-06-30 2009-01-01 Sharp Kabushiki Kaisha Image data providing apparatus, image display apparatus, image display system, method for controlling image data providing apparatus, method for controlling image display apparatus, control program, and recording medium
US10108432B1 (en) * 2009-04-16 2018-10-23 Intuit Inc. Generating a script based on user actions
CN103744674A (en) * 2014-01-06 2014-04-23 北京奇虎科技有限公司 Method and device for generating hypertext markup language (HTML) procedure code
CN104166556A (en) * 2014-08-27 2014-11-26 北京金山安全软件有限公司 Software interface replacing method and device and terminal
US20170337038A1 (en) * 2016-05-20 2017-11-23 Microsoft Technology Licensing, Llc Augmenting an original class with an augmenting class
CN106484408A (en) * 2016-09-29 2017-03-08 电子科技大学 A kind of node relationships figure display methods based on HTML5 and system
CN107357942A (en) * 2017-09-04 2017-11-17 山东达创网络科技股份有限公司 A kind of source code auxiliary Core Generator and its generation method
CN110427187A (en) * 2019-07-31 2019-11-08 山东浪潮通软信息科技有限公司 A kind of list visual layout method based on the parsing of HTML Custom Attributes

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112116681A (en) * 2019-06-19 2020-12-22 腾讯科技(深圳)有限公司 Image generation method and device, computer equipment and storage medium
CN110321126A (en) * 2019-07-08 2019-10-11 北京三快在线科技有限公司 The method and apparatus for generating page code
CN110442333A (en) * 2019-07-11 2019-11-12 北京磨刀刻石科技有限公司 Method and apparatus based on design drawing automatically generating program code
CN113535151A (en) * 2020-04-14 2021-10-22 北京京东振世信息技术有限公司 Code generation method and device
CN113535151B (en) * 2020-04-14 2024-05-17 北京京东振世信息技术有限公司 Code generation method and device
CN113742619A (en) * 2020-11-13 2021-12-03 北京沃东天骏信息技术有限公司 Page layout determination method and device, electronic equipment and storage medium
CN114647476A (en) * 2022-03-31 2022-06-21 北京百度网讯科技有限公司 Page rendering method, device, equipment, storage medium and program
CN114647476B (en) * 2022-03-31 2024-06-11 北京百度网讯科技有限公司 Page rendering method, device, equipment, storage medium and program
CN116798053A (en) * 2023-07-20 2023-09-22 上海合芯数字科技有限公司 Icon generation method and device
CN116798053B (en) * 2023-07-20 2024-04-26 上海合芯数字科技有限公司 Icon generation method and device

Also Published As

Publication number Publication date
CN109857388B (en) 2021-06-15

Similar Documents

Publication Publication Date Title
CN109857388A (en) Code generating method, device, server and computer-readable medium
US20230401828A1 (en) Method for training image recognition model, electronic device and storage medium
CN108984399A (en) Detect method, electronic equipment and the computer-readable medium of interface difference
CN109739478A (en) Front end project automated construction method, device, storage medium and electronic equipment
CN106980508A (en) Method and apparatus for generating the page
CN107239491A (en) For realizing method, equipment, browser and electronic equipment that user behavior is followed the trail of
CN109446099A (en) Automatic test cases generation method, device, medium and electronic equipment
CN109213486A (en) Method and apparatus for generating customized visualization component
US11170135B2 (en) Method, apparatus, and device for generating a visual model layout of a space
CN109271403A (en) A kind of operating method of data query, device, medium and electronic equipment
US10049095B2 (en) In-context editing of output presentations via automatic pattern detection
CN110837356B (en) Data processing method and device
CN110020329A (en) For generating the methods, devices and systems of webpage
CN109359194A (en) Method and apparatus for predictive information classification
CN110400029A (en) A kind of method and system of mark management
CN106874519A (en) Webpage representation method and apparatus
CN109582317A (en) Method and apparatus for debugging boarding application
CN109101309A (en) For updating user interface method and device
CN107506190A (en) XML file amending method and device based on Spring frameworks
CN110209906A (en) Method and apparatus for extracting webpage information
CN112839185B (en) Method, apparatus, device and medium for processing image
CN112801086A (en) Method and device for classifying certificates, electronic equipment and storage medium
CN108921792A (en) Method and apparatus for handling picture
CN110941401A (en) Printing method and device
CN109977011A (en) Automatic generation method, device, storage medium and the electronic equipment of test script

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