Cascading style sheets (CSS) prototype pointer chaining in object-oriented environment
First Claim
1. A computer-implemented method comprising:
- representing a plurality of hierarchical rules as a plurality of objects in a prototype pointer chain;
providing a function to search said rules for a desired style by traversing said prototype pointer chain; and
processing via a processor instructions stored on computer-readable storage medium to provide a user interface comprising a visual object wherein a visual appearance of the visual object is affected by the desired style;
wherein said hierarchy of rules is defined in Cascading Style Sheets (CSS) standard; and
wherein said objects in said prototype pointer chain include a first object representing said type rule, said first object being a supertype of a second object, said second object representing said class rule, said second object being a supertype of a third object, said third object representing said inline rule.
3 Assignments
0 Petitions
Accused Products
Abstract
A method, system, and computer program product for providing an application include representing a plurality of hierarchical rules as a plurality of objects in a prototype pointer chain, and providing a function to search the rules for a desired style by traversing the prototype pointer chain. An exemplary method provides a user interface or application with one or more visual objects. The visual appearances of the visual objects is affected by style information retrieved by traversing a prototype pointer chain to search for style-related rules. A compiled file can include code that describes rules as objects and creates class inheritance relationships between those objects and code that describes a style-finding function. A displaying program instantiates the objects arranged in a prototype pointer chain and uses its own inheritance logic to traverse the chain according to the style-finding function.
28 Citations
19 Claims
-
1. A computer-implemented method comprising:
-
representing a plurality of hierarchical rules as a plurality of objects in a prototype pointer chain; providing a function to search said rules for a desired style by traversing said prototype pointer chain; and processing via a processor instructions stored on computer-readable storage medium to provide a user interface comprising a visual object wherein a visual appearance of the visual object is affected by the desired style;
wherein said hierarchy of rules is defined in Cascading Style Sheets (CSS) standard; and
wherein said objects in said prototype pointer chain include a first object representing said type rule, said first object being a supertype of a second object, said second object representing said class rule, said second object being a supertype of a third object, said third object representing said inline rule. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A computer-implemented method comprising:
-
receiving first code, said first code describing a first object and rules applying to said first object, said rules in a hierarchy of rules; compiling said first code into second code, said second code describing a plurality of styles as properties of a plurality of second objects, each of said second objects representing one of said rules, said second objects being ordered in a prototype pointer chain, the order corresponding to the hierarchy of rules, said second code describing a method to find a desired style of said first object by traversing said prototype pointer chain; and processing, via a processor, instructions stored on computer-readable medium to provide a Rich Internet Application (RIA) comprising a visual object, wherein a visual appearance of the visual object is affected by the desired style wherein said hierarchy of rules is defined in Cascading Style Sheets (CSS) standard; and
wherein said objects in said prototype pointer chain include a first object representing said type rule, said first object being a supertype of a second object, said second object representing said class rule, said second object being a supertype of a third object, said third object representing said inline rule. - View Dependent Claims (9, 10, 11, 12)
-
-
13. A computer program product having a computer readable storage medium having computer program logic recorded thereon for providing a user application, comprising:
-
code to instantiate a first object and a second object, said first object to be rendered as part of a User Interface (UI) of said application; code to apply a property to said first object that encompasses a plurality of styles of said first object, the value of said property being said second object, said second object being a first rule, the properties of said second object being styles applicable to affect a visual appearance of said first object; code to instantiate a third object, said third object being a superclass of said second object, the properties of said third object being other styles applicable to affect the visual appearance of said first object, wherein said second and third objects represent hierarchical rules; and code to call a method of said first object, said method instructing a program to inspect said second and third objects for said styles and said other styles by traversing a prototype pointer chain that includes said second and third objects comprising code to instantiate a fourth object in said prototype pointer chain, said fourth object being a superclass of said third object, wherein said second object corresponds to an inline rule, said third object corresponds to a class rule, and said fourth object corresponds to a type rule. - View Dependent Claims (14, 15, 16)
-
-
17. A computer-implemented method comprising:
-
instantiating a first user interface (UI) object; instantiating a plurality of second objects, each of said second objects representing a rule in a hierarchy of rules, said second objects being ordered in a prototype pointer chain, the order of said prototype pointer chain corresponding to the hierarchy of rules, wherein each of said second objects includes at least one property that is a style; traversing said prototype pointer chain to find a desired one of said styles to apply to said first object; and processing, via a processor, instructions stored on computer-readable storage medium to render an application comprising the first UI object, wherein a visual appearance of the first UI object is affected by the desired style instantiating a plurality of third objects, each of said third objects representing a rule in said hierarchy of rules, said third objects being ordered in a second prototype pointer chain, the order of said second prototype pointer chain corresponding to said hierarchy of rules and associated with said first user interface object and with one or more supertype objects of said first user interface object, wherein each of said third objects includes at least one property that is a style; and
traversing said second prototype pointer chin to find a desired style to apply to said first object. - View Dependent Claims (18, 19)
-
Specification