WO2017084452A1 - 图形界面中标签页的处理方法和装置 - Google Patents

图形界面中标签页的处理方法和装置 Download PDF

Info

Publication number
WO2017084452A1
WO2017084452A1 PCT/CN2016/101624 CN2016101624W WO2017084452A1 WO 2017084452 A1 WO2017084452 A1 WO 2017084452A1 CN 2016101624 W CN2016101624 W CN 2016101624W WO 2017084452 A1 WO2017084452 A1 WO 2017084452A1
Authority
WO
WIPO (PCT)
Prior art keywords
page
tab
color
background color
graphical interface
Prior art date
Application number
PCT/CN2016/101624
Other languages
English (en)
French (fr)
Inventor
李斌
Original Assignee
腾讯科技(深圳)有限公司
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 腾讯科技(深圳)有限公司 filed Critical 腾讯科技(深圳)有限公司
Publication of WO2017084452A1 publication Critical patent/WO2017084452A1/zh
Priority to US15/715,628 priority Critical patent/US10109079B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/001Texturing; Colouring; Generation of texture or colour
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • G06F3/0483Interaction with page-structured environments, e.g. book metaphor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04847Interaction techniques to control parameter settings, e.g. interaction with sliders or dials
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures

Definitions

  • the present application relates to the field of communications technologies, and in particular, to a method and an apparatus for processing a tab page in a graphical interface.
  • GUI Graphical User Interface
  • HTML Hypertext Markup Language
  • a tab page corresponds to an open web page or file
  • the website icon (favicon) and the website title (or file title) are generally displayed in the tab page, and when the user needs to browse a web page or file, Click on the appropriate tab to open the corresponding webpage or file, which allows you to manage multiple open webpages in the same browser.
  • the embodiment of the present invention provides a method and a device for processing a tab page in a graphical interface, which can improve the recognition degree of the tab page, and improve the recognition and propagation of information in the tab page while facilitating user operations.
  • An embodiment of the present application provides a method for processing a tab page in a graphical interface, including:
  • the background color of the tab corresponding to the page is drawn according to the background color of the tab page, and a color tab page is obtained;
  • the page and color tabs are displayed in the graphical interface.
  • the embodiment of the present application further provides a processing device for a tab page in a graphical interface, including:
  • a receiving unit configured to receive a page access request triggered by the user through a graphical interface
  • An obtaining unit configured to obtain a corresponding page according to the page access request
  • a detecting unit configured to detect whether the page background color of the tab has been set
  • a first drawing unit configured to: when the detecting unit determines that the tab page background color has been set, draw a background color of the tab page corresponding to the page according to the tab page background color, to obtain a color tab page;
  • a second drawing unit configured to: when the detecting unit determines that the background color of the tab is not set, extract a main color of the page, and draw a background color of the tab corresponding to the page according to the main color to obtain a color label page;
  • a display unit for displaying the page and the color tab in the graphical interface.
  • the embodiment of the present application further provides a processing device for a tab page in a graphical interface, including: a processor, a memory connected to the processor; storing, in the memory, a machine readable instruction, the processor executing the Machine-readable instructions do the following to do the following:
  • the page and color tabs are displayed in the graphical interface.
  • the embodiment of the present application further provides a non-transitory computer readable storage medium, where the machine readable instructions are stored in a storage medium, and the machine readable instructions may be executed by a processor to perform the following operations:
  • the background color of the tab corresponding to the page is drawn according to the background color of the tab page, and a color tab page is obtained;
  • the page and color tabs are displayed in the graphical interface.
  • the embodiment of the present application adopts, when receiving a page access request triggered by the user through a graphical interface, obtains a corresponding page according to the page access request, and detects whether the page background color of the tab has been set, and if so, according to the tab page The background color is used to draw the background color of the tab corresponding to the page, and a color tab is obtained. Otherwise, if not set, the main color of the page is extracted, and the background color of the tab corresponding to the page is drawn according to the main color to obtain a color label.
  • FIG. 1 is a flowchart of a method for processing a tab page in a graphical interface provided by an embodiment of the present application
  • FIG. 2 is another flowchart of a method for processing a tab page in a graphical interface provided by an embodiment of the present application
  • FIG. 3a is another flowchart of a method for processing a tab in a graphical interface provided by an embodiment of the present application
  • FIG. 3b is a schematic diagram of a tab page in a graphical interface browser provided by an embodiment of the present application.
  • FIG. 3c is another schematic diagram of a tab page in a graphical interface browser provided by an embodiment of the present application.
  • FIG. 4a is a schematic structural diagram of a processing device for a tab page in a graphical interface provided by an embodiment of the present application
  • 4b is another schematic structural diagram of a processing device for a tab page in a graphical interface provided by an embodiment of the present application
  • FIG. 5 is a schematic structural diagram of a terminal provided by an embodiment of the present application.
  • the embodiment of the present application provides a method and an apparatus for processing a tab page in a graphical interface.
  • a page access request triggered by a user through a graphical interface is received; a corresponding page is obtained according to the page access request; and a background color of the tab page is set for the page; if it is set, according to the tab page
  • the background color is drawn to the background color of the tab corresponding to the page, to obtain a color tab page; if not set, the main color of the page is extracted, and the background color of the tab corresponding to the page is drawn according to the main color to obtain a color tab page;
  • the page and color tabs are displayed in the graphical interface.
  • the main color of the page refers to the basic tendency of the page to appear in color appearance.
  • colors can be used in the page, there is a general tendency, for example, bluish or reddish.
  • the basic tendency of this color appearance is the dominant color of the page.
  • FIG. 1 is a flowchart of a method for processing a tab page in a graphical interface provided by an embodiment of the present application. This embodiment is described from the perspective of a processing device of a tab page in a graphical interface.
  • the processing device of the tab page in the graphical interface may be integrated into a device such as a terminal, or may be installed in a device such as a terminal in a software format.
  • the terminal may specifically be a mobile phone, a tablet computer, a notebook computer, or a personal computer (PC, Personal Computer).
  • the specific process of processing the tab page in the graphical interface may be as follows:
  • the user may receive the link address input through the address bar in the graphical interface to trigger the page access request; or, the user may receive the click through the graphical interface.
  • the link interface or trigger key is used to trigger the page access request, and so on, and will not be described here.
  • the page access request may carry information such as the address of the page to be accessed.
  • the graphical interface may specifically be a browser, or other HTML file content for displaying a web server or a file system, and other applications that allow the user to interact with the files.
  • a browser will be taken as an example for description.
  • the page access request may be sent to the corresponding website server according to the address of the page carried in the page access request, and the web page returned by the website server according to the page access request may be received.
  • a page access request may be sent to the corresponding device according to the address of the page carried in the page access request, and the file returned by the device according to the page access request, such as a picture or a video, may be received.
  • step 104 Detect whether the page background color has been set on the page. If the background color of the tab page has been set, go to step 104. If the background color of the tab page is not set, go to step 105.
  • the background color of the tab may be set in various ways.
  • the background color of the tab may be set in the content of the tab. Parameter, and then set the background color of the tab by assigning a value to the background color parameter of the tab, or you can also set the link address of the background color of the tab, such as a Uniform Resource Locator (URL, etc.) to set the tab. Background color, and so on.
  • URL Uniform Resource Locator
  • the corresponding detection manner may be specifically as follows:
  • the content of the page includes a tab background color parameter, determining whether the value of the tab background color parameter is a preset value; if yes, determining that the tab background color is set, and according to the pre- Set the value to determine the background color of the tab; if not, make sure the label is not set The background color of the page.
  • the content of the page may generally include an HTML file and a Cascading Style Sheet (CSS) file, wherein the CSS related information may also be embedded in the HTML file, so the HTML file and the CSS file of the page may be parsed. To get the content of the page.
  • CSS Cascading Style Sheet
  • the preset value may be determined according to the actual application requirement, and may be a numerical value, a plurality of numerical values, or a range of one or several numerical values, and details are not described herein again.
  • the link address of the background color of the tab may be set by the website where each page is located (that is, by way of fixing the default URL of the rule), or may be set in the content of the page such as the content of the webpage.
  • the specific composition factor of the link address may be determined according to the needs of the actual application, for example, a domain name + a specific path (such as tab-background-color), and the like.
  • the background color of the tab page corresponding to the page is drawn according to the background color of the tab page, and a color tab page is obtained.
  • the "color” in the color tab of the embodiment of the present invention includes various colors in the black and white gray system such as white, gray, and black, in addition to the color corresponding to the "color” in the conventional sense.
  • the color can even include “transparent”, that is, the color tab here refers to "the tab page drawn according to the background color of the tab page", and does not mean that the background color of the tab page is "color”.
  • the main color of the page is extracted, and the background color of the tab corresponding to the page is drawn according to the main color to obtain a color tab.
  • the method for extracting the main color of the page may be various.
  • the icon (favicon) of the page may be determined, and then the main color of the icon is extracted, according to the main color of the icon. Adjust the main color of the page, and so on.
  • the icon of the page, that is, favicon is generally displayed on the left side of the tab page, and can also be displayed in the bookmark and history.
  • the primary color tone may be extracted in a proportion of the number of pixels, and then the default color of the page may be calculated by using a preset algorithm, and the like. Different algorithms may get different page main colors, which will not be described here.
  • the content of the page may be displayed in a page display area in the graphical interface, and the color tab page is displayed in a tab bar; wherein the tab bar refers to a container of tab pages for displaying and managing the area of the tab page.
  • the tab bar refers to a container of tab pages for displaying and managing the area of the tab page.
  • a graphical interface such as a browser.
  • the processing method of the tab in the graphical interface may further include:
  • Step 107 When a new tab or other tab in the graphical interface is selected, the background color of the color tab displayed in the graphical interface may be replaced with a preset color.
  • the processing method of the tab page in the graphic interface may further include:
  • Step 108 When the tab of the page in the graphical interface is selected, the tab of the page in the graphical interface is replaced with the colored tab.
  • an interface for dynamically setting the background color of the tab page may be provided in the graphical interface. If the background color of the tab page needs to be set, the corresponding interface may be invoked. Realize the setting of the tab background color. That is, the processing method of the tab page in the graphic interface may further include:
  • FIG. 2 is a flowchart of a method for processing a tab page in a graphical interface according to an embodiment of the present disclosure. As shown in FIG. 2, the method includes the following operations. Step 201: Receive a page access request triggered by a user through a graphical interface.
  • Step 202 Acquire a corresponding page according to the page access request.
  • the steps 201 to 202 are the same as the steps 101 to 102 shown in FIG. 1 , and details are not described herein again.
  • Step 203 Draw the background color of the tab page corresponding to the page.
  • the main color of the page may be extracted, and then the background color of the tab corresponding to the page is drawn according to the main color.
  • the background color of the tab corresponding to the page may be drawn as the background color of the normal tab, that is, there is no background color difference from other tabs.
  • the drawing may be performed based on the background color of the tab obtained from the web page content or the setting URL.
  • Step 204 Receive a setting request of a background color of a tab page input by a webpage through a preset interface in the graphic interface, where the setting request carries information such as a color to be set, and the color to be set is used as a tab background of the page. Color, redraw the background color of the tab page.
  • the preset interface can be set according to the requirements of the actual application, and details are not described herein again.
  • the embodiment when receiving the page access request triggered by the user through the graphical interface, the embodiment obtains the corresponding page according to the page access request, and detects whether the page background color of the tab has been set, if it is set, according to The background color of the tab page draws the background color of the tab page corresponding to the page, and obtains a color tab page. Otherwise, if not set, the main color of the page is extracted, and the background color of the tab page corresponding to the page is drawn according to the main color.
  • the background color can be flexibly set for the tab page according to different situations, for example, when the preset tab background color is detected, the preset tab background color is used as the tab page.
  • the background color and when the background color of the tab is not set, the main color of the extracted page is used as the background color of the tab, and so on, so that it is possible to avoid some pages from being difficult to extract the main color, such as in the icon of the website. Containing a variety of different colors that are the same or close to each other, or the main color of the icon of the website is inconsistent with the main color of the website content, and even the occurrence of the recognition failure is beneficial to improve the recognition efficiency and recognition. effect.
  • the solution not only helps the user to identify, but also facilitates the user to view and operate. Moreover, the recognition efficiency, the recognition effect, and the recognition and dissemination of information in the tab can be improved.
  • FIG. 3a is another flowchart of a method for processing a tab page in a graphical interface provided by an embodiment of the present application.
  • the graphical interface is specifically a browser
  • the processing device of the tab in the graphical interface is specifically integrated into the terminal as an example for description.
  • the processing device of the tab page in the graphical interface may be integrated into the terminal.
  • the method may be installed in the browser of the terminal in a plug-in manner, or may be installed in the terminal in the form of an application. Wait, don't repeat them here.
  • the processing device of the tab page in the graphical interface is integrated into the terminal as an example, and the specific integration manner is not limited.
  • a method for processing a tab page in a graphical interface may be as follows:
  • the terminal receives a page access request triggered by the user by using a browser, where the page access request may carry information such as an address of a page that needs to be accessed.
  • the user can enter the link address of the website to be accessed in the address bar of the browser of the terminal, so that the page can be generated according to the link address of the website to be accessed.
  • the request is accessed; or the user can also trigger the page access request by clicking on the link address of a website in the browser, and so on.
  • the terminal sends the page access request to the corresponding website server according to the address of the page carried in the page access request, and receives a page returned by the website server according to the page access request.
  • step 303 The terminal detects whether the page background color is set on the page. If the background color of the tab page is set, step 304 is performed. If the background color of the tab page is not set, step 305 is performed.
  • the background color of the tab may be set in various ways.
  • the background color of the tab may be set in the content of the tab. Parameters, and then set the tab background color by assigning a value to the tab background color parameter, or you can also set the link address of the tab background color, such as a URL to set the background color of the tab, and so on.
  • the corresponding detection manner may be specifically as follows:
  • the content of the page includes a tab background color parameter, determining whether the value of the tab background color parameter is a preset value; if yes, determining that the tab background color is set, and according to the pre- Set the value to determine the background color of the tab; if not, make sure the background color of the tab is not set.
  • the content of the page may generally include an HTML file and a CSS file.
  • the related information of the CSS may also be embedded in the HTML file. Therefore, the content of the page may be obtained by parsing the HTML file and the CSS file of the page.
  • you can set information about the tab page of the browser such as adding a tab page identifier in the CSS information, and assigning a value to the background color of the tab page by using the background color parameter "background-color" of the tab page.
  • the back of the tab page of the browser can be The scenery is set to gray, and so on.
  • the preset value may be determined according to the actual application requirement, and may be a numerical value, a plurality of numerical values, or a range of one or several numerical values, and details are not described herein again.
  • the link address of the background color of the tab may be set by the website where each page is located (that is, by way of fixing the default URL of the rule), or may be set in the content of the page such as the content of the webpage.
  • the specific composition factor of the link address may be determined according to the needs of the actual application, for example, a domain name + a specific path (such as tab-background-color), and the like.
  • the default URL of the background color of the tab set by the website "www.123456789.com” may be:
  • the URL can be set in the HTML file.
  • the following code is set in the webpage of "www.123456789.com":
  • the terminal draws according to the background color of the tab.
  • the background color of the tab corresponding to the page is obtained, and a color tab is obtained.
  • the terminal extracts a primary color of the page, and draws a background color of the tab corresponding to the page according to the primary color to obtain a color tab.
  • the method for extracting the main color of the page may be various.
  • the icon (favicon) of the page may be determined, and then the main color of the icon is extracted in a proportion of the number of pixels, and based on the main color of the icon.
  • the terminal displays the page and the color tab in the browser.
  • the content of the page may be specifically displayed in a page display area in the browser, and the color tab page is displayed in a tab bar of the browser.
  • the website A, B is included in the tab bar 310 of the browser.
  • the tab page of the page is displayed as a corresponding color tab page; otherwise, The tab page of the page can be displayed as a normal tab page.
  • the tab page 312 of the B website is clicked, the tab page 313 of the C website is changed from a color tab page (ie, gray, see FIG. 3b) to a common tab.
  • Tabs, such as tabs with white backgrounds, and tabs 212 for B sites are replaced with colored tabs, such as black tabs, and so on.
  • the tab page in the graphical interface of the page is selected again, for example, the user clicks on the tab 313 of the C website, the tab 313 of the C website can be replaced with a color tab page, that is, a tab with a gray background. See Figure 3b.
  • an interface for dynamically setting the background color of the tab page may be provided in the graphical interface. If the background color of the tab page needs to be set, the corresponding interface may be invoked. To achieve the setting of the tab background color, you can also perform the steps:
  • the interface provided by the browser to set the background color of the tab is generally called by JavaScript in the webpage.
  • the web page can select the appropriate color value as the background color of the tab page according to the characteristics of its own content. For example, if you need to set the background color of the tab to gray, you can set the following code:
  • step of setting the background color of the tab page and the execution of any of the steps 301-306 may be performed in any order, that is, the background color of the tab may be set at any time, and details are not described herein again.
  • the embodiment when receiving a page access request triggered by the browser by the user, the embodiment obtains a corresponding page according to the page access request, and detects whether the page background color of the tab has been set, and if so, according to The background color of the tab page draws the background color of the tab page corresponding to the page, and obtains a color tab page. Otherwise, if not set, the main color of the page is extracted, and the background color of the tab page corresponding to the page is drawn according to the main color.
  • the background color can be flexibly set for the tab page according to different situations, for example, when the preset tab background color is detected, the preset tab background color is used as the tab page.
  • the background color and when the background color of the tab is not set, the main color of the extracted page is used as the background color of the tab, and so on, so that it is possible to avoid some pages from being difficult to extract the main color, such as in the icon of the website. Contains a variety of different colors that are the same or close to each other, or the main color of the icon of the website is inconsistent with the main color of the website content, and even identifies the failure. Occurs to improve recognition efficiency and recognition.
  • the solution not only helps the user to identify, but also facilitates the user to view and operate. Moreover, the recognition efficiency, the recognition effect, and the recognition and dissemination of information in the tab can be improved.
  • the embodiment of the present application further provides a processing device for a tab page in a graphical interface.
  • the processing device of the tab page in the graphical interface may include a receiving unit 401, an obtaining unit 402, a detecting unit 403, and a first drawing unit. 404.
  • the receiving unit 401 is configured to receive a page access request triggered by the user through a graphical interface.
  • the user may receive the link address input through the address bar in the graphical interface to trigger the page access request; or the user may trigger the page access request by clicking the link interface or the trigger button in the graphical interface, etc. Etc., I will not repeat them here.
  • the page access request may carry information such as the address of the page to be accessed.
  • the graphical interface may specifically be a browser, or other HTML file content for displaying a web server or a file system, and other applications that allow the user to interact with the files.
  • a browser will be taken as an example for description.
  • the obtaining unit 402 is configured to obtain a corresponding page according to the page access request.
  • the obtaining unit 402 may send a page access request to the corresponding website server according to the address of the page carried in the page access request, and receive the web page returned by the website server according to the page access request.
  • the obtaining unit 402 may send a page access request to the corresponding device according to the address of the page carried in the page access request, and receive a file returned by the device according to the page access request, such as a picture or a video, and the like.
  • the detecting unit 403 is configured to detect whether the page background color has been set on the page.
  • the background color of the tab can be set in various ways.
  • the tab background color parameter can be set in the content of the page, and then the background color of the tab is set by assigning a value to the background color parameter of the tab.
  • the details can be as follows:
  • the detecting unit 403 is specifically configured to obtain the content of the page, where the content of the page includes a tab background color parameter; determine whether the value of the background color parameter of the tab is a preset value; if yes, determine that the tab background is set Color, and determine the background color of the tab according to the preset value; if not, it is determined that the tab background color is not set.
  • the preset value may be determined according to the actual application requirement, and may be a numerical value, a plurality of numerical values, or a range of one or several numerical values, and details are not described herein again.
  • the detecting unit 403 may be specifically configured to determine whether the page has a link address of a corresponding tab background color; if yes, determine that the tab background color has been set, and obtain a tab background color according to the link address; if not, Then it is determined that the tab background color is not set.
  • the link address of the background color of the tab may be set by the website where each page is located (that is, by way of fixing the default URL of the rule), or may be set in the content of the page such as the content of the webpage.
  • the specific composition factor of the link address may be determined according to the needs of the actual application, for example, a domain name + a specific path (such as tab-background-color), and the like.
  • the first drawing unit 404 is configured to: when the detecting unit determines that the tab page background color has been set, draw a background color of the tab page corresponding to the page according to the tab page background color, to obtain a color tab page.
  • the second drawing unit 405 is configured to: when the detecting unit determines that the tab page background color is not set, extract a main color of the page, and draw a background color of the tab page corresponding to the page according to the main color to obtain a color tab page.
  • the method for extracting the main color of the page may be various.
  • the icon (favicon) of the page may be determined, then the main color of the icon is extracted, the main color of the page is calculated according to the main color of the icon, and the like. which is:
  • the second drawing unit 405 is specifically configured to: when the detecting unit determines that the tab page background color is not set, determine an icon of the page; extract a main color of the icon, and calculate a main color of the page according to the main color of the icon, according to The main color of the page draws the background color of the tab corresponding to the page, resulting in a color tab.
  • the primary color tone may be extracted in a proportion of the number of pixels, and then the default color of the page may be calculated by using a preset algorithm, and the like. Different algorithms may get different page main colors, which will not be described here.
  • Display unit 406 is for displaying the page and color tabs in the graphical interface.
  • the display unit 406 can be specifically configured to display the content of the page in the page display area in the graphical interface, and display the color tab in the tab bar.
  • an interface for dynamically setting the background color of the tab page may be provided in the graphical interface. If the background color of the tab page needs to be set, the corresponding interface may be invoked. Realize the setting of the tab background color. That is, as shown in FIG. 4b, the processing device of the tab page in the graphical interface may further include a setting unit 407, configured to set a tab background color of the page.
  • the setting unit 407 can be configured to receive a setting request of a background color of a tab page input by a webpage through a preset interface in the graphical interface, where the setting request carries a color to be set; The tab background color of the page.
  • the preset interface can be set according to the requirements of the actual application, and details are not described herein again.
  • the tab page of the page is displayed as a corresponding color tab page; otherwise, The tab of the page can be displayed as a normal tab.
  • the so-called normal tab refers to a tab that does not have a background color difference from other tabs.
  • the background color of the tab can also be preset according to the needs of the actual application. . That is, as shown in FIG. 4b, the processing device of the tab page in the graphical interface may further include a replacing unit 408. When a new tab or other tab is selected in the graphical interface, the background color of the color tab displayed in the graphical interface can be changed to a preset color.
  • the tab page in the graphical interface of the page is selected again, for example, the user clicks on the tab of the page, the tab of the page in the graphical interface can be replaced with the color tab again for highlighting. , indicating that the page corresponding to the color tab is the page that the current user is browsing, and so on. which is:
  • the replacing unit 408 is further configured to replace the tab page in the graphical interface with the color tab page when the tab page of the web interface is selected.
  • the foregoing units may be implemented as a separate entity, or may be implemented in any combination, and may be implemented as the same or a plurality of entities.
  • the foregoing method embodiments and details are not described herein.
  • the processing device of the tab page in the graphic interface may be integrated into a device such as a terminal, or may be installed in a device such as a terminal in the form of a software, and the terminal may be a device such as a mobile phone, a tablet computer, a notebook computer or a PC.
  • the processing device of the tab page in the graphical interface of the embodiment receives the page access request triggered by the user through the graphical interface
  • the obtaining unit 402 acquires the corresponding page according to the page access request, and is detected by the detecting unit 403. Detecting whether the page has a tab background color. If it is set, the first drawing unit 404 draws the background color of the tab corresponding to the page according to the background color of the tab to obtain a color tab. Otherwise, if not, Then, the second drawing unit 405 extracts the main color of the page, and draws the background color of the tab corresponding to the page according to the main color to obtain a color label page, and then displays the page and the display unit 406 in the graphic interface.
  • the main color of the extracted page is used as the background color of the tab, and so on, so that it is possible to prevent some pages from being difficult to extract the main color, such as the icon of the website containing different colors of the same or close to each other. , or the recognition error caused by the main color of the icon of the website and the main color of the website content is inconsistent, and even the occurrence of the recognition failure is beneficial to improve the recognition efficiency and the recognition effect.
  • the solution not only helps the user to identify, but also facilitates the user to view and operate. Moreover, the recognition efficiency, the recognition effect, and the recognition and dissemination of information in the tab can be improved.
  • the embodiment of the present application further provides a terminal.
  • the terminal may include a radio frequency (RF) circuit 501, a memory 502 including one or more computer readable storage media, and an input unit. 503.
  • RF radio frequency
  • the terminal structure shown in FIG. 5 does not constitute a limitation to the terminal, and may include more or less components than those illustrated, or a combination of certain components, or different component arrangements. among them:
  • the RF circuit 501 can be used for transmitting and receiving information or during a call, and receiving and transmitting the signal. Specifically, after receiving the downlink information of the base station, the downlink information is processed by one or more processors 508. In addition, the data related to the uplink is sent to the base station. .
  • the RF circuit 501 includes, but is not limited to, an antenna, at least one amplifier, a tuner, one or more oscillators, a Subscriber Identity Module (SIM) card, a transceiver, a coupler, a low noise amplifier (LNA, Low Noise Amplifier), duplexer, etc. In addition, the RF circuit 501 can also communicate with the network and other devices through wireless communication.
  • SIM Subscriber Identity Module
  • LNA Low Noise Amplifier
  • the wireless communication may use any communication standard or protocol, including but not limited to Global System of Mobile communication (GSM), General Packet Radio Service (GPRS), and Code Division Multiple Access (CDMA). , Code Division Multiple Access), Wideband Code Division Multiple Access (WCDMA), long LTE (Long Term Evolution), e-mail, Short Message Service (SMS), etc.
  • GSM Global System of Mobile communication
  • GPRS General Packet Radio Service
  • CDMA Code Division Multiple Access
  • Code Division Multiple Access Code Division Multiple Access
  • WCDMA Wideband Code Division Multiple Access
  • long LTE Long Term Evolution
  • SMS Short Message Service
  • the memory 502 can be used to store software programs and modules, and the processor 508 executes various functional applications and data processing by running software programs and modules stored in the memory 502.
  • the memory 502 may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application required for at least one function (such as a sound playing function, an image playing function, etc.), and the like; the storage data area may be stored according to Data created by the use of the terminal (such as audio data, phone book, etc.).
  • memory 502 can include high speed random access memory, and can also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, memory 502 may also include a memory controller to provide access to memory 502 by processor 508 and input unit 503.
  • the input unit 503 can be configured to receive input numeric or character information and to generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function controls.
  • input unit 503 can include a touch-sensitive surface as well as other input devices.
  • Touch-sensitive surfaces also known as touch screens or trackpads, collect touch operations on or near the user (such as the user using a finger, stylus, etc., any suitable object or accessory on a touch-sensitive surface or touch-sensitive Operation near the surface), and drive the corresponding connecting device according to a preset program.
  • the touch-sensitive surface can include two portions of a touch detection device and a touch controller.
  • the touch detection device detects the touch orientation of the user, and detects a signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts the touch information into contact coordinates, and sends the touch information.
  • the processor 508 is provided and can receive commands from the processor 508 and execute them.
  • touch-sensitive surfaces can be implemented in a variety of types, including resistive, capacitive, infrared, and surface acoustic waves.
  • the input unit 503 can also include other input devices. Specifically, other input devices may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control buttons, switch buttons, etc.), trackballs, mice, joysticks, and the like.
  • Display unit 504 can be used to display information entered by the user or information provided to the user, as well as various graphical user interfaces of the terminal, which can be composed of graphics, text, icons, video, and any combination thereof.
  • the display unit 504 can include a display panel.
  • the display panel can be configured in the form of a Liquid Crystal Display (LCD), an Organic Light-Emitting Diode (OLED), or the like.
  • the touch-sensitive surface can cover the display panel, and when the touch-sensitive surface detects a touch operation on or near it, it is transmitted to the processor 508 to determine the type of the touch event, and then the processor 508 displays the type according to the type of the touch event. A corresponding visual output is provided on the panel.
  • the touch-sensitive surface and display panel are implemented as two separate components to perform input and input functions, in some embodiments, the touch-sensitive surface can be integrated with the display panel to implement input and output functions.
  • the terminal may also include at least one type of sensor 505, such as a light sensor, motion sensor, and other sensors.
  • the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel according to the brightness of the ambient light, and the proximity sensor may close the display panel and/or the backlight when the terminal moves to the ear.
  • the gravity acceleration sensor can detect the magnitude of acceleration in all directions (usually three axes). When it is stationary, it can detect the magnitude and direction of gravity.
  • the terminal can also be configured with gyroscopes, barometers, hygrometers, thermometers, infrared sensors and other sensors, no longer Narration.
  • the audio circuit 506, the speaker, and the microphone provide an audio interface between the user and the terminal.
  • the audio circuit 506 can transmit the converted electrical signal of the audio data to the speaker, and convert it into a sound signal output by the speaker; on the other hand, the microphone converts the collected sound signal into an electrical signal, which is received by the audio circuit 506 and converted.
  • the audio data is then processed by the audio data output processor 508, sent via RF circuitry 501 to, for example, another terminal, or the audio data is output to memory 502 for further processing.
  • the audio circuit 506 may also include an earbud jack to provide communication between the peripheral earphone and the terminal.
  • WiFi is a short-range wireless transmission technology.
  • the terminal can help users to send and receive emails, browse web pages, and access streaming media through the WiFi module 507. It provides wireless broadband Internet access for users.
  • FIG. 5 shows the WiFi module 507, it can be understood that it does not belong to the necessary configuration of the terminal, and may be omitted as needed within the scope of not changing the essence of the application.
  • Processor 508 is the control center of the terminal, which connects various portions of the entire handset using various interfaces and lines, by executing or executing software programs and/or modules stored in memory 502, and invoking data stored in memory 502, executing The various functions of the terminal and processing data to monitor the mobile phone as a whole.
  • the processor 508 may include one or more processing cores; in some embodiments of the present application, the processor 508 may integrate an application processor and a modem processor, where the application processor primarily processes The operating system, user interface, applications, etc., the modem processor primarily handles wireless communications. It will be appreciated that the above described modem processor may also not be integrated into the processor 508.
  • the terminal also includes a power source 509 (such as a battery) for powering various components.
  • the power source can be logically coupled to the processor 508 through a power management system to manage charging, discharging, and power consumption through the power management system. Management and other functions.
  • the power supply 509 may also include any one or more of a DC or AC power source, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and the like.
  • the terminal may further include a camera, a Bluetooth module, and the like, and details are not described herein again.
  • the processor 508 in the terminal loads the executable file corresponding to the process of one or more applications into the memory 502 according to the following instruction, and is stored in the memory by the processor 508.
  • the application in 502 to implement various functions:
  • the background color of the corresponding tab page results in a colored tab page; the page and the color tab page are displayed in the graphical interface.
  • the background color of the tab may be set in various ways.
  • the background color of the tab may be set in the content of the tab. Parameters, and then set the tab background color by assigning a value to the tab background color parameter, or you can also set the link address of the tab background color, such as a URL to set the background color of the tab, and so on.
  • the link address of the background color of the tab may be set by the website where each page is located (that is, by way of fixing the default URL of the rule), or may be set in the content of the page such as the content of the webpage.
  • the specific composition factor of the link address may be determined according to the needs of the actual application, for example, a domain name + a specific path (such as tab-background-color), and the like.
  • the icon of the page can be determined (favicon), then the main color of the icon is extracted, the main color of the page is calculated according to the main color of the icon, and the like.
  • the icon of the page, that is, favicon is generally displayed on the left side of the tab page, and can also be displayed in the bookmark and history.
  • the main color of the icon can be extracted in various ways.
  • the main color can be extracted in the proportion of the number of pixels, and then the main color of the page is calculated by using a preset algorithm, etc., wherein different The algorithm may get different page main tones, so I won't go into details here.
  • the processor 508 can also execute instructions of the following functions:
  • the background color of the color tab displayed in the graphical interface can be changed to a preset color.
  • the processor 508 can also execute instructions of the following functions:
  • the tab of the page in the graphical interface is selected, the tab of the page in the graphical interface is replaced with the colored tab.
  • an interface for dynamically setting the background color of the tab page may be provided in the graphical interface. If the background color of the tab page needs to be set, the corresponding interface may be invoked. Realize the setting of the tab background color. That is, the processor 508 can also execute instructions of the following functions:
  • the setting request carries information such as a color to be set, and the color to be set is used as the background color of the tab page of the page.
  • the preset interface can be set according to the requirements of the actual application, and details are not described herein again.
  • the terminal of the embodiment acquires the corresponding page according to the page access request, and detects whether the page background color of the tab has been set, and if so, Then, according to the background color of the tab page, the background color of the tab page corresponding to the page is drawn to obtain a color tab page. Otherwise, if not set, the main color of the page is extracted, and the background of the tab page corresponding to the page is drawn according to the main color tone.
  • the background color can be flexibly set for the tab according to different situations, for example, when a preset tab is detected In the background color, the preset background color of the tab is used as the background color of the tab, and when the background color of the tab is not set, the main color of the extracted page is used as the background color of the tab, and so on, Therefore, it can be avoided that some pages are not easy to extract the main color, such as the website icon contains a plurality of different colors that are the same or close, or the main color of the icon of the website is inconsistent with the main color of the website content. Errors, even the occurrence of failures, are helpful to improve recognition efficiency and recognition.
  • the solution not only helps the user to identify, but also facilitates the user to view and operate. Moreover, the recognition efficiency, the recognition effect, and the recognition and dissemination of information in the tab can be improved.
  • the program may be stored in a computer readable storage medium, and the storage medium may include: Read Only Memory (ROM), Random Access Memory (RAM), disk or optical disk.
  • ROM Read Only Memory
  • RAM Random Access Memory

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

一种图形界面中标签页的处理方法和装置,其中方法包括:在接收到用户通过图形界面触发的页面访问请求时(101),根据该页面访问请求获取相应的页面(102),并检测该页面是否已设置标签页背景色(103),若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页(104),若未设置,则提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页(105),然后,在该图形界面中显示该页面和彩色标签页;该方案不仅有助用户对标签页进行辨识,方便用户进行查看和操作,而且也可以提高标签页中信息的识别度和传播性。

Description

图形界面中标签页的处理方法和装置 技术领域
本申请涉及通信技术领域,具体涉及一种图形界面中标签页的处理方法和装置。
发明背景
图形界面,也称为图形用户接口(GUI,Graphical User Interface),是指采用图形方式显示的计算机操作用户界面,而浏览器,便是其中一种。所谓浏览器,是指可以显示网页服务器或者文件***的超级文本标记语言(HTML,Hyper Text Mark-up Language)文件内容,并让用户与这些文件交互的一种软件。
为了便于用户操作,目前的浏览器多数会采用多标签页(tab)的方式来对各个网页或文件进行展示,其中,标签页主要位于浏览器的标签栏。作为标签页的容器,标签栏主要用于管理用户打开的所有网页,是用户操作比较频繁的区域之一。一般的,一个标签页会对应于一个打开的网页或文件,且标签页中一般会显示网站图标(favicon)和网站标题(或文件标题),当用户需要浏览某个网页或文件时,便可以点击相应的标签页,以打开相应的网页或文件,从而实现在同一浏览器中管理多个打开网页的目的。
发明内容
本申请实施例提供一种图形界面中标签页的处理方法和装置,可以提高标签页的辨识度,在方便用户操作的同时,提高标签页中信息的识别度和传播性。
本申请实施例提供一种图形界面中标签页的处理方法,包括:
接收用户通过图形界面触发的页面访问请求;
根据所述页面访问请求获取相应的页面;
检测所述页面是否已设置标签页背景色;
若已设置,则根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
若未设置,则提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
在所述图形界面中显示所述页面和彩色标签页。
相应的,本申请实施例还提供一种图形界面中标签页的处理装置,包括:
接收单元,用于接收用户通过图形界面触发的页面访问请求;
获取单元,用于根据所述页面访问请求获取相应的页面;
检测单元,用于检测所述页面是否已设置标签页背景色;
第一绘制单元,用于在检测单元确定已设置标签页背景色时,根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
第二绘制单元,用于在检测单元确定未设置标签页背景色时,提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
显示单元,用于在所述图形界面中显示所述页面和彩色标签页。
本申请实施例还提供了一种图形界面中标签页的处理装置,包括:处理器,与所述处理器连接的存储器;所述存储器中存储有机器可读指令,所述处理器执行所述机器可读指令以执行以下操作行以下操作:
接收用户通过图形界面触发的页面访问请求;
根据所述页面访问请求获取相应的页面;
检测所述页面是否已设置标签页背景色;
若已设置,则根据所述标签页背景色绘制所述页面对应的标签页的 背景颜色,得到彩色标签页;
若未设置,则提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
在所述图形界面中显示所述页面和彩色标签页。
本申请实施例还提供了一种非易失性计算机可读存储介质,所述存储介质中存储有机器可读指令,所述机器可读指令可以有处理器执行以完成以下操作:
接收用户通过图形界面触发的页面访问请求;
根据所述页面访问请求获取相应的页面;
检测所述页面是否已设置标签页背景色;
若已设置,则根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
若未设置,则提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
在所述图形界面中显示所述页面和彩色标签页。
本申请实施例采用在接收到用户通过图形界面触发的页面访问请求时,根据该页面访问请求获取相应的页面,并检测该页面是否已设置标签页背景色,若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页,否则,若未设置,则提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页,然后,在该图形界面中显示该页面和彩色标签页;由于在该方案中,可以为不同页面的标签页设置不同的背景色,因此,大大提高了标签页的辨识度,有利于各个标签页之间进行区分;也就是说,采用该方案,不仅有助用户进行辨识,方便用户进行查看和操作,而且,也可以提高标签页中信息的识别度和传播性。
附图简要说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本申请实施例提供的图形界面中标签页的处理方法的流程图;
图2是本申请实施例提供的图形界面中标签页的处理方法的另一流程图;
图3a是本申请实施例提供的图形界面中标签页的处理方法的另一流程图;
图3b是本申请实施例提供的图形界面浏览器中标签页的示意图;
图3c是本申请实施例提供的图形界面浏览器中标签页的另一示意图;
图4a是本申请实施例提供的图形界面中标签页的处理装置的结构示意图;
图4b是本申请实施例提供的图形界面中标签页的处理装置的另一结构示意图;
图5是本申请实施例提供的终端的结构示意图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
由于在同一个浏览器中可能同时存在多个标签页,而这些标签页又 极为相似,因此,用户在浏览和操作时可能会存在难以区分这多个标签页的情况,即这些标签页的辨识度并不高,这不仅不利于用户操作,而且,也大大影响标签页中信息的识别度和传播性。
本申请实施例提供一种图形界面中标签页的处理方法和装置。根据本申请实施例提供的方案,接收用户通过图形界面触发的页面访问请求;根据该页面访问请求获取相应的页面;检测该页面是否已设置标签页背景色;若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页;若未设置,则提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页;在该图形界面中显示该页面和彩色标签页。在该方案中,可以为不同页面的标签页设置不同的背景色,因此,大大提高了标签页的辨识度,有利于各个标签页之间进行区分;也就是说,采用该方案,不仅有助用户进行辨识,方便用户进行查看和操作,而且,也可以提高标签页中信息的识别度和传播性。
在本申请实施例中,所述页面主色调是指页面在颜色外观上的基本倾向。虽然页面中可以使用了多种颜色,但是在总体上呈现出一种倾向,例如,偏蓝或偏红。这种色彩外观上的基本倾向就是所述页面的主色调。
以下将对本申请实施例提供的方法和装置分别进行详细说明。
图1是本申请实施例提供的图形界面中标签页的处理方法的流程图。本实施例将从图形界面中标签页的处理装置的角度进行描述,该图形界面中标签页的处理装置具体可以集成在终端等设备中,也可以以软体的形式安装在终端等设备中,该终端具体可以为手机、平板电脑、笔记本电脑或个人计算机(PC,Personal Computer)等设备。
如图1所示,该图形界面中标签页的处理方法的具体流程可以如下:
101、接收用户通过图形界面触发的页面访问请求。
例如,具体可以接收用户通过图形界面中的地址栏输入的链接地址,来触发该页面访问请求;或者,也可以接收用户通过点击图形界面中的 链接接口或触发键来触发该页面访问请求,等等,在此不再赘述。
其中,该页面访问请求中可以携带所需要访问的页面的地址等信息。
其中,该图形界面具体可以为浏览器,或其他用于显示网页服务器或者文件***的HTML文件内容,并可以让用户与这些文件进行交互的其他应用。为了描述方便,在本申请实施例中,将均以浏览器为例进行说明。
102、根据该页面访问请求获取相应的页面。
例如,可以根据该页面访问请求中所携带的页面的地址向对应的网站服务器发送页面访问请求,接收该网站服务器根据该页面访问请求返回的网页。
又例如,可以根据该页面访问请求中所携带的页面的地址向对应的设备发送页面访问请求,接收该设备根据该页面访问请求返回的文件,比如图片或视频,等等。
103、检测该页面是否已设置标签页背景色,若已设置标签页背景色,则执行步骤104,若未设置标签页背景色,则执行步骤105。
其中,检测的方式可以有多种,具体可以根据标签页背景色的设置方式而定,而标签页背景色的设置方式同样可以有多种,比如,可以在页面的内容中设置标签页背景色参数,然后通过对该标签页背景色参数赋值来设置标签页背景色,或者,还可以设置标签页背景色的链接地址,如统一资源***(URL,Uniform Resource Locator)等来设置该标签页背景色,等等。
例如,以上述两种标签页背景色的设置方式为例,则对应的检测方式具体可以如下:
(1)第一种方式;
获取该页面的内容,其中,该页面的内容中包括标签页背景色参数,确定该标签页背景色参数的值是否为预设值;若是,则确定已设置标签页背景色,并根据该预设值确定标签页背景色;若否,则确定未设置标 签页背景色。
其中,页面的内容一般可以包括HTML文件和层叠样式表(CSS,Cascading Style Sheet)文件,其中,CSS的相关信息也可内嵌到HTML文件中,因此,可以通过解析页面的HTML文件和CSS文件来获取页面的内容。
其中,预设值可以根据实际应用的需求而定,可以是一个数值,也可以是若干个数值,还可以是一个或若干个数值的范围,在此不再赘述。
(2)第二种方式;
确定该页面是否存在对应的标签页背景色的链接地址,若是,则确定已设置标签页背景色,并根据该链接地址获取标签页背景色;若否,则确定未设置标签页背景色。
其中,该标签页背景色的链接地址可以由各个页面所在的网站进行设置(即可以通过固定规则的默认URL的方式),也可以在页面内容如网页内容中进行设置。该链接地址的具体组成因素可以根据实际应用的需求而定,比如,可采用域名+特定路径(如tab-background-color)的方式,等等。
104、在确定已设置标签页背景色时,根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页。
需说明的是,这里本发明实施例的彩色标签页中的“彩色”除了包括传统意义上的“彩色”所对应的颜色之外,也包括白色、灰色、黑色等黑白灰色系中的各种颜色,甚至还可以包括“透明”,即这里的彩色标签页指的是“根据标签页背景色绘制后的标签页”,并不是指标签页的背景颜色为“彩色”。
105、在确定未设置标签页背景色时,提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页。
其中,提取该页面的主色调的方式可以有多种,比如,可以确定该页面的图标(favicon),然后提取该图标的主色调,根据该图标的主色 调计算页面的主色调,等等。其中,页面的图标,即favicon一般在标签页的左侧显示,也可在书签,历史记录中显示。
需说明的是,提取图标的主色调的方式可以有多种,比如,可以以像素数量占比的方式来提取主色调,然后采用预设算法来计算该页面的主色调,等等,其中,不同的算法可能会得到不同的页面主色调,在此不再赘述。
106、在该图形界面中显示该页面和彩色标签页。
例如,具体可以在图形界面中的页面显示区域显示页面的内容,并在标签栏中显示该彩色标签页;其中,标签栏指的是标签页的容器,用于显示和管理标签页的区域,通常位于图形界面如浏览器的顶部。
在本申请一些实施例中,还可以设置只有当该页面被激活,比如用户点击该页面对应的标签,以浏览该页面时,才将该页面的标签页显示为对应的彩色标签页,否则,该页面的标签页可以显示为普通标签页,所谓普通标签页指的是与其他标签页不具有背景色差异的标签页,其中,普通标签页的背景颜色也可以根据实际应用的需求进行预设。即在步骤“在图形界面中显示该页面和彩色标签页(即步骤106)”之后,该图形界面中标签页的处理方法还可以包括:
步骤107,当该图形界面中新建标签页或其他标签页被选中时,可以将页面在图形界面中所显示的彩色标签页的背景色更换为预设颜色。
此后,若该页面图形界面中的标签页再次被选中,比如,用户点击了该页面的标签页,则可以将该页面在图形界面中的标签页再次更换为该彩色标签页,以作突出显示,表示该彩色标签页所对应的页面为当前用户正在浏览的页面,等等。即在步骤107“将页面在图形界面中所显示的彩色标签页的背景色更换为预设颜色”之后,该图形界面中标签页的处理方法还可以包括:
步骤108,当该页面在图形界面中的标签页被选中时,将该页面在图形界面中的标签页更换为所述彩色标签页。
在本申请一些实施例中,为了便于网页对标签页背景色进行设置,还可以在图形界面中提供动态设置标签页背景色的接口,若需要设置标签页背景色,则调用相应的接口即可实现标签页背景色的设定。即该图形界面中标签页的处理方法还可以包括:
设置该页面的标签页背景色。图2为本申请实施例提供的一种图形界面中标签页的处理方法的流程图。如图2所示,该方法包括以下操作。步骤201,接收用户通过图形界面触发的页面访问请求。
步骤202,根据该页面访问请求获取相应的页面。
在本申请实施例中,步骤201~202分别与图1所示的步骤101~102相同,在此不再赘述。
步骤203,绘制该页面对应的标签页的背景颜色。
在本步骤中,在绘制该页面对应的标签页的背景颜色时,可以提取该页面的主色调,然后根据该主色调绘制该页面对应的标签页的背景颜色。或者,也可以将该页面对应的标签页的背景颜色绘制为普通标签页的背景颜色,即与其他标签页不具有背景颜色差异。或者,也可以是根据从网页内容或者设定URL中获取的标签页背景色,进行绘制。
步骤204,接收网页通过该图形界面中的预设接口输入的标签页背景色的设置请求,其中,该设置请求携带需要设置的颜色等信息,将该需要设置的颜色作为该页面的标签页背景色,重新绘制标签页的背景颜色。
其中,该预设的接口可以根据实际应用的需求进行设置,在此不再赘述。
由上可知,本实施例采用在接收到用户通过图形界面触发的页面访问请求时,根据该页面访问请求获取相应的页面,并检测该页面是否已设置标签页背景色,若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页,否则,若未设置,则提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到 彩色标签页,然后,在该图形界面中显示该页面和彩色标签页;由于在该方案中,可以为不同页面的标签页设置不同的背景色,使标签页进一步凸显网站的品牌信息,因此,大大提高了标签页的辨识度,有利于各个标签页之间进行区分。而且,由于在该方案中,可以根据不同的情况灵活地为标签页设置背景色,比如,在检测到有预先设置的标签页背景色时,采用该预先设置的标签页背景色作为标签页的背景颜色,而在检测到没有设置的标签页背景色时,则采用提取页面的主色调来作为标签页背景色,等等,因此,可以避免某些页面不易提取主色调,如网站的图标中包含多种占比相同或接近的不同颜色,或网站的图标的主色调与网站内容的主色调不一致等场景下所导致的识别错误,甚至识别失败的情况的发生,有利于提高识别效率和识别效果。
总而言之,采用该方案,不仅有助用户进行辨识,方便用户进行查看和操作,而且,也可以提高识别效率、识别效果、以及提高标签页中信息的识别度和传播性。
图3a是本申请实施例提供的图形界面中标签页的处理方法的另一流程图。在图3a所示的实施例中,将以该图形界面具体为浏览器,且该图形界面中标签页的处理装置具体集成在终端中为例进行说明。其中,该图形界面中标签页的处理装置集成在终端中的方式可以有多种,例如,可以以插件的方式安装在终端的浏览器中,或者,也可以以应用的形式安装在终端中,等等,在此不作赘述。需说明的是,为了便于描述,在本实施例中,仅仅以该图形界面中标签页的处理装置集成在终端中为例进行说明,而不对其具体的集成方式进行限定。
参见图3a,一种图形界面中标签页的处理方法,具体流程可以如下:
301、终端接收用户通过浏览器触发的页面访问请求,其中,该页面访问请求中可以携带所需要访问的页面的地址等信息。
例如,用户可以在该终端的浏览器的地址栏中输入所需要访问的网站的链接地址,这样,便可以根据该需要访问的网站的链接地址生成页 面访问请求;或者,用户还可以通过点击浏览器中的某个网站的链接地址来触发该页面访问请求,等等。
302、终端根据该页面访问请求中所携带的页面的地址向对应的网站服务器发送该页面访问请求,并接收该网站服务器根据该页面访问请求返回的页面。
303、终端检测该页面是否已设置标签页背景色,若已设置标签页背景色,则执行步骤304,若未设置标签页背景色,则执行步骤305。
其中,检测的方式可以有多种,具体可以根据标签页背景色的设置方式而定,而标签页背景色的设置方式同样可以有多种,比如,可以在页面的内容中设置标签页背景色参数,然后通过对该标签页背景色参数赋值来设置标签页背景色,或者,还可以设置标签页背景色的链接地址,如URL等来设置该标签页背景色,等等。
例如,以上述两种标签页背景色的设置方式为例,则对应的检测方式具体可以如下:
(1)第一种方式;
获取该页面的内容,其中,该页面的内容中包括标签页背景色参数,确定该标签页背景色参数的值是否为预设值;若是,则确定已设置标签页背景色,并根据该预设值确定标签页背景色;若否,则确定未设置标签页背景色。
其中,页面的内容一般可以包括HTML文件和CSS文件,其中,CSS的相关信息也可内嵌到HTML文件中,因此,可以通过解析页面的HTML文件和CSS文件来获取页面的内容。
比如,可以在CCS文件中,设置浏览器的标签页的相关信息,如在CSS信息中添加一个标签页标识,并通过标签页背景色参数“background-color”为标签页的背景色赋值,浏览器可以通过读取该参数来确定相应页面的标签页背景色,然后根据该标签页背景色绘制该页面的标签页的背景颜色,如以下示例代码,便可以将浏览器的标签页的背 景色设置为了灰色,等等。
Figure PCTCN2016101624-appb-000001
其中,预设值可以根据实际应用的需求而定,可以是一个数值,也可以是若干个数值,还可以是一个或若干个数值的范围,在此不再赘述。
(2)第二种方式;
确定该页面是否存在对应的标签页背景色的链接地址,若是,则确定已设置标签页背景色,并根据该链接地址获取标签页背景色;若否,则确定未设置标签页背景色。
其中,该标签页背景色的链接地址可以由各个页面所在的网站进行设置(即可以通过固定规则的默认URL的方式),也可以在页面内容如网页内容中进行设置。该链接地址的具体组成因素可以根据实际应用的需求而定,比如,可采用域名+特定路径(如tab-background-color)的方式,等等。
例如,以采用域名+特定路径,且该链接地址具体为URL为例,则网站“www.123456789.com”所设置的标签页背景色的默认URL可以为:
http://www.123456789.com/tab-background-color。
如果网页并不使用该默认URL,则可以在HTML文件中设置该URL。如在“www.123456789.com”的网页中设置了如下代码:
<link rel=″tab-background-color″href=″/tab-background-color2″/>
获取标签页背景色的URL为:
http://www.123456789.com/tab-background-color2。
304、在确定已设置标签页背景色时,终端根据该标签页背景色绘 制该页面对应的标签页的背景颜色,得到彩色标签页。
305、在确定未设置标签页背景色时,终端提取该页面的主色调,并根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页。
其中,提取该页面的主色调的方式可以有多种,比如,可以确定该页面的图标(favicon),然后以像素数量占比的方式提取该图标的主色调,并基于该图标的主色调,采用预设算法计算出该页面的主色调,等等。
306、终端在该浏览器中显示该页面和彩色标签页。
例如,具体可以在浏览器中的页面显示区域显示页面的内容,并在浏览器的标签栏中显示该彩色标签页,例如,参见图3b,在浏览器的标签栏310中包括A网站、B网站和C网站的标签页312~313,其中,A网站和B网站的标签页311~312的背景颜色为白色,C网站的标签页313的背景颜色为灰色,等等。
在本申请一些实施例中,还可以设置只有当该页面被激活,比如用户点击该页面对应的标签,以浏览该页面时,才将该页面的标签页显示为对应的彩色标签页,否则,该页面的标签页可以显示为普通标签页,比如,参见图3c,当B网站的标签页312被点击时,C网站的标签页313由彩色标签页(即灰色,参见图3b)变为普通标签页,比如白色背景的标签页,而B网站的标签页212则更换为彩色标签页,比如黑色的标签页,等等。
此后,若该页面图形界面中的标签页再次被选中,比如,用户再点击C网站的标签页313,则可以将C网站的标签页313再次更换为彩色标签页,即灰色背景的标签页,参见图3b。
在本申请一些实施例中,为了便于网页对标签页背景色进行设置,还可以在图形界面中提供动态设置标签页背景色的接口,若需要设置标签页背景色,则调用相应的接口即可实现标签页背景色的设定,即还可以执行步骤:
接收网页通过该浏览器中的预设接口输入的标签页背景色的设置请求,其中,该设置请求携带需要设置的颜色等信息,将该需要设置的颜色作为该页面的标签页背景色。
其中,浏览器提供的设置标签页背景色的接口一般由网页中的JavaScript调用。网页可根据自身内容的特点,选择合适的颜色值作为标签页的背景色。比如,若需要把标签页背景色设置为灰色,则可以设置如下代码:
qqbrowser.tab.setBackgroundColor(‘gray’)。
需说明的是,该设置标签页背景色的步骤与步骤301~306中任一步骤的执行可以不分先后,即可以随时对该标签页背景色进行设置,在此不再赘述。
由上可知,本实施例采用在接收到用户通过浏览器触发的页面访问请求时,根据该页面访问请求获取相应的页面,并检测该页面是否已设置标签页背景色,若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页,否则,若未设置,则提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页,然后,在该浏览器中显示该页面和彩色标签页;由于在该方案中,可以为不同页面的标签页设置不同的背景色,使标签页进一步凸显网站的品牌信息,因此,大大提高了标签页的辨识度,有利于各个标签页之间进行区分。而且,由于在该方案中,可以根据不同的情况灵活地为标签页设置背景色,比如,在检测到有预先设置的标签页背景色时,采用该预先设置的标签页背景色作为标签页的背景颜色,而在检测到没有设置的标签页背景色时,则采用提取页面的主色调来作为标签页背景色,等等,因此,可以避免某些页面不易提取主色调,如网站的图标中包含多种占比相同或接近的不同颜色,或网站的图标的主色调与网站内容的主色调不一致等场景下所导致的识别错误,甚至识别失败的情况的 发生,有利于提高识别效率和识别效果。
总而言之,采用该方案,不仅有助用户进行辨识,方便用户进行查看和操作,而且,也可以提高识别效率、识别效果、以及提高标签页中信息的识别度和传播性。
本申请实施例还提供一种图形界面中标签页的处理装置,如图4a所示,该图形界面中标签页的处理装置可以包括接收单元401、获取单元402、检测单元403、第一绘制单元404、第二绘制单元405、第二绘制单元405和显示单元406。
其中,接收单元401用于接收用户通过图形界面触发的页面访问请求。
例如,具体可以接收用户通过图形界面中的地址栏输入的链接地址,来触发该页面访问请求;或者,也可以接收用户通过点击图形界面中的链接接口或触发键来触发该页面访问请求,等等,在此不再赘述。
其中,该页面访问请求中可以携带所需要访问的页面的地址等信息。
其中,该图形界面具体可以为浏览器,或其他用于显示网页服务器或者文件***的HTML文件内容,并可以让用户与这些文件进行交互的其他应用。为了描述方便,在本申请实施例中,将均以浏览器为例进行说明。
获取单元402用于根据该页面访问请求获取相应的页面。
例如,获取单元402可以根据该页面访问请求中所携带的页面的地址向对应的网站服务器发送页面访问请求,并接收该网站服务器根据该页面访问请求返回的网页。
又例如,获取单元402可以根据该页面访问请求中所携带的页面的地址向对应的设备发送页面访问请求,并接收该设备根据该页面访问请求返回的文件,比如图片或视频,等等。
检测单元403用于检测该页面是否已设置标签页背景色。
其中,检测的方式可以有多种,具体可以根据标签页背景色的设置 方式而定,而标签页背景色的设置方式同样可以有多种,比如,可以在页面的内容中设置标签页背景色参数,然后通过对该标签页背景色参数赋值来设置标签页背景色,或者,还可以设置标签页背景色的链接地址,如URL等来设置该标签页背景色,等等。例如,具体可以如下:
检测单元403,具体可以用于获取该页面的内容,该页面的内容中包括标签页背景色参数;确定该标签页背景色参数的值是否为预设值;若是,则确定已设置标签页背景色,并根据该预设值确定标签页背景色;若否,则确定未设置标签页背景色。
其中,预设值可以根据实际应用的需求而定,可以是一个数值,也可以是若干个数值,还可以是一个或若干个数值的范围,在此不再赘述。
或者,检测单元403,具体可以用于确定该页面是否存在对应的标签页背景色的链接地址;若是,则确定已设置标签页背景色,并根据该链接地址获取标签页背景色;若否,则确定未设置标签页背景色。
其中,该标签页背景色的链接地址可以由各个页面所在的网站进行设置(即可以通过固定规则的默认URL的方式),也可以在页面内容如网页内容中进行设置。该链接地址的具体组成因素可以根据实际应用的需求而定,比如,可采用域名+特定路径(如tab-background-color)的方式,等等。
第一绘制单元404用于在检测单元确定已设置标签页背景色时,根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页。
第二绘制单元405用于在检测单元确定未设置标签页背景色时,提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页。
其中,提取该页面的主色调的方式可以有多种,比如,可以确定该页面的图标(favicon),然后提取该图标的主色调,根据该图标的主色调计算页面的主色调,等等,即:
第二绘制单元405,具体可以用于在检测单元确定未设置标签页背景色时,确定该页面的图标;提取该图标的主色调,并根据该图标的主色调计算该页面的主色调,根据该页面的主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页。
需说明的是,提取图标的主色调的方式可以有多种,比如,可以以像素数量占比的方式来提取主色调,然后采用预设算法来计算该页面的主色调,等等,其中,不同的算法可能会得到不同的页面主色调,在此不再赘述。
显示单元406用于在该图形界面中显示该页面和彩色标签页。
例如,显示单元406,具体可以用于在图形界面中的页面显示区域显示页面的内容,并在标签栏中显示该彩色标签页
在本申请一些实施例中,为了便于网页对标签页背景色进行设置,还可以在图形界面中提供动态设置标签页背景色的接口,若需要设置标签页背景色,则调用相应的接口即可实现标签页背景色的设定。即如图4b所示,该图形界面中标签页的处理装置还可以进一步包括设置单元407,用于设置该页面的标签页背景色。
在一些实施例中,该设置单元407可以用于接收网页通过该图形界面中的预设接口输入的标签页背景色的设置请求,该设置请求携带需要设置的颜色;将该需要设置的颜色作为该页面的标签页背景色。
其中,该预设的接口可以根据实际应用的需求进行设置,在此不再赘述。
在本申请一些实施例中,还可以设置只有当该页面被激活,比如用户点击该页面对应的标签,以浏览该页面时,才将该页面的标签页显示为对应的彩色标签页,否则,该页面的标签页可以显示为普通标签页,所谓普通标签页指的是与其他标签页不具有背景色差异的标签页,其中,普通标签页的背景颜色也可以根据实际应用的需求进行预设。即如图4b所示,该图形界面中标签页的处理装置还可以进一步包括更换单元408, 用于在该图形界面中新建标签页或其他标签页被选中时,可以将页面在图形界面中所显示的彩色标签页的背景色更换为预设颜色。
此后,若该页面图形界面中的标签页再次被选中,比如,用户点击了该页面的标签页,则可以将该页面在图形界面中的标签页再次更换为该彩色标签页,以作突出显示,表示该彩色标签页所对应的页面为当前用户正在浏览的页面,等等。即:
更换单元408,还用于在该页面在图形界面中的标签页被选中时,将该页面在图形界面中的标签页更换为所述彩色标签页。
具体实施时,以上各个单元可以作为独立的实体来实现,也可以进行任意组合,作为同一或若干个实体来实现,以上各个单元的具体实施可参见前面的方法实施例,在此不再赘述。
该图形界面中标签页的处理装置具体可以集成在终端等设备中,也可以以软体的形式安装在终端等设备中,该终端具体可以为手机、平板电脑、笔记本电脑或PC等设备。
由上可知,本实施例的图形界面中标签页的处理装置采用在接收到用户通过图形界面触发的页面访问请求时,由获取单元402根据该页面访问请求获取相应的页面,并由检测单元403检测该页面是否已设置标签页背景色,若已设置,则由第一绘制单元404根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页,否则,若未设置,则由第二绘制单元405提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页,然后,再由显示单元406在该图形界面中显示该页面和彩色标签页;由于在该方案中,可以为不同页面的标签页设置不同的背景色,使标签页进一步凸显网站的品牌信息,因此,大大提高了标签页的辨识度,有利于各个标签页之间进行区分。而且,由于在该方案中,可以根据不同的情况灵活地为标签页设置背景色,比如,在检测到有预先设置的标签页背景色时,采用该预先设置的标签页背景色作为标签页的背景颜色,而在检测到没有设置的标签 页背景色时,则采用提取页面的主色调来作为标签页背景色,等等,因此,可以避免某些页面不易提取主色调,如网站的图标中包含多种占比相同或接近的不同颜色,或网站的图标的主色调与网站内容的主色调不一致等场景下所导致的识别错误,甚至识别失败的情况的发生,有利于提高识别效率和识别效果。
总而言之,采用该方案,不仅有助用户进行辨识,方便用户进行查看和操作,而且,也可以提高识别效率、识别效果、以及提高标签页中信息的识别度和传播性。
相应的,本申请实施例还提供一种终端,如图5所示,该终端可以包括射频(RF,Radio Frequency)电路501、包括有一个或一个以上计算机可读存储介质的存储器502、输入单元503、显示单元504、传感器505、音频电路506、无线保真(WiFi,Wireless Fidelity)模块507、包括有一个或者一个以上处理核心的处理器508、以及电源509等部件。本领域技术人员可以理解,图5中示出的终端结构并不构成对终端的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。其中:
RF电路501可用于收发信息或通话过程中,信号的接收和发送,特别地,将基站的下行信息接收后,交由一个或者一个以上处理器508处理;另外,将涉及上行的数据发送给基站。通常,RF电路501包括但不限于天线、至少一个放大器、调谐器、一个或多个振荡器、用户身份模块(SIM,Subscriber Identity Module)卡、收发信机、耦合器、低噪声放大器(LNA,Low Noise Amplifier)、双工器等。此外,RF电路501还可以通过无线通信与网络和其他设备通信。所述无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯***(GSM,Global System of Mobile communication)、通用分组无线服务(GPRS,General Packet Radio Service)、码分多址(CDMA,Code Division Multiple Access)、宽带码分多址(WCDMA,Wideband Code Division Multiple Access)、长 期演进(LTE,Long Term Evolution)、电子邮件、短消息服务(SMS,Short Messaging Service)等。
存储器502可用于存储软件程序以及模块,处理器508通过运行存储在存储器502的软件程序以及模块,从而执行各种功能应用以及数据处理。存储器502可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作***、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据终端的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器502可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。相应地,存储器502还可以包括存储器控制器,以提供处理器508和输入单元503对存储器502的访问。
输入单元503可用于接收输入的数字或字符信息,以及产生与用户设置以及功能控制有关的键盘、鼠标、操作杆、光学或者轨迹球信号输入。具体地,在一个具体的实施例中,输入单元503可包括触敏表面以及其他输入设备。触敏表面,也称为触摸显示屏或者触控板,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触敏表面上或在触敏表面附近的操作),并根据预先设定的程式驱动相应的连接装置。在本申请一些实施例中,触敏表面可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器508,并能接收处理器508发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触敏表面。除了触敏表面,输入单元503还可以包括其他输入设备。具体地,其他输入设备可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种。
显示单元504可用于显示由用户输入的信息或提供给用户的信息以及终端的各种图形用户接口,这些图形用户接口可以由图形、文本、图标、视频和其任意组合来构成。显示单元504可包括显示面板,在本申请一些实施例中,可以采用液晶显示器(LCD,Liquid Crystal Display)、有机发光二极管(OLED,Organic Light-Emitting Diode)等形式来配置显示面板。进一步的,触敏表面可覆盖显示面板,当触敏表面检测到在其上或附近的触摸操作后,传送给处理器508以确定触摸事件的类型,随后处理器508根据触摸事件的类型在显示面板上提供相应的视觉输出。虽然在图5中,触敏表面与显示面板是作为两个独立的部件来实现输入和输入功能,但是在某些实施例中,可以将触敏表面与显示面板集成而实现输入和输出功能。
终端还可包括至少一种传感器505,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板的亮度,接近传感器可在终端移动到耳边时,关闭显示面板和/或背光。作为运动传感器的一种,重力加速度传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;至于终端还可配置的陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。
音频电路506、扬声器,传声器可提供用户与终端之间的音频接口。音频电路506可将接收到的音频数据转换后的电信号,传输到扬声器,由扬声器转换为声音信号输出;另一方面,传声器将收集的声音信号转换为电信号,由音频电路506接收后转换为音频数据,再将音频数据输出处理器508处理后,经RF电路501以发送给比如另一终端,或者将音频数据输出至存储器502以便进一步处理。音频电路506还可能包括耳塞插孔,以提供外设耳机与终端的通信。
WiFi属于短距离无线传输技术,终端通过WiFi模块507可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图5示出了WiFi模块507,但是可以理解的是,其并不属于终端的必须构成,完全可以根据需要在不改变申请的本质的范围内而省略。
处理器508是终端的控制中心,利用各种接口和线路连接整个手机的各个部分,通过运行或执行存储在存储器502内的软件程序和/或模块,以及调用存储在存储器502内的数据,执行终端的各种功能和处理数据,从而对手机进行整体监控。在本申请一些实施例中,处理器508可包括一个或多个处理核心;在本申请一些实施例中,处理器508可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作***、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器508中。
终端还包括给各个部件供电的电源509(比如电池),在本申请一些实施例中,电源可以通过电源管理***与处理器508逻辑相连,从而通过电源管理***实现管理充电、放电、以及功耗管理等功能。电源509还可以包括一个或一个以上的直流或交流电源、再充电***、电源故障检测电路、电源转换器或者逆变器、电源状态指示器等任意组件。
尽管未示出,终端还可以包括摄像头、蓝牙模块等,在此不再赘述。具体在本实施例中,终端中的处理器508会按照如下的指令,将一个或一个以上的应用程序的进程对应的可执行文件加载到存储器502中,并由处理器508来运行存储在存储器502中的应用程序,从而实现各种功能:
接收用户通过图形界面触发的页面访问请求;根据该页面访问请求获取相应的页面;检测该页面是否已设置标签页背景色;若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页;若未设置,则提取该页面的主色调,根据该主色调绘制该页面对 应的标签页的背景颜色,得到彩色标签页;在该图形界面中显示该页面和彩色标签页。
其中,检测的方式可以有多种,具体可以根据标签页背景色的设置方式而定,而标签页背景色的设置方式同样可以有多种,比如,可以在页面的内容中设置标签页背景色参数,然后通过对该标签页背景色参数赋值来设置标签页背景色,或者,还可以设置标签页背景色的链接地址,如URL等来设置该标签页背景色,等等。
其中,该标签页背景色的链接地址可以由各个页面所在的网站进行设置(即可以通过固定规则的默认URL的方式),也可以在页面内容如网页内容中进行设置。该链接地址的具体组成因素可以根据实际应用的需求而定,比如,可采用域名+特定路径(如tab-background-color)的方式,等等。
其中,提取该页面的主色调的方式可以有多种,比如,可以确定该页面的图标(favicon),然后提取该图标的主色调,根据该图标的主色调计算页面的主色调,等等。其中,页面的图标,即favicon一般在标签页的左侧显示,也可在书签,历史记录中显示。
同理,提取图标的主色调的方式也可以有多种,比如,可以以像素数量占比的方式来提取主色调,然后采用预设算法来计算该页面的主色调,等等,其中,不同的算法可能会得到不同的页面主色调,在此不再赘述。
在本申请一些实施例中,还可以设置只有当该页面被激活,比如用户点击该页面对应的标签,以浏览该页面时,才将该页面的标签页显示为对应的彩色标签页,否则,该页面的标签页可以显示为普通标签页,其中,普通标签页的背景颜色也可以根据实际应用的需求进行预设。即处理器508还可以执行如下功能的指令:
当该图形界面中新建标签页或其他标签页被选中时,可以将页面在图形界面中所显示的彩色标签页的背景色更换为预设颜色。
此后,若该页面图形界面中的标签页再次被选中,比如,用户点击了该页面的标签页,则可以将该页面在图形界面中的标签页再次更换为该彩色标签页,以作突出显示,表示该彩色标签页所对应的页面为当前用户正在浏览的页面,等等。即处理器508还可以执行如下功能的指令:
当该页面在图形界面中的标签页被选中时,将该页面在图形界面中的标签页更换为所述彩色标签页。
在本申请一些实施例中,为了便于网页对标签页背景色进行设置,还可以在图形界面中提供动态设置标签页背景色的接口,若需要设置标签页背景色,则调用相应的接口即可实现标签页背景色的设定。即处理器508还可以执行如下功能的指令:
设置该页面的标签页背景色。例如,具体可以如下:
接收网页通过该图形界面中的预设接口输入的标签页背景色的设置请求,其中,该设置请求携带需要设置的颜色等信息,将该需要设置的颜色作为该页面的标签页背景色。
其中,该预设的接口可以根据实际应用的需求进行设置,在此不再赘述。
以上各个操作的具体实施可参见前面的实施例,在此不再赘述。
由上可知,本实施例的终端采用在接收到用户通过图形界面触发的页面访问请求时,根据该页面访问请求获取相应的页面,并检测该页面是否已设置标签页背景色,若已设置,则根据该标签页背景色绘制该页面对应的标签页的背景颜色,得到彩色标签页,否则,若未设置,则提取该页面的主色调,根据该主色调绘制该页面对应的标签页的背景颜色,得到彩色标签页,然后,在该图形界面中显示该页面和彩色标签页;由于在该方案中,可以为不同页面的标签页设置不同的背景色,使标签页进一步凸显网站的品牌信息,因此,大大提高了标签页的辨识度,有利于各个标签页之间进行区分。而且,由于在该方案中,可以根据不同的情况灵活地为标签页设置背景色,比如,在检测到有预先设置的标签页 背景色时,采用该预先设置的标签页背景色作为标签页的背景颜色,而在检测到没有设置的标签页背景色时,则采用提取页面的主色调来作为标签页背景色,等等,因此,可以避免某些页面不易提取主色调,如网站的图标中包含多种占比相同或接近的不同颜色,或网站的图标的主色调与网站内容的主色调不一致等场景下所导致的识别错误,甚至识别失败的情况的发生,有利于提高识别效率和识别效果。
总而言之,采用该方案,不仅有助用户进行辨识,方便用户进行查看和操作,而且,也可以提高识别效率、识别效果、以及提高标签页中信息的识别度和传播性。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:只读存储器(ROM,Read Only Memory)、随机存取记忆体(RAM,Random Access Memory)、磁盘或光盘等。
以上对本申请实施例所提供的一种图形界面中标签页的处理方法和装置进行了详细介绍,本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。

Claims (18)

  1. 一种图形界面中标签页的处理方法,其特征在于,包括:
    接收用户通过图形界面触发的页面访问请求;
    根据所述页面访问请求获取相应的页面;
    检测所述页面是否已设置标签页背景色;
    若已设置,则根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    若未设置,则提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    在所述图形界面中显示所述页面和所述彩色标签页。
  2. 根据权利要求1所述的方法,其特征在于,所述检测所述页面是否已设置标签页背景色,包括:
    获取所述页面的内容,所述页面的内容中包括标签页背景色参数;
    确定所述标签页背景色参数的值是否为预设值;
    若是,则确定已设置标签页背景色,并根据所述预设值确定标签页背景色;
    若否,则确定未设置标签页背景色。
  3. 根据权利要求1所述的方法,其特征在于,所述检测所述页面是否已设置标签页背景色,包括:
    确定所述页面是否存在对应的标签页背景色的链接地址;
    若是,则确定已设置标签页背景色,并根据所述链接地址获取标签页背景色;
    若否,则确定未设置标签页背景色。
  4. 根据权利要求1至3任一项所述的方法,其特征在于,所述提取所述页面的主色调,包括:
    确定所述页面的图标;
    提取所述图标的主色调,并根据该图标的主色调计算所述页面的主 色调。
  5. 根据权利要求1至3任一项所述的方法,其特征在于,还包括:
    设置所述页面的标签页背景色。
  6. 根据权利要求5所述的方法,其特征在于,所述设置所述页面的标签页背景色,包括:
    接收所述页面通过所述图形界面中的预设接口输入的标签页背景色的设置请求,所述设置请求携带需要设置的颜色;
    将所述需要设置的颜色作为所述页面的标签页背景色。
  7. 根据权利要求1至3任一项所述的方法,其特征在于,所述在所述图形界面中显示所述页面和彩色标签页之后,还包括:
    当所述图形界面中新建标签页或其他标签页被选中时,将所述页面在图形界面中所显示的彩色标签页的背景色更换为预设颜色。
  8. 根据权利要求7所述的方法,其特征在于,所述将所述页面在图形界面中的标签页的背景色更换为预设颜色之后,还包括:
    当所述页面在图形界面中的标签页被选中时,将所述页面在图形界面中的标签页更换为所述彩色标签页。
  9. 一种图形界面中标签页的处理装置,其特征在于,包括:
    接收单元,用于接收用户通过图形界面触发的页面访问请求;
    获取单元,用于根据所述页面访问请求获取相应的页面;
    检测单元,用于检测所述页面是否已设置标签页背景色;
    第一绘制单元,用于在检测单元确定已设置标签页背景色时,根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    第二绘制单元,用于在检测单元确定未设置标签页背景色时,提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    显示单元,用于在所述图形界面中显示所述页面和彩色标签页。
  10. 根据权利要求9所述的装置,其特征在于,
    所述检测单元,具体用于获取所述页面的内容,所述页面的内容中包括标签页背景色参数;确定所述标签页背景色参数的值是否为预设值;若是,则确定已设置标签页背景色,并根据所述预设值确定标签页背景色;若否,则确定未设置标签页背景色。
  11. 根据权利要求9所述的装置,其特征在于,
    所述检测单元,具体用于确定所述页面是否存在对应的标签页背景色的链接地址;若是,则确定已设置标签页背景色,并根据所述链接地址获取标签页背景色;若否,则确定未设置标签页背景色。
  12. 根据权利要求9至11任一项所述的装置,其特征在于,
    第二绘制单元,具体用于在检测单元确定未设置标签页背景色时,确定所述页面的图标;提取所述图标的主色调,并根据该图标的主色调计算所述页面的主色调,根据所述页面的主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页。
  13. 根据权利要求9至11任一项所述的装置,其特征在于,还包括设置单元;
    所述设置单元,用于设置所述页面的标签页背景色。
  14. 根据权利要求13所述的装置,其特征在于,
    所述设置单元,具体用于接收所述页面通过所述图形界面中的预设接口输入的标签页背景色的设置请求,所述设置请求携带需要设置的颜色;将所述需要设置的颜色作为所述页面的标签页背景色。
  15. 根据权利要求9至11任一项所述的装置,其特征在于,还包括更换单元;
    所述更换单元,用于在所述图形界面中新建标签页或其他标签页被点击时,将所述彩色标签页的背景色更换为预设颜色。
  16. 根据权利要求9至11任一项所述的装置,其特征在于,
    所述更换单元,还用于在所述页面在图形界面中的标签页被选中时, 将所述页面在图形界面中的标签页更换为所述彩色标签页。
  17. 一种图形界面中标签页的处理装置,其特征在于,包括:处理器,与所述处理器连接的存储器;所述存储器中存储有机器可读指令,所述处理器执行所述机器可读指令以执行以下操作行以下操作:
    接收用户通过图形界面触发的页面访问请求;
    根据所述页面访问请求获取相应的页面;
    检测所述页面是否已设置标签页背景色;
    若已设置,则根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    若未设置,则提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    在所述图形界面中显示所述页面和彩色标签页。
  18. 一种非易失性计算机可读存储介质,其特征在于,所述存储介质中存储有机器可读指令,所述机器可读指令可以有处理器执行以完成以下操作:
    接收用户通过图形界面触发的页面访问请求;
    根据所述页面访问请求获取相应的页面;
    检测所述页面是否已设置标签页背景色;
    若已设置,则根据所述标签页背景色绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    若未设置,则提取所述页面的主色调,根据所述主色调绘制所述页面对应的标签页的背景颜色,得到彩色标签页;
    在所述图形界面中显示所述页面和彩色标签页。
PCT/CN2016/101624 2015-11-18 2016-10-10 图形界面中标签页的处理方法和装置 WO2017084452A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US15/715,628 US10109079B2 (en) 2015-11-18 2017-09-26 Method and apparatus for processing tab in graphical interface

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510796799.4 2015-11-18
CN201510796799.4A CN106708496B (zh) 2015-11-18 2015-11-18 图形界面中标签页的处理方法和装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US15/715,628 Continuation US10109079B2 (en) 2015-11-18 2017-09-26 Method and apparatus for processing tab in graphical interface

Publications (1)

Publication Number Publication Date
WO2017084452A1 true WO2017084452A1 (zh) 2017-05-26

Family

ID=58717322

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/101624 WO2017084452A1 (zh) 2015-11-18 2016-10-10 图形界面中标签页的处理方法和装置

Country Status (3)

Country Link
US (1) US10109079B2 (zh)
CN (1) CN106708496B (zh)
WO (1) WO2017084452A1 (zh)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10712912B2 (en) * 2017-03-14 2020-07-14 Vmware, Inc. Generating contextual cues linking related browser tabs
CN107315588B (zh) * 2017-06-26 2020-07-14 深圳传音通讯有限公司 Tab页样式应用界面的背景显示方法和装置
CN110673904B (zh) * 2018-07-03 2023-08-25 淘宝(中国)软件有限公司 主题色彩处理、展示页面生成的方法、装置及设备
CN110109664B (zh) * 2018-10-18 2023-03-03 神思(山东)医疗信息技术有限责任公司 一种页面集成***及方法
KR20200101187A (ko) * 2019-02-19 2020-08-27 삼성전자주식회사 전자 장치에서 사용자 입력을 위한 피드백 제공 장치 및 방법
CN110210532B (zh) * 2019-05-15 2022-03-01 北京字节跳动网络技术有限公司 背景色生成方法、装置及电子设备
CN110580319A (zh) * 2019-07-18 2019-12-17 北京小米移动软件有限公司 网页标签的显示方法、装置、电子设备及存储介质
KR102422221B1 (ko) * 2020-03-30 2022-07-19 라인플러스 주식회사 이미지 내 텍스트 색상과 배경 색상을 추출하여 제공하는 방법, 시스템, 및 컴퓨터 프로그램
CN115309306A (zh) * 2021-05-08 2022-11-08 Oppo广东移动通信有限公司 标签控制方法、装置、终端设备及存储介质
CN113722030B (zh) * 2021-06-10 2022-12-16 荣耀终端有限公司 一种显示方法、电子设备及计算机存储介质
CN113407082B (zh) * 2021-06-23 2023-09-12 青岛海信移动通信技术有限公司 应用于终端设备的字体颜色控制方法及相关装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103164519A (zh) * 2013-03-08 2013-06-19 优视科技有限公司 调整工具栏色调的方法及装置
CN103198121A (zh) * 2013-04-02 2013-07-10 北京奇虎科技有限公司 浏览器设置背景的方法及浏览器
CN103440326A (zh) * 2013-09-02 2013-12-11 百度在线网络技术(北京)有限公司 提供呈现信息的方法和装置
US20140101539A1 (en) * 2011-08-26 2014-04-10 Tencent Technology (Shenzhen) Company Limited Website presenting method and browser

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020161803A1 (en) * 2001-03-15 2002-10-31 Imation Corp. Web page color accuracy
US20030128235A1 (en) * 2002-01-10 2003-07-10 International Business Machines Corporation System for associating graphics frames with events and method therefor
US7197702B2 (en) * 2003-06-13 2007-03-27 Microsoft Corporation Web page rendering mechanism using external programmatic themes
US7587679B1 (en) * 2004-08-25 2009-09-08 Adobe Systems Incorporated System and method for displaying elements using a single tab
US20080120570A1 (en) * 2006-11-22 2008-05-22 Bluetie, Inc. Methods for managing windows within an internet environment and systems thereof
US8095883B2 (en) * 2007-08-03 2012-01-10 International Business Machines Corporation Indicating the default value for a property to enhance user feedback
US20090187481A1 (en) * 2008-01-22 2009-07-23 Bonzi Joe R Automatic generation of electronic advertising messages
US20100076863A1 (en) * 2008-09-22 2010-03-25 Golomb Vitaly M Hosting platform
CN103488646B (zh) * 2012-06-13 2017-11-14 腾讯科技(深圳)有限公司 一种移动终端浏览器弱光源下浏览网页的方法及装置
CN103593348B (zh) * 2012-08-14 2019-02-19 腾讯科技(深圳)有限公司 浏览器标签的显示方法及装置
CN103399764A (zh) * 2013-07-24 2013-11-20 北京小米科技有限责任公司 界面色彩设置方法、装置和终端
US9311289B1 (en) * 2013-08-16 2016-04-12 Google Inc. Spreadsheet document tab conditional formatting
CN104199960B (zh) * 2014-09-18 2018-09-11 北京金山安全软件有限公司 标签页处理方法及装置
CN104657465B (zh) * 2015-02-10 2018-01-23 腾讯科技(深圳)有限公司 一种网页的显示控制方法及装置
CN104965631B (zh) * 2015-05-26 2020-05-15 深圳市万普拉斯科技有限公司 桌面配色方法、装置及智能终端

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140101539A1 (en) * 2011-08-26 2014-04-10 Tencent Technology (Shenzhen) Company Limited Website presenting method and browser
CN103164519A (zh) * 2013-03-08 2013-06-19 优视科技有限公司 调整工具栏色调的方法及装置
CN103198121A (zh) * 2013-04-02 2013-07-10 北京奇虎科技有限公司 浏览器设置背景的方法及浏览器
CN103440326A (zh) * 2013-09-02 2013-12-11 百度在线网络技术(北京)有限公司 提供呈现信息的方法和装置

Also Published As

Publication number Publication date
US10109079B2 (en) 2018-10-23
CN106708496B (zh) 2020-03-17
CN106708496A (zh) 2017-05-24
US20180018795A1 (en) 2018-01-18

Similar Documents

Publication Publication Date Title
WO2017084452A1 (zh) 图形界面中标签页的处理方法和装置
US11200295B2 (en) Web page annotation displaying method and apparatus, and mobile terminal
CN110795666B (zh) 一种网页生成方法、装置、终端及存储介质
US10643021B2 (en) Method and device for processing web page content
US9489469B2 (en) Page display method, apparatus and terminal
WO2018196588A1 (zh) 一种信息分享方法、装置和***
US20150128033A1 (en) Method and apparatus for webpage browsing
CN110020293B (zh) 多媒体数据展示方法、装置及存储介质
CN108073647B (zh) 网页显示方法及装置
WO2014206055A1 (en) A method and system for generating a user interface
US9921735B2 (en) Apparatuses and methods for inputting a uniform resource locator
US9977661B2 (en) Method and system for generating a user interface
WO2015003636A1 (zh) 一种页面元素的拦截方法和装置
CN111124709A (zh) 一种文本处理方法及电子设备
WO2014146450A1 (en) Method, device and system for data searching
CN105095161B (zh) 一种显示富文本信息的方法及装置
CN105094872B (zh) 一种显示网页应用的方法和装置
CN104123308B (zh) 网页生成方法及网页生成装置
US20160283047A1 (en) Login interface displaying method and apparatus
CN109145182B (zh) 数据采集方法、装置、计算机设备及***
CN108563712B (zh) 网页图片查看方法、装置及存储设备
CN110309454B (zh) 一种界面显示方法、装置、设备及存储介质
CN108616552B (zh) 网页访问方法、装置和***
CN107871017B (zh) 一种信息过滤功能的检测方法及装置
CN117435109A (zh) 一种内容显示方法、装置及计算机可读存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16865630

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 15/11/2018)

122 Ep: pct application non-entry in european phase

Ref document number: 16865630

Country of ref document: EP

Kind code of ref document: A1