OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

office message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Direction of radial gradients


The spec is unclear about the direction of radial gradients:

> 18.354 draw:start-color 
> The draw:start-color attributes specifies the start value for the <draw:gradient> element, which interpolates between the value 
> of this attribute and draw:end-color. 
> The draw:start-color attribute may be used with the following element: <draw:gradient> 15.17.1 

And similar for end-color, but it doesn't say which color is the inner color and which is the
outer color for a radial gradient.

Testing with OpenOffice: creating a radial gradient gives:

<draw:gradient draw:name="Radial_20_red_2f_yellow" draw:display-name="Radial
red/yellow" draw:style="radial" draw:cx="50%" draw:cy="50%"
draw:start-color="#ff3333" draw:end-color="#e6ff00"
draw:start-intensity="100%" draw:end-intensity="100%" draw:border="0%"/>

start-color is red and end-color is yellow.

At the moment we have the following situation (example image attached):
KOffice (Karbon): start-color is the inner color, end-color the outer
OpenOffice: start-color is the outer, end-color the inner

In SVG the first color stop is the most inner color and the last stop the
most outer color.

The OpenDocument specification needs to be clearer about how the colors 
need to be handled, especially since OpenOffice and SVG have a different
view on the question.

In 1.1 the specification also said:
> 14.14.1 Colors is the following:
> The gradient interpolates between a start color and an end color, which are
> specified using the attributes draw:start-color and draw:end-color.
but I don't see this in 1.2-draft7 ?

The specification could say something like: "If the gradient is radial, ... 
then start-color is the inner color and end-color is the outer color",
if we decide to follow the OpenOffice behavior.

-- 
David Faure, faure@kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).

radialgradient.odg

odfradialgradient.png



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]