OASIS Open Document Format for Office Applications (OpenDocument) TC

 View Only
  • 1.  Re: [office] preferred view mode upon opening document

    Posted 10-24-2008 06:45
    The way we resolved this situation elsewhere in ODF are namespaced
    tokens, that is, a namespace prefix, followed by an identifier.
    
    If we use that for the manifest:preferred-view-mode attribute, then the 
    schema would look like this:
    
    
    
    We would pre-define the values
    
    manifest:edit
    manifest:presentation-slide-show
    manifest:read-only
    
    
    One question is whether we want to provide fallback values for user 
    defined values, so that application that don't understand the user 
    defined view mode can at least choose one of the pre-defined modes that 
    is close to the use defined mode. If we want to have this, then we may 
    define two attributes. One that is exactly what we have in the original 
    proposal, and an additional one, let's say 
    "manifest:extended-preferred-view-mode" that takes a namespaced value. 
    Depending on whether we want the fallback value to be optional or 
    mandatory, the schema may look like this:
    
    
    
    or like this
    
    
    
    Michael
    
    
    -- 
    Michael Brauer, Technical Architect Software Engineering
    StarOffice/OpenOffice.org
    Sun Microsystems GmbH             Nagelsweg 55
    D-20097 Hamburg, Germany          michael.brauer@sun.com
    http://sun.com/staroffice         +49 40 23646 500
    http://blogs.sun.com/GullFOSS
    
    Sitz der Gesellschaft: Sun Microsystems GmbH, Sonnenallee 1,
    	   D-85551 Kirchheim-Heimstetten
    Amtsgericht Muenchen: HRB 161028
    Geschaeftsfuehrer: Thomas Schroeder, Wolfgang Engels, Dr. Roland Boemer
    Vorsitzender des Aufsichtsrates: Martin Haering
    
    


  • 2.  Re: [office] preferred view mode upon opening document

    Posted 10-24-2008 09:21

    Sure, namespaceToken can satisfy the name extension requirement, the name will be like "xxxx:yyyy". This gets me out of the case that I'm defining new data type:) Thanks Michael. Also I agree with Michael's suggestion that separate custom view modes from the pre-defined values.

    BTW, I think Rob's URI solution is also a good solution, in which it is not necessary to separate custom view modes from pre-defined values,and only needs one attribute "manifest:preferred-view-mode". Moreover, that method can be used to solve those general enumeration extension issues.

    I really feel the community's capabilities:)

    Mingfei
    Michael Brauer - Sun Germany - ham02 - Hamburg ---10/24/2008 02:50:44 PM---The way we resolved this situation elsewhere in ODF are namespaced


    From:

    Michael Brauer - Sun Germany - ham02 - Hamburg <Michael.Brauer@Sun.COM>

    To:

    robert_weir@us.ibm.com

    Cc:

    office@lists.oasis-open.org

    Date:

    10/24/2008 02:50 PM

    Subject:

    Re: [office] preferred view mode upon opening document




    The way we resolved this situation elsewhere in ODF are namespaced
    tokens, that is, a namespace prefix, followed by an identifier.

    If we use that for the manifest:preferred-view-mode attribute, then the
    schema would look like this:

    <define name="file-entry-attlist" combine="interleave">
      <optional>
        <attribute name="manifest:preferred-view-mode">
          <ref name="namespacedToken"/>
        </attribute>
      </optional>
    </define>

    We would pre-define the values

    manifest:edit
    manifest:presentation-slide-show
    manifest:read-only


    One question is whether we want to provide fallback values for user
    defined values, so that application that don't understand the user
    defined view mode can at least choose one of the pre-defined modes that
    is close to the use defined mode. If we want to have this, then we may
    define two attributes. One that is exactly what we have in the original
    proposal, and an additional one, let's say
    "manifest:extended-preferred-view-mode" that takes a namespaced value.
    Depending on whether we want the fallback value to be optional or
    mandatory, the schema may look like this:

    <define name="file-entry-attlist" combine="interleave">
      <optional>
        <attribute name="manifest:preferred-view-mode">
                <choice>
                <value>edit</value>
                <value>presentation-slide-show</value>
                <value>read-only</value>
                </choice>
        </attribute>
      </optional>
      <optional>
        <attribute name="manifest:extended-preferred-view-mode">
          <ref name="namespacedToken"/>
        </attribute>
      </optional>
    </define>

    or like this

    <define name="file-entry-attlist" combine="interleave">
      <optional>
        <attribute name="manifest:preferred-view-mode">
                <choice>
                <value>edit</value>
                <value>presentation-slide-show</value>
                <value>read-only</value>
                </choice>
        </attribute>
        <optional>
          <attribute name="manifest:extended-preferred-view-mode">
            <ref name="namespacedToken"/>
          </attribute>
        </optional>
      </optional>
    </define>

    Michael


    --
    Michael Brauer, Technical Architect Software Engineering
    StarOffice/OpenOffice.org
    Sun Microsystems GmbH             Nagelsweg 55
    D-20097 Hamburg, Germany          michael.brauer@sun.com
    http://sun.com/staroffice         +49 40 23646 500
    http://blogs.sun.com/GullFOSS

    Sitz der Gesellschaft: Sun Microsystems GmbH, Sonnenallee 1,
       D-85551 Kirchheim-Heimstetten
    Amtsgericht Muenchen: HRB 161028
    Geschaeftsfuehrer: Thomas Schroeder, Wolfgang Engels, Dr. Roland Boemer
    Vorsitzender des Aufsichtsrates: Martin Haering


    ---------------------------------------------------------------------
    To unsubscribe from this mail list, you must leave the OASIS TC that
    generates this mail.  Follow this link to all your TCs in OASIS at:
    https://www.oasis-open.org/apps/org/workgroup/portal/my_workgroups.php