[prev in list] [next in list] [prev in thread] [next in thread] 

List:       koffice-devel
Subject:    Re: Re: Re: [karbon14] Rotate tool
From:       Dirk_Schönberger <dirk.schoenberger () sz-online ! de>
Date:       2002-10-09 7:38:14
[Download RAW message or body]

> An affine trafo is not more special than any other command.
I know that you are not a big friend of affine transformations as a special
case, but that's why I posted my question to the mailing list. Perhaps there
are other opinions... :)

Basically, what I would like to see, is something like in SVG, where you can
specify
the transformations like in (the SVG fragment)

<g transform="translate(50,50)">
    <g fill="none" stroke="red" stroke-width="3" >
       ....
    </g>
</g>

a SVG g tag would be equivalent to a VGroup in Karbon14. transform tags
should be available to Groups and VComposites, because the more basic SVG
primitives
like <line .../>, <rect ... /> are not aailable in karbon14.

Affine transformations, which should be explicitly storeable, include

matrix(<a> <b> <c> <d> <e> <f>)
translate(<tx> [<ty>])
scale(<sx> [<sy>])
rotate(<rotate-angle> [<cx> <cy>])
skewX(<skew-angle>)
skewY(<skew-angle>)

Operations should be able to sequenced, as in

<g transform="translate(-10,-20) scale(2) rotate(45) translate(5,10)">
  <!-- graphics elements go here -->
</g>

> We could
> save the command history in the future, but making a command "a part of
> a vcomposite" create very wrong dependencies between core objects and
> additonal operations (= commands).

Beside explicitly storing them into the DOM (or rather the external
represenations, because serialization / de-serialization of the result
matrix should only be done in the saveToXML, loadFromXML methods), they
could also be stored as part of the action list, like in

<actions>
  <transform transformation="translate(10,10)" items="1,20,35,345" />
</actions>

This should create no dependencies between VComposites and Tools/Actions,
because the store/load could be done in a special Iterator or something like
that.

Regards
Dirk





_______________________________________________
koffice-devel mailing list
koffice-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/koffice-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic