Re: [dev] Using matrices for rotation of graphical objects
Hi Regina, Ok I will try to ask on d...@api.openoffice.org. Thank you very much. Thibault. - Mail Original - De: "Regina Henschel" À: dev@openoffice.org Envoyé: Vendredi 26 Mars 2010 00:06:44 Objet: Re: [dev] Using matrices for rotation of graphical objects Hi Thibault, Thibault Vataire schrieb: > Hi, > > I use a trick to rotate the image : I convert the image (which is a com.sun.star.text.TextGraphicObject object) into com.sun.star.drawing.GraphicObjectShape object. > It is this new object that I want to rotate. I'm not sure whether this is a defect or desired behavior. In my experiments I see this behavior: When you apply the new matrix, the translation part of it is used for "from left to paragraph area" and "from top to margin". That is true for all anchor types of form "to". Anchored "as Character" it is "from bottom to base line" vertically, horizontal part is ignored. Perhaps you ask in d...@api.openoffice.org? kind regards Regina > > > - Mail Original - > De: "Regina Henschel" > À: dev@openoffice.org > Envoyé: Jeudi 25 Mars 2010 00:34:15 > Objet: Re: [dev] Using matrices for rotation of graphical objects > > Hi Thibault, > > Thibault Vataire schrieb: >> Hi, >> >> I'm working on an extension that allow to rotate images in Writer, in the >> meanwhile that this function was added to OpenOffice.org. >> Some users asked me to add predefined values like rotate 90°, but I >> encounter some difficulties to use the matrices for rotation. >> I've found how to compute values for the first and the second column of the >> matrix, but not for the third. >> >> These values seems to be the new position of the initial upper left corner >> of the shape. >> >> Is somebody know how to compute these values ? >> > > I'm a little bit confused. If you have a Draw shape, then there is a > transformation matrix, but that is not a new function. If you have a > TextGraphicObject, then there is no transformation matrix. So what kind > of object you are speaking about? > > kind regards > Regina > > - > To unsubscribe, e-mail: dev-unsubscr...@openoffice.org > For additional commands, e-mail: dev-h...@openoffice.org > > > - > To unsubscribe, e-mail: dev-unsubscr...@openoffice.org > For additional commands, e-mail: dev-h...@openoffice.org > > - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org
Re: [dev] Using matrices for rotation of graphical objects
Hi Thibault, Thibault Vataire schrieb: Hi, I use a trick to rotate the image : I convert the image (which is a com.sun.star.text.TextGraphicObject object) into com.sun.star.drawing.GraphicObjectShape object. It is this new object that I want to rotate. I'm not sure whether this is a defect or desired behavior. In my experiments I see this behavior: When you apply the new matrix, the translation part of it is used for "from left to paragraph area" and "from top to margin". That is true for all anchor types of form "to". Anchored "as Character" it is "from bottom to base line" vertically, horizontal part is ignored. Perhaps you ask in d...@api.openoffice.org? kind regards Regina - Mail Original - De: "Regina Henschel" À: dev@openoffice.org Envoyé: Jeudi 25 Mars 2010 00:34:15 Objet: Re: [dev] Using matrices for rotation of graphical objects Hi Thibault, Thibault Vataire schrieb: Hi, I'm working on an extension that allow to rotate images in Writer, in the meanwhile that this function was added to OpenOffice.org. Some users asked me to add predefined values like rotate 90°, but I encounter some difficulties to use the matrices for rotation. I've found how to compute values for the first and the second column of the matrix, but not for the third. These values seems to be the new position of the initial upper left corner of the shape. Is somebody know how to compute these values ? I'm a little bit confused. If you have a Draw shape, then there is a transformation matrix, but that is not a new function. If you have a TextGraphicObject, then there is no transformation matrix. So what kind of object you are speaking about? kind regards Regina - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org
Re: [dev] Using matrices for rotation of graphical objects
Hi, I use a trick to rotate the image : I convert the image (which is a com.sun.star.text.TextGraphicObject object) into com.sun.star.drawing.GraphicObjectShape object. It is this new object that I want to rotate. Best regards, T. Vataire - Mail Original - De: "Regina Henschel" À: dev@openoffice.org Envoyé: Jeudi 25 Mars 2010 00:34:15 Objet: Re: [dev] Using matrices for rotation of graphical objects Hi Thibault, Thibault Vataire schrieb: > Hi, > > I'm working on an extension that allow to rotate images in Writer, in the > meanwhile that this function was added to OpenOffice.org. > Some users asked me to add predefined values like rotate 90°, but I encounter > some difficulties to use the matrices for rotation. > I've found how to compute values for the first and the second column of the > matrix, but not for the third. > > These values seems to be the new position of the initial upper left corner of > the shape. > > Is somebody know how to compute these values ? > I'm a little bit confused. If you have a Draw shape, then there is a transformation matrix, but that is not a new function. If you have a TextGraphicObject, then there is no transformation matrix. So what kind of object you are speaking about? kind regards Regina - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org
Re: [dev] Using matrices for rotation of graphical objects
Hi Thibault, Thibault Vataire schrieb: Hi, I'm working on an extension that allow to rotate images in Writer, in the meanwhile that this function was added to OpenOffice.org. Some users asked me to add predefined values like rotate 90°, but I encounter some difficulties to use the matrices for rotation. I've found how to compute values for the first and the second column of the matrix, but not for the third. These values seems to be the new position of the initial upper left corner of the shape. Is somebody know how to compute these values ? I'm a little bit confused. If you have a Draw shape, then there is a transformation matrix, but that is not a new function. If you have a TextGraphicObject, then there is no transformation matrix. So what kind of object you are speaking about? kind regards Regina - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org
[dev] Using matrices for rotation of graphical objects
Hi, I'm working on an extension that allow to rotate images in Writer, in the meanwhile that this function was added to OpenOffice.org. Some users asked me to add predefined values like rotate 90°, but I encounter some difficulties to use the matrices for rotation. I've found how to compute values for the first and the second column of the matrix, but not for the third. These values seems to be the new position of the initial upper left corner of the shape. Is somebody know how to compute these values ? Best regards, Thibault Vataire. - To unsubscribe, e-mail: dev-unsubscr...@openoffice.org For additional commands, e-mail: dev-h...@openoffice.org