Computing devices, ranging from large-scale computing devices to small handheld devices, typically provide their users with at least one visual interface. Graphical user interfaces (GUIs) generally provide the user with a visual presentation of the application or other program in use, and may additionally provide the user with manners to visually interact with the application or other program. GUIs and other computing system visual presentations are often provided in color. Various parts or areas of the GUI may be presented in certain colors, and/or by way of a color scheme. Examples of color schemes include visual styles or themes, where the appearance of visual controls, graphical appearance details, and/or other visual items may be presented in certain colors and color combinations.
In some cases, a theme could be changed to select one of a plurality of pre-designed themes that might color just some part of a GUI, such as presentation block title bars and borders. Such a solution only enables selection of pre-designed color combinations, and does not enable users to specify desired colors. Users may want to change the color of the user interface for various reasons. For example, the user may simply want to a more personally pleasing color combination. In another example, users may have visual impairments, whether it be low vision capabilities, the inability to see certain colors very well, etc. For example, certain users having some sort of visual impairment may benefit from high contrast visual presentations, whether of the same color or a variety of colors. High contrast may involve, for example, sufficiently contrasting colors between foreground and background portions of user interface elements to provide that particular user the ability to discern relevant text, glyphs and/or other informative indicia.
Changing the foreground and/or background color of individual user interface items on computer applications and other programs could place a burden on application developers. For an application color to be changed, application developers would need to obtain and apply color metrics manually in order to provide an application element of a certain color. Thus, application developers may need to assume the responsibility of drawing boxes or other shapes of certain colors for the application user interface elements in order to create the user interface. Thus, applications themselves may need to obtain color metrics and/or use graphics application programming interfaces (APIs) to actually draw the user interface elements. Further, selection of one of a plurality of pre-designed global color themes limits the ability of the user to select the particular colors in which applications will be presented. Changing global color themes may only change certain user interface elements such as a title bar or border, without affecting buttons and other graphical user interface elements of the application itself.
Techniques involving colorization of graphical user interfaces. One representative technique includes a computer-implemented method, where functions of the method are carried out by a system having processing/computing capabilities. The representative technique includes facilitating user specification of colors in which user interface elements will be colored in an application. An application colorization service is initiated in response to the user specification of the colors, which is used at least to obtain the colors specified by the user and create bitmap images of the application's user interface elements using the user-specified colors. A bitmap image output location is made accessible to the application to enable the application to retrieve the created bitmap images.
Another representative embodiment is directed to an apparatus having a user interface configured to enable a user to specify colors for application elements presentable via an application. A memory stores the user-specified colors for the application elements. A processor is configured to retrieve the stored colors, create graphical images for the application elements having the user-specified colors, enable access to the created graphical images by the application, and to execute the application to present the application elements using the created graphical images having the user-specified colors.
In still another representative embodiment, a method for colorizing user interface elements is embodied in instructions that are executable by a computing system and stored on computer-readable media. When executed, the instructions of the method facilitate user specification of one or more background colors, and one or more foreground colors, in which user interface elements will be respectively colored as background and foreground user interface elements in an application. The background and foreground colors may be stored as part of the system metrics. Size characteristics pertaining to the user interface elements are received from the application. A service module is provided to obtain the user-specified background and foreground colors for the user interface elements from the system metrics, create a bitmap image(s) using at least the size characteristics and the background and foreground colors, and store the created bitmap image(s) where it is accessible to the application for its use in presenting the user interface elements via the application.
This Summary is provided to introduce a selection of concepts in a simplified form that are further described below in the Detailed Description. This Summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.
In the following description, reference is made to the accompanying drawings that depict representative implementation examples. It is to be understood that other embodiments and implementations may be utilized, as structural and/or operational changes may be made without departing from the scope of the disclosure.
The disclosure is generally directed to graphical user interface colorization. An application user interface (UI) operating on a computing system(s) may be colorized in accordance with the disclosure. As noted above, one manner of changing application user interface (UI) colors is by way of visual styles or themes, which may change the color combination of all visual presentations. In such cases, users cannot specify particular colors, color combinations, contrasting colors for use in connection with applications they are using. Further, as high contrast or other color combinations may involve specifying both a foreground and background color of an application UI element, global color themes do not enable such user-specified granularity.
In order to change certain application UI elements, the application may be responsible for obtaining colors from system metrics or elsewhere, and using graphics primitives or APIs to actually draw application UI shapes of the obtained colors. Application UI elements, colorized according to user preferences, have not been centrally available to applications to relieve them of the responsibility of colorizing the application UI elements themselves. Further, in the context of high contrast solutions, predictable colorization cannot be applied to an arbitrary bitmap (or other similar image) used for application UI to ensure a specified contrast ratio between the background and foreground elements of a UI element.
To address these and other problems, the present disclosure provides techniques for colorizing graphical user interfaces in applications or other programs involving a graphical display. In one embodiment, a user can specify which one or more colors to be applied to the background and/or foreground of UI elements of an application(s). In one embodiment, the application UI colorization occurs at runtime of the application, and involves generating one or more bitmaps of the color(s) specified by the user. The desired colors or color combinations may be selected for any purpose, such as graphical aesthetics, high contrast or particular color combinations for the visually impaired, etc. Applications can obtain bitmaps for its application UI elements from a central repository that creates the bitmaps according to at least the user-specified colors, and in some embodiments also according to other characteristics (e.g. size) specified by the application itself.
Various embodiments below are described in terms of “bitmaps.” It should be recognized, however, that the principles described herein are equally applicable to any bitmap, pixmap or other image file format used to store digital images. Thus, while the term “bitmap” is used in connection with various representative descriptions throughout the disclosure, it is a representative type of image file format, and the disclosure is not limited thereto. For example, embodiments described herein could be applied to primitive drawing as well, such as functions used for lines, arcs, text, etc.
As described in embodiments below, given at least a set of color metrics designated by a user and sizing information provided by an application, bitmaps or other images may be generated to correspond to the provided color and sizing information. Such generated bitmaps may be applied to the UI of the application that provided the sizing metrics, and/or to another applications(s). Some embodiments also involve applying the color metrics to bitmaps or other images based on image combinations to create an appearance of some level of transparency (e.g. based on an alpha channel) of each pixel in the bitmap, which can provide a consistent colorization across the bitmap. For example, some embodiments described herein involve techniques to enable generation of bitmaps based on color and sizing metrics to be used as background elements in an application UI, and enable application of color to a bitmap based on an alpha channel of each pixel in the bitmap to be used as foreground elements in the application UI.
Thus, rather than a developer using graphics primitives to provide color on application UI elements of application 100, the application can use the application UI colorization service 102. Prior to use of such an application UI colorization service 102 as described herein, applications themselves would have to fetch color metrics, and boxes or other UI elements were drawn to create the UI element. The techniques described herein abstract such functions away from the applications, and enable service-based generation of bitmaps that are colorized based on user-specified metrics.
More particularly, the user 104 may request a bitmap 110, that represents some sort of UI element for the application 100, from the application UI colorization service 102. As an example, a user 104 can specify color information, such as by way of a control panel feature or other user interface. The user 104 could specify, for example, that UI buttons are to be dark blue, and text on the buttons will be white. The application UI colorization service 102 will extract the colors from the color metrics 106. Using the extracted colors, the application UI colorization service 102 can generate the bitmap 110 that has the user-specified colors for items such as, for example, the background color, border color and/or other color for the UI element. The service 102 delivers or otherwise makes that bitmap 110 available to the caller, which may be the application 100 or developer thereof, which will in turn apply it to the application 100 UI. Thus, among other things, the techniques described herein enable the generation of UI bitmaps, by way of a callable service that colorizes UI elements based on user-specified metrics.
In this manner, the application 100 can present its UI as a set of bitmaps or other image files without having to go to the detail of what the color of the UI element should be when a user changes the color. As noted above, the application UI colorization service 102 can provide a bitmap 110 that looks like the desired UI element—e.g., a button colored as specified by the user 104. While a size of the UI element could be specified by the user 104, in one embodiment the color is defined by the end user 104 while the size of the UI element is defined by the application 100 that is using the application UI colorization service 102. Thus, among other things, techniques described in the disclosure enable applications to call a service that generates bitmaps for application UI elements based at least in part on user input. The application can take those generated bitmaps from the service rather than generating the bitmaps itself.
The technique of
In one embodiment, the end user supplies color metrics to the system. This may be accomplished in various manners, such as by applying a theme or other visual style to the system, or creating a custom theme/visual style, and applying that to the system through a system-provided control user interface. When such a theme is applied, it in turn applies the color metrics to system metrics and requests that the visuals for the application UI be updated. Once the request is sent, the service will begin to generate bitmaps and apply color and sizing metrics to these bitmaps which can then be consumed by application UI executing on the system.
In accordance with the disclosure, both background and foreground elements of a UI component may be specified by the user.
Block 406 depicts that the system examines each pixel of the bitmap. In one embodiment color will be applied to the examined pixel if one or more conditions are met. It should be recognized that such conditions are not implemented in some embodiments, but in the embodiment of
In the embodiment of
When color metrics 502 have been modified, a notification to the theming service 508 may be provided. This notification is depicted in
The theming service 508 enables applications 504 to obtain bitmaps generated by the theming service 508, rather than fetching the color metrics or updated system metrics to create drawings of application UI elements themselves. In one embodiment, the application 504 provides application UI or image characteristics 514, such as bitmap size information, in any manner. Thus, in the illustrated embodiment, the size of the application UI element is defined by the application 504 using the theming service 508. For example, the application 504 can request of the theming service 508 a UI element size as part or all of the image characteristics 514, and may indicate that the application UI desired is a button that is to be three-hundred (300) pixels by forty (40) pixels. The theming service 508, having fetched the color metrics 512 and having received the size via the image characteristics 514, can generate a bitmap that is colored and sized correctly to that application request. The application 504 can obtain the generated bitmap from the graphic item output 516, and essentially paint the bitmap onto the corresponding application UI element.
While
As noted above, the graphic item output 516 represents what is output by the theming service 508; namely, bitmaps (or other images) of the color specified by the user and the size specified by the application 504. In one embodiment, when the bitmap output is ready at the graphic item output 516, the service can notify the application 504 to redraw itself using the bitmap(s) that is now colorized to the new set of colors specified via the personalization user interface 500. Thus, the application 504 essentially consumes the new bitmaps from the graphic item output 516.
In one embodiment, changing the colors via the control panel personalization 500B involves changing system metrics 506B via system color application programming interfaces (SysColor APIs) 520. In one embodiment, the color selections made by the user via the control panel personalization module 500B are translated to system metrics 506B by way of the system color APIs 520. The system metrics 506B represent information such as the dimensions of various display elements, and in the illustrated embodiment also include system color metrics. Multiple system metrics may be available that will map onto certain UI components, such as background color, text or glyph color, border color, highlighting, selected text color, etc.
When the user makes a color change via the personalization module 500B, this initiates a color or theme switching action in one embodiment, which involves the theme switch control module 522. The initiation of a color/theme switch by way of user-selected colors via the control panel personalization module 500B may be accomplished by sending a notification, such as the set system visual styles notification 524, to the theme switch control module 522. This notification 524 indicates that something is being changed in the system metrics 506B due to user-specified color changes, and the notification 524 indicates that the existing theme or other visual style is to be re-loaded or otherwise switched to something else corresponding to the user's selections.
In one embodiment, a security check may be performed in connection with initiating the switching of a theme or other system colors. In the illustrated embodiment of
In the illustrated embodiment, at least the theme switch control module 522 and the Uxtheme dynamic link library module (Uxtheme.dll) 530 form at least part of the theming service 508 described in connection with
When the theme switch control module 522 is notified via the set system visual styles notification 524, a notification shown as the thread injection notification 528 informs the Uxtheme.dll 530 to start colorizing images and re-loading those images. Thus, in one embodiment, the notification 524 essentially kicks off the process of regenerating bitmaps using the system metrics 506B that the end user just set b way of the control panel personalization module 500B.
More particularly, in response to the thread injection notification 528, the Uxtheme.dll 530 or analogous program fetches the information from the system metrics 506B, which may be by way of system color APIs 534. Upon fetching at least the updated color metrics from the system metrics 506B, the modules 530/532 can begin to generate the bitmaps that will ultimately be placed in the live data section bitmaps 516B for use as application UI by the calling application (not shown). Thus, the service 508 retrieves updated system metrics 506B and generates bitmaps for application UI, thereby allowing applications to avoid having to take on these and other responsibilities.
As noted in the embodiment of
As shown at block 600D and block 600E, colors may be specified by the user in various manners. For example, block 600D shows that the user may specify colors by presenting a GUI having selectable colors for the application UI elements, and enabling the user to select the desired colors via the GUI. An example of such a GUI is shown in
In the embodiment of
As shown in graphics block 720, the user may specify a color by way of a color palette 722 where the user clicks or otherwise graphically designates the desired color on the color palette 722. In another example, red, green and blue values may be entered graphically, textually, or otherwise in the RGB UI block 724. Another example shown at block 726 indicates that color may be designated based on other color characteristics such as hue, saturation, and brightness.
As previously noted, it may be desirable for ease of visibility, low vision needs, or other reasons to enable color selections such that there is a high contrast between foreground and background application UI elements. In one embodiment, an automatic high contrast UI feature 728 is provided to allow the user to let the system automatically choose high contrast colors. In one embodiment, the high contrast colors may be a default such as predominantly black and white for foreground and background coloring, or the user may be allowed to continue to rotate through a plurality of preset high contrast color combinations. In the embodiment illustrated in
Returning now to
Returning again to
The representative method of
As demonstrated in the foregoing examples, the embodiments described herein facilitate colorization of user interface elements. In various embodiments, methods are described that can be executed on a computing device, such as by providing software modules that are executable via a processor (which includes a physical processor and/or logical processor, controller, etc.). The methods may also be stored on computer-readable media that can be accessed and read by the processor and/or circuitry that prepares the information for processing via the processor. Having instructions stored on a computer-readable media as described herein is distinguishable from having instructions propagated or transmitted, as the propagation transfers the instructions versus stores the instructions such as can occur with a computer-readable medium having instructions stored thereon. Therefore, unless otherwise noted, references to computer-readable media/medium having instructions stored thereon, in this or an analogous form, references tangible media on which data may be stored or retained.
One embodiment involves providing an application colorization service, as shown at block 808, to facilitate colorizing the application UI elements for the application that calls the application colorization service. In the embodiment of
The representative computing system 900 includes a processor 902 coupled to numerous modules via a system bus 904. The depicted system bus 904 represents any type of bus structure(s) that may be directly or indirectly coupled to the various components and modules of the computing environment. A read only memory (ROM) 906 may be provided to store firmware used by the processor 902. The ROM 906 represents any type of read-only memory, such as programmable ROM (PROM), erasable PROM (EPROM), or the like. The host or system bus 904 may be coupled to a memory controller 914, which in turn is coupled to the memory 912 via a memory bus 916. The exemplary memory 912 may store, for example, all or portions of the operating system 918, application programs 920 and other programs, and data 922.
Among other things, the memory controller 914 may manage the flow of data to/from the processor 902. All or portions of the operating system 918, applications 920, data 922, etc., may be stored in internal storage 934 and/or external or remote storage 940, 944, 948. Such internal storage 934 or external/remote storage 940, 944, 948 include, but are not limited to, fixed or hard disk drives (whether magnetic, solid-state, etc.), portable diskettes, compact-disk read-only memories (CD-ROMs), digital versatile discs (DVDs) and other optical storage, magnetic tape, semiconductor memories such as random-access memories (RAM), read-only memories (ROM), programmable read-only memories (PROMs), subscriber identity modules (SIMs), wireless identification modules (WIMs), etc. Relevant portions of the operating system 918, applications 920 and data 922 may be provided to memory 912 to facilitate manipulation thereof, speed of access, etc. Therefore, while the operating system 918, applications 920 and data 922, and specific items associated therewith are shown in memory 912, this is for purpose of illustration as some or all of the information may be retained in other storage components versus memory.
The operating system (OS) stored in storage and/or memory 912 may include a control panel module 960, analogous to, for example, the control panel personalization module 500B of
The application programs 920 may represent any applications operable on the computing system 900, including the applications that call on the application UI colorization service described herein (e.g. the theming service 968). Data 922 may also be stored in memory 912 and/or storage 934, 940, 944, such as system metrics 972 and output bitmaps 974, which in one embodiment respectively correspond to system metrics 506B and live data section bitmaps 516B of
The colorization described herein provides different colors (and/or shades of one or more colors) for applications. The applications may be viewed on a display 980. A graphics card or other interface 982 can generate the output images to the display. The graphics interface 982 obtains the bitmaps 974 for the application via the system bus 904 or another bus. Thus, the application programs 920 can be presented on the display 980 having the system metrics 972 provided by the theming service 968 with colors specified by the user by way of the control panel module 960 or other GUI.
As demonstrated in the foregoing examples, embodiments described herein involve at least colorization of graphical user interfaces. In various embodiments, methods are described that can be executed on a computing device(s), such as by providing software modules that are executable via a processor (e.g. one or more physical processors and/or logical processors, controllers, etc.). The methods may also be stored on computer-readable media that can be accessed and read by the processor and/or circuitry that prepares the information for processing via the processor. For example, the computer-readable media may include any digital storage technology, including memory 912, storage 934, 940, 944, 948, any other volatile or non-volatile storage, etc.
Any resulting program(s) implementing features described herein may include computer-readable program code embodied within one or more computer-usable media, thereby resulting in computer-readable media enabling storage of executable functions described herein to be performed. As such, terms such as “computer-readable medium,” “computer program product,” computer-readable storage, computer-readable media or analogous terminology as used herein are intended to encompass a computer program(s) existent temporarily or permanently on any computer-usable medium.
Having instructions stored on computer-readable media as described herein is distinguishable from instructions propagated or transmitted, as the propagation transfers the instructions, versus stores the instructions such as can occur with a computer-readable medium having instructions stored thereon. Therefore, unless otherwise noted, references to computer-readable media/medium having instructions stored thereon, in this or an analogous form, references tangible media on which data may be stored or retained.
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as representative forms of implementing the claims.