摘要 |
A method and system of determining the screen capability and rendering the appropriate display attribute is herein described. The present invention performs this task by using a color table, which contains a list of object types and a corresponding list of display attributes. The application program obtains the correct display attribute for the object by calling the color table, giving it an identifier of the object. The color table is indexed by the identifier of the object and a screen capability flag that is obtained, in one embodiment, from the operating system. The color table provides the display attribute for the specified object based on the screen capability flag. Advantageously, the application program does not need to know the computer's display capability. Furthermore, the application program needs only one piece of computer code, regardless of the number of display capabilities which are possible. Thus, memory space in the palmtop is conserved. In another embodiment of the present invention, the application program is allowed to modify the default values of the display attributes in the color table. Thus, an application program could use its own color to display an object if the default color is undesirable.
|