Re: Comments on yesterday's version of the fresnel document

From: Chris Bizer <bizer_at_gmx.de>
Date: Wed, 23 Mar 2005 16:29:36 -0500

Fresnel - Display Vocabulary for RDF
Hi Emmanuel,

thanks for your comments.

 _at__at_@ I'm sorry to come back to this again, but I still do not understand why you are making a difference between selecting classes and instances. We discussed this by email a few days ago, and I still don't get it. When you say fresnel:lensDomain foaf:Person, you implicitely mean "the domain of this lens is all instances of class foaf:Person in the model".


Yes, I think the important word in the last sentence is *implicitly*. Knowing it implicitly means that we require the RDF schema to be known to figure out if a node is an instance or a class.

I think when we are browsing real world data found on the Semantic Web, we can not assume that we allways know the schema and have type information.

Thus I would like to have a solution that also works without this information. Which is the main reason why I would like to make the distinction between ClassLens and InstanceLens.

Another advantage is that using this explicit distinction, we can also display RDF schema information and OWL ontologies, which we cann't if the browser automatically infers the instances. Right?

We could of course also trick around with FSL. But I would really like to have this distinction in the core with basic rdf nameing.

What do the others think?



 _at__at__at_what is the order of precedence here? I guess that most specific ones come first.

Yes.

_at__at__at_In that case shouldn't FSL and SPARQL come before simple RDF naming? FSL and SPARQL selectors are supposed to be more specific than basic selectors.

This is an interesting question, which can be seen in two ways.
If you use FSL to name all persons that are below 30, then this expression is more specific than the class foaf:Person
If you use FSL to name all persons and all organisations, then the expression is less specific.

As I said, our specifity functions still need work.

 _at__at_@ we could add that the same thing can also be expressed as "foaf:Person[foo:age/"30"]"^^fresnel:selector

Yes, but don't we confuse user who haven't read the FSL spec with this more than we help them.
I would prefer to mention only one syntax at this point and leave it to the FSL spec to explain the different appreviations.

The decision which syntax to put there is of course up to you.

Chris



  ----- Original Message -----
  From: Emmanuel Pietriga
  To: Chris Bizer
  Cc: Stefano Mazzocchi ; Ryan Lee
  Sent: Wednesday, March 23, 2005 3:29 PM
  Subject: Comments on yesterday's version of the fresnel document


  Chris,

  I've put them inline in the HTML document (in red, beginning with _at__at_@).

  Writing this from the train, haven't checked email all day long, so you
  might have written a new version since then. I think my comments will
  still apply though.

  I would really like us to solve this ClassLens vs. InstanceLens issue.

  Emmanuel

  --
  Emmanuel Pietriga
  INRIA Futurs - Projet In Situ tel : +33 1 69 15 34 66
  Bat 490, Université Paris-Sud fax : +33 1 69 15 65 86
  91405 ORSAY Cedex FRANCE http://www.lri.fr/~pietriga




------------------------------------------------------------------------------


  ï»¿


  Fresnel - Display Vocabulary for RDF
  User Manual, 22 March 2005
    This version:
    http://www.w3.org/put the right URL here-20050320/
    Latest version:
    http://www.w3.org/put the right URL here/
    Editors:
    Chris Bizer, Freie Universität Berlin <chris_at_bizer.de>
    Somebody else??
  Copyright © 2005 W3C® ( MIT, ERCIM, Keio), All Rights Reserved. W3C liability, trademark, and document use rules apply.


------------------------------------------------------------------------------

  Abstract
  Fresnel is a simple vocabulary for specifying how to display RDF graphs.


------------------------------------------------------------------------------

  Table of Contents
    a.. 1 Introduction
      a.. 1.1 FOAF Example
      b.. 1.2 Vocabulary Modules
    b.. 1.3 Selector Languages
    c.. 2 Core Lens Vocabulary
      a.. 2.1 ClassLens, InstanceLens and LensDomain
      b.. 2.2 Property Selection and Ordering
      c.. 2.3 Lens Purposes
      d.. 2.4 Lens Specificity Function
    d.. 3 Core Style Vocabulary
      a.. 3.1 PropertyStyle and StyleDomain
      b.. 3.2 Labelling Properties
      c.. 3.3 Displaying Property Values
      d.. 3.4 Using CSS and SVG Styling Instructions
      e.. 3.5 Additional Content
      f.. 3.6 Style Specificity Function
    e.. 4 Grouping Styles and Lenses
    f.. 5 Extended Lens Vocabulary
    g.. 5.1 Lens Inheritance
    h.. 5.2 Using Sublenses
    i.. 5.3 Alternate and Merged Properties
    j.. 6 Extended Style Vocabulary
      a.. 6.1 Selector Pseudo-Classes
      b.. 6.2 Including external Media Files
      c.. 6.3 Supporting different Output Media
      d.. 7 Fresnel Processing Model
        a..
    k..
  Appendices
    a.. A References
    b.. B Change Log


------------------------------------------------------------------------------

  1 Introduction
  Fresnel is a simple vocabulary for specifying which parts of an RDF graph [1] are displayed by an RDF browser and how they are styled using existing style languages like CSS [2].

  Displaying RDF in a human-friendly manner by way of an RDF display vocabulary has been done in different ways across applications. After recognizing the general need for displaying RDF and wanting to avoid reinventing the wheel over and over again, members of the Semantic Web Interest Group united to create Fresnel as an extensible ontology of core RDF display concepts.

  The Fresnel design goals were to create a vocabulary which is

    a.. applicable across different RDF display paradigms, e.g. graph-oriented or text-oriented,
    b.. useful for rendering different output formats like HTML, SVG, PDF, plain text and other formats,
    c.. builds on existing Web technology,
    d.. extensible with special purpose vocabularies,
    e.. easy to learn and use.
  Fresnel's two main concepts are Lenses and Styles. Fresnel Lenses define which properties of an RDF resource are displayed and how these properties are ordered. Fresnel Styles determine how these properties are rendered by specifying the basic, RDF-specific styling and by providing hooks to CSS [2] and SVG [3] styling instructions, which are used to specify fonts, colors and borders.



  Fresnel realizes a strict distinction between selection and styling. The Fresnel rendering process involves three steps:

    1.. Selection: The parts of the RDF graph to be displayed are selected and ordered using a Fresnel lens or a set of lenses. The result of the selection step is a ordered tree of RDF nodes, not containing any styling information yet.
    2.. Styling: Afterwards, a set of Fresnel styles is applied to the tree, adding a set of styling instructions to each node.
    3.. Output Generation: The result of step 2 is rendered into the appropriate output format.
  Some of output formats we had in mind while designing Fresnel are:

    a.. HTML or SVG document including CSS styling instructions
    b.. HTML or SVG document plus an external CSS stylesheet
    c.. XML tree plus external CSS stylesheet
    d.. PDF or plain text document or an document in other format.
  Terminology
  Fresnel takes an ontology-centric view on RDF graphs. Thus this document speaks of classes which are having instances. Instances are are having properties, which are having property values.

  1.1 FOAF Example
  The following example shows how Fresnel can be used to render FOAF [4] persons.

# -----------------------------------------------# 1.Fresnel Lenses for FOAF Person# -----------------------------------------------
:foafPersonDefaultLens rdf:type fresnel:ClassLens ;
          fresnel:purpose fresnel:defaultLens ;
          fresnel:lensDomain foaf:Person ;
          fresnel:group :foafGroup ;
          fresnel:showProperties ( foaf:name
                                   foaf:surname
                                   foaf:depiction ) .
:knowsLens rdf:type fresnel:ClassLens ;
          fresnel:lensDomain foaf:Person ;
          fresnel:group :foafGroup ;
          fresnel:showProperties ( foaf:name
                                   foaf:surname
                                   foaf:mbox
                                   [ rdf:type fresnel:PropertyDetails ; fresnel:property foaf:knows ; fresnel:sublens :foafPersonDefaultLens ] ) .
                                              
# -----------------------------------------------
# 2. Fresnel Styles
# -----------------------------------------------

:foafGroup rdf:type fresnel:Group ;
          fresnel:stylesheetLink <http://www.example.org/example.css> ;
          fresnel:containerStyle "global"^^fresnel:cssClassSelector ;

:depictStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:depict ;
          fresnel:label fresnel:none ;
          fresnel:value fresnel:image ;
          fresnel:valueStyle "border: thick silver solid;"^^fresnel:cssStylingInstruction ;
          fresnel:group :foafGroup .
        
:uriStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:homepage ;
          fresnel:styleDomain foaf:mbox ;
          fresnel:value fresnel:uri ;
          fresnel:labelStyle "basicLabel"^^fresnel:cssClassSelector ;
          fresnel:valueStyle "basicUri"^^fresnel:cssClassSelector ;
          fresnel:group :foafGroup .

  The Fresnel stylesheet above contains two lenses for foaf:Person. The first lens defines a view on foaf:Person containing three properties: Name, surname and depiction. A browser would start with displaying this lens because it is marked with the purpose fresnel:defaultLens. The second lens displays a person together with all other persons she knows. The fresnel:sublens property specifies that the foafPersonDefaultLens should be used to display the people a person knows.

  The second part of the stylesheet contains a link to an external CSS stylesheet and the definition of a CSS class containing global default styles. Afterwards, the :depictStyle specifies that all values of the foaf:depict property should be displayed as images having solid, silver borders. The:uriStyle specifies that values of foaf:homepage and foaf:mbox should be displayed as URIs using the basicLabel and the basicUriCSS classes for styling the property label and the property values.


  1.2 Vocabulary Modules
  In order to make it easier for browsers to implement Fresnel, we have modularized Fresnel along two modularization axis:

    a.. Vocabulary Moduels: Fresnel is split into two core and two extended vocabularies. The core vocabularies contain Fresnel's main concepts and have to be implemented by all browsers wishing to support Fresnel. The extended vocabularies contain additional functionality. Browsers should try to implement this functionality or parts of it.
    b.. Selector Languages: Fresnel selectors are used to specify which lenses and styles apply to which set of RDF instances or to which property. There are three selector languages: 1. Simple RDF naming, 2. Fresnel Selectors and 3. SPARQL. Fresnel browser must support simple RDF naming, but should also try to support the others.
  Fresnel is split into a core-lens and a core-style vocabulary and two additional vocabularies containing terms for more advanced functionality.

    a.. Lens-Core, containing the basic vocabulary for defining lenses.
    b.. Style-Core, containing the basic vocabulary for specifying styles.
    c.. Lens-Extended, containing additional terms for relating lenses and sublenses and for using lens inheritance.
    d.. Style-Extended, containing advanced lens selector-, media type- and lens purpose vocabularies.
  1.3 Selector Languages
  Fresnel selectors are used in fresnel:lensDomain or fresnel:styleDomain properties to specify which lenses and styles should be used to display which RDF instances. Fresnel supports three selector languages:

  1. Simple RDF Naming
  Simple RDF naming is the easiest but also least expressive way to specify lens and style domains. You specify the domains by directly naming the class, property or instance to which a lens or style should apply.
:foafPersonLens rdf:type fresnel:ClassLens ; fresnel:lensDomain foaf:Person ;2. Fresnel Selectors
  You can also specify lens and style domains by using the Fresnel selector language. The Fresnel selector language is similar to Xpath. The language was created by deriving the pieces from different RDFpath proposals that are relevant to Fresnel.

  Example: The following style applies only to person that are exactly 30 years old.

:foafPersonStyle rdf:type fresnel:InstanceStyle ; fresnel:styleDomain
                 "*[rdf:type/foaf:Person and foo:age/"30"]"^^fresnel:selector ;_at__at_@ we could add that the same thing can also be expressed as "foaf:Person[foo:age/"30"]"^^fresnel:selector

  More information about the Fresnel Selector language is found in the Fresnel Selectors Manual.
  3. SPARQL
  In addition to the Fresnel Selector language, some browsers might also want to allow the full expressivity of SPARQL.
todo: Write example when the working group has written the spec ;-)The SPARQL queries used within Fresnel always have to return exactly on node set, meaning that they are only allowed to have one variable in the SELECT clause.


  2 The Core Lens Vocabulary
  Fresnel lenses specify which properties of an RDF instance are shown. For example, a 'short summary' lens for FOAF persons might display the name and the email address of a person. The result of applying a lens or a group of lenses to an RDF graph is a ordered tree of RDF nodes. This tree doesn't contain any styling information yet. Styling instructions are added as a seperate step using Fresnel Styles.

  The core lens vocabulary is used to define

    a.. lenses,
    b.. the set of instances to which a lens is applicable,
    c.. the properties to be displayed,
    d.. the order of these properties and the order of their values,
    e.. the purpose of a lens.
  2.1 ClassLens, InstanceLens and LensDomain
  _at__at_@ I'm sorry to come back to this again, but I still do not understand why you are making a difference between selecting classes and instances. We discussed this by email a few days ago, and I still don't get it. When you say fresnel:lensDomain foaf:Person, you implicitely mean "the domain of this lens is all instances of class foaf:Person in the model". When I say fresnel:lensDomain "*[rdf:type/foaf:Person]"^^fresnel:selector, I say the same thing. Yet, I'm explicitely addressing instances. Anyway, when specifying a lensDomain, no matter wether we are, we *know* we are refering to instances. When we just write foaf:Person, we know this actually means "resources of rdf:type foaf:Person". I really need an example of when you really need to make the difference between a ClassLens and an InstanceLens. The only reason I see why you would want to consider the basic expression "foaf:Person" as an instance and not a class is if you want to state that the domain of this lens should actually be the single resource whose URI is foaf:Person. I consider this a corner case. I don't think we need to have ClassLens and InstanceLens just for this, because you can actually state that "the lensDomain should be the single resource whose URI is foaf:Person" by using the following FSL expression: "*[. = foaf:Person]"^^fresnel:selector (which is different from "foaf:Person"^^fresnel:selector as this is actually equivalent to "*[rdf:typer/foaf:Person]"^^fresnel:selector). Note that this abbreviated syntax actually means that basic selectors (in the context of what you call ClassLens) actually have the same semantics as the same thing written as an FSL expression, meaning that basic selectors are actually a subset of FSL, which is nice. So my point is, having both InstanceLens and ClassLens introduces complexity in the language for corner cases, which are anyway easily expressed with simple FSL expressions, just having one kind of Lens (instead of making the difference between ClassLens and InstanceLens).

  The fresnel:lensDomain property specifies the set of instances to which a lens is applicable. A lens can have more than one lens domain.

  This set of instances can be specified in two ways:

  ClassLens

  ClassLenses are used to specify that a lens should be applicable to all instances of the class being named in the fresnel:lensDomain.

  Example: The following lens is applied to all instances of foaf:Person

:foafPersonLens rdf:type fresnel:ClassLens ; fresnel:lensDomain foaf:Person .InstanceLens

  InstanceLenses are used to specify a custom set of instances to which the lens should be applicable. This set is usually defined using the Fresnel Selector language or SPARQL.

  Example: The following lens should only be used for persons that are older than 60 years.

:oldGuys rdf:type fresnel:InstanceLens ;
         fresnel:lensDomain
         "*[rdf:type/foaf:Person and foaf:age/* > 60]"^^fresnel:selector ;



  2.2 Property Selection and Ordering
  Lenses use fresnel:showProperties and fresnel:hideProperties to define which properties are displayed. The value of showProperties and hideProperties is a single RDF property or an RDF list containing a ordered list of RDF properties.

  Example: The following lens shows the foaf:name property first, followed by the foaf:mbox and foaf:homepage property.

:foafPersonShortLens rdf:type fresnel:ClassLens ; fresnel:lensDomain foaf:Person ; fresnel:showProperties ( foaf:name foaf:mbox foaf:homepage ) .Unknown Property Sets
  RDF has a flexible data model that allows arbitrary properties to be added to resources. Thus lens author's can not expect to know all properties in advance that instances might use. The case can be handled using fresnel:allProperties:

  fresnel:allProperties is a placeholder for the names of all properties of the current instance that haven't been explicitly named in the property list before.

  Example: The following lens shows the foaf:name property first, followed by the foaf:mbox and foaf:homepage property. Afterwards it displays all other properties of the current person, but hides the dc:creator and dc:date properties.

:foafPersonShortLens rdf:type fresnel:ClassLens ; fresnel:lensDomain foaf:Person ; fresnel:showProperties ( foaf:name foaf:mbox foaf:homepage
                                   fresnel:allProperties );
          fresnel:hideProperties ( dc:creator
                                   dc:date ) .RDF Lists and RDF Containers
  If the value set of property P1 contains one rdf:list, rdf:bag or rdf:alt then the elements of this list are treated like direct property values of P1. If the set of values contains several rdf:lists, rdf:bags or rdf:alts then they are treated separately as normal instances.

  2.3 Lens Purpose Vocabulary
  The idea behind the lens purpose vocabulary is to help the browser to decide which lens to use in situations where there are several applicable lenses.

  Purposes are specified using the fresnel:purpose property.

  Lens purposes depend on the application-domain and the browser's display paradigm. Therefore, we are just providing an open interface for using domain- or browser-specific purposes and define two relatively general purposes which might be useful across browsers.

  :defaultLens for a specific class. Browsers might decide to show a lens having the purpose :defaultLens in situations where there are several applicable lenses.

  :labelLens provides a short human-understandable label for a instance of a specific class. Browsers in the need of labelling a instance (see fresnel:value ) should implement the following behaviour:

    1.. Look for labelLenses for the specific class.
    2.. Display one of them.
    3.. If no label lens is found, display rdfs:label value.
    4.. If no rdfs:label is found, display dc:title
    5.. If no dc:title is found, display the URI of the resource.
  Example: LabelLens for foaf:Person displaying only the person's name.

:foafPersonLabelLens rdf:type fresnel:ClassLens ; fresnel:purpose fresnel:labelLens ; fresnel:lensDomain foaf:Person ; fresnel:showProperties foaf:name .

  2.4 Lens Specificity Function
  If there is more than one lens applicable to an instance and the user hasn't specified a specific lens that he wants to use, then the browser should select a lens using the following specificity function:

  _at__at__at_what is the order of precedence here? I guess that most specific ones come first. In that case shouldn't FSL and SPARQL come before simple RDF naming? FSL and SPARQL selectors are supposed to be more specific than basic selectors.

    1.. Instance Lens using simple RDF naming
    2.. Instance Lens using SPARQL
    3.. Instance Lens using FSL
    4.. Default Class Lens using simple RDF naming
    5.. Default Class Lens using SPARQL
    6.. Default Class Lens using FSL
    7.. Class Lens using simple RDF naming
    8.. Class Lens using SPARQL
    9.. Class Lens using FSL
  This still needs work: Open Issues

    a.. Instances with multiple types
    b.. Several lenses of the same specifcity e.g. LabelLenses.
    c.. Different specificities for different types of FSL, SPARQL queries
    d.. Ensure that there is always the same lens selected in a specific situation.


  3The Core Style Vocabulary
  Fresnel lenses specify what information is displayed. The style vocabulary is used to specify how information is displayed.

  The vocabulary is providing a bridge between RDF and CSS [2] and SVG [3] styling instructions. These are used to specify style attributes like colors, fonts and borders. The style vocabulary also contains some RDF-specific terms for areas that are not covered by CSS or SVG.

  The lens core vocabulary is used to style RDF properties by defining:

  _at__at__at_shouldn't that be "the style core vocab?"

    a.. how a property is labelled,
    b.. how the property values are displayed,
    c.. which additional content like commas and periods is displayed between or after property values,
    d.. the CSS styling instructions for defining fonts, colors or borders.
  Using the vocabulary, you can say things like:

    a.. Display all values of the foaf:depict property as an image without a label.
    b.. Display the label of the foaf:name property using Arial 12pt.
    c.. Display values of foaf:knows with the custom label "Friends of the guy: ".
  Styles are usually grouped together using a Fresnel Group. See Chapter 4 for details about Fresnel groups.

  3.1 PropertyStyle and styleDomain
  The core style vocabulary only allows RDF properties to be styled. The Extended Style vocabulary also allows specific sets of instances to be styled.

  Styles for RDF properties are defined using fresnel:PropertyStyles.

  The fresnel:styleDomain property specifies a set of properties to which a style is applicable. A style can have more than one style domain.

  Example: The following style applies to the foaf:depict property:

:depictStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:depict .

  3.2 Labelling Properties
  Fresnel uses the rdfs:label of a property to label this property. If there is no rdfs:label defined for a property then the URI of the property is displayed. It is also possible to define custom labels.

  The fresnel:label property defines if a property label is displayed (fresnel:show) or not (fresnel:none). Using the fresnel:label property with a literal value specifies a custom property.

  Example: Do not show the label of the foaf:depict property:

:depictStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:depict ; fresnel:label fresnel:none .
Example: Use a custom label for the foaf:knows property:

:knowsStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:knows ; fresnel:label "The guy knows the following people: " .


  3.3 Displaying Property Values
  The default behaviour for displaying property values is:

    1.. If the value is a literal, then display it as text.
    2.. If the current lens contains a sublens for this property, use the sublens to display the value.
    3.. If the value is a resource or bNode, check if the default procedure is overridden by a style for this instance and execute the specified behaviour.
    4.. If the value is a typed resource or typed bNode, check if the default procedure is overridden by a style for the type of this instance and execute the specified behaviour.
    5.. If the value is a resource or bNode, then check if there is a label InstanceLens for this resource or bNode and display it.
    6.. If the value is a typed resource or a typed bNode check if there is a label ClassLens for the type of this resource or bNode and display it.
    7.. If the resource has a rdfs:label property, then display its value.
    8.. If the resource has a dc:title property, then display its value.
    9.. Otherwise display the URI of the resource or the name of the bnode.

  This default behaviour can be overridden using the fresnel:value propery. The fresnel:value property specifies, that all values of a property are displayed

    a.. as Images (Reason: You usually like to see an image and not the metadata about an image) or
    b.. as URIs (Reason: For some properties like mailboxes or homepages it is preferable to display the URI instead of the metadata about the box or site).
  In the case that the default behaviour is overridden, Browser might want to give the user the option to switch back to the default behaviour or to manually select a lens that he likes to use.

  Example: Display values of the foaf:depict property always as images.

:depictStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:depict ; fresnel:value fresnel:image .
Example: Display values of the foaf:mbox property always as URIs.

:knowsStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:mbox ; fresnel:value fresnel:uri .



  3.4 Using CSS and SVG Styling Instructions
  Fresnel uses CSS [2] styling instructions for defining colors, fonts, borders and other decorative elements. Fresnel uses SVG [3] styling instructions for defining strokes and brushes.

  Styling instructions can be included directly into a Fresnel lens or can be included by CSS class references from an external stylesheet.

  Fresnel Box Model

  Styling instructions can be applied to the 5 elements of Fresnel's box model. This box model consists of:

        Box Model Element Description
        Container Box The container box surrounds all instances that are currently displayed.
        Usage example: Specifying the background color of a page.
        A container box contains a set of resource boxes.
        Resource Box The resource box surrounds all properties of a single resources.
        Usage example: Specifying a box around all properties of an instance.
        The box contains a set of property boxes.
        Property Box The property box surrounds the area that is used to display a single property.
        Usage example: Specifying the background color of whole area that representing a property.
        It contains one label box and a set of value boxes.
        Label Box The label box contains the label of a property.
        Value Box The value box contains one property value.
        If several lenses are displayed together (fresnel:sublens) then a value box may contain another complete Fresnel box model.

  Styling instructions can be attached to elements of the box model by using the corresponding Fresnel hook property.

  The following table contains the fresnel hook properties and defines the elements to which the hooks are applicable.

        Styling Hook Applicable to
        fresnel:containerStyle fresnel:Group instances (see Grouping Lenses and Styles)
        fresnel:resourceStyle fresnel:Group, fresnel:ClassStyle and resnel:InstanceStyle instances (see Extended Stye Vocabulary for ClassStyle and InstanceStyle)
        fresnel:propertyStyle fresnel:PropertyStyle instances (see above for PropertyStyle)
        fresnel:labelStyle fresnel:PropertyStyle instances
        fresnel:valueStyle fresnel:PropertyStyle instances

  Example: The following Fresnel style defines that the label of the foaf:name property is displayed using the color grey and that the property values are displayed in black.

:nameStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:name ; fresnel:labelStyle "font-color: #808080"^^fresnel:cssStylingInstruction ;
          fresnel:valueStyle "font-color: #000000"^^fresnel:cssStylingInstruction .Example: The following Fresnel style defines that a line is drawn above the area representing the property foaf:mbox and that a line is drawn below each of the property values.

:mboxStyle rdf:type fresnel:PropertyStyle ;
      fresnel:styleDomain foaf:mbox ; fresnel:propertyStyle "border-top: solid black"^^fresnel:cssStylingInstruction ;
      fresnel:valueStyle "border-bottom: solid black"^^fresnel:cssStylingInstruction .

  Internal and External Styling Instructions

  Fresnel offers two ways for attaching styling instructions to Fresnel styling hooks.

  1. Internal Styling Instructions

  Internal styling instructions are included into Fresnel styles as literals of datatype fresnel:cssStylingInstruction.

  Example:

:mboxStyle rdf:type fresnel:PropertyStyle ;
      fresnel:styleDomain foaf:mbox ; fresnel:propertyStyle "border-top: solid black"^^fresnel:cssStylingInstruction ;
  2. External Styling Instructions

  Styling instructions can also be kept in an external stylesheet and be referenced from Fresnel styles using CSS class names.

  In this case, a fresnel:stylesheetLink is added to the group to which the Fresnel styles belong. The fresnel:stylesheetLink contains the URL of the external stylesheet. A browser might decide to allow the user to switch between different external styesheets, if a fresnel:group contains several fresnel:stylesheetLinks.

  CSS classes contained in the external stylesheet are referenced using literals of datatype fresnel:cssClassSelector.

  Example: In the following example, there is a external stylesheet attached to the :foafGroup. The CSS classes contained in this stylesheet are used by the :uriStyle to style the label and the value of the foaf:homepage property.

:foafGroup rdf:type fresnel:Group ;
          fresnel:stylesheetLink <http://www.example.org/example.css> .
        
:uriStyle rdf:type fresnel:PropertyStyle ;
          fresnel:styleDomain foaf:homepage ;
          fresnel:labelStyle "basicLabel"^^fresnel:cssClassSelector ;
          fresnel:valueStyle "basicUri"^^fresnel:cssClassSelector ;
          fresnel:group :foafGroup .
  3.5 Additional Content
  Fresnel allows you to add fixed content at various places of the box model. This can be used for example to add commas to a list of property values or to add headings in front of resources.

  You can also specify a additional content that should be displayed if a property is missing.

  Todo: Describe in detail ....



  3.6. Style Specifity Function
  Todo: Describe ....



  4 Grouping Styles and Lenses
  Fresnel aims at the exchange of lenses and styles and the usage of lenses and styles from different sources. Lenses and styles can be grouped in order to make it easier for the browser to determine which lenses and styles fit well together.

  A browser should consider groups when

    a.. selecting default and label lenses
    b.. determining the specificity of styles amd lenses
  Groups also provide hooks for attaching

    a.. links to external CSS stylesheets,
    b.. namespace prefixes for the Fresnel Selector Language,
    c.. CSS styling instructions which should apply to the area surrounding the displayed RDF data (containerStyle).
  Example: The following group contains a link to an external CSS stylesheet and defines that the CSS class 'global' should be used to style the container surrounding the displayed RDF data.

:foafGroup rdf:type fresnel:Group ;
          fresnel:stylesheetLink <http://www.example.org/example.css> ;
          fresnel:containerStyle "global"^^fresnel:cssClassSelector ; Lenses and Styles are put into a group using the fresnel:group property.

:depictStyle rdf:type fresnel:PropertyStyle ;
          fresnel:group :foafGroup .

  5 Extended Lens
  # Contents:
  # 1. Lens Inheritance Vocabulary
  # 2. Extended Property Selection Vocabulary
  # 3. Property Description Vocabulary
  # 4. Lens Relation Vocabulary



  6 Extended Style
  # Contents:
  # 1. Class and Instance Styles
  # 2. Additional Style Description Properties
  # 3. Additional Property Value Styles for Media Types
  # 4. Style Purposes

  7 Processing Model
  This chapter will describe the Fresnel rendering process.









  A. References
  References

  [1] Resource Description Framework (RDF): http://www.w3.org/RDF/

  [2] Cascading Style Sheets (CSS): http://www.w3.org/Style/CSS/

  [3] Scalable Vector Graphics (SVG): http://www.w3.org/Graphics/SVG/

  [4] Friend of a Friend (FOAF) project: http://www.foaf-project.org/





  [13] RFC 3986, "Uniform Resource Identifier (URI): Generic Syntax", T. Berners-Lee, R. Fielding, L. Masinter

  [14] "Namespaces in XML 1.1", Tim Bray et al., W3C Recommendation.

  [17] "XQuery 1.0 and XPath 2.0 Functions and Operators", Ashok Malhotra et al., W3C Working Draft.




------------------------------------------------------------------------------

  B. Change Log
    a.. Revision 1.0 2005/03/22 Chris:
    Intital version of this document.
Received on Wed Mar 23 2005 - 21:29:53 EST

This archive was generated by hypermail 2.3.0 : Thu Aug 09 2012 - 16:39:18 EDT