- #1
rekshaw
- 15
- 0
Hey all,
BACKGROUND: (please note that knowledge of this is not necessary):
I'm currently writing a javascript application using vectors (with jquery and raphaeljs) that enables me to rotate custom text (using font.js file, not normal fonts). However, due to a bug in the new version of raphael, when I rotate a text made up of multiple letters, all the letters rotate on their own relative center.
Don't worry, I'm not asking you to help me debug my scripting language, I'm asking you to help me get around this bug by manually calculating the translating movements (x and y) of each letter.
If I wasn't clear until now, don't worry, I'll show you exactly what I need (quick photoshop):
MATHEMATICAL PROBLEM:
[PLAIN]http://img534.imageshack.us/img534/1780/rotationtranslation.png
Variables I know:
- the angle a
- the angles b
- the 2 sides K
I need to find the blue and orange (y and x) lengths in order to translate my letters properly.
BACKGROUND: (please note that knowledge of this is not necessary):
I'm currently writing a javascript application using vectors (with jquery and raphaeljs) that enables me to rotate custom text (using font.js file, not normal fonts). However, due to a bug in the new version of raphael, when I rotate a text made up of multiple letters, all the letters rotate on their own relative center.
Don't worry, I'm not asking you to help me debug my scripting language, I'm asking you to help me get around this bug by manually calculating the translating movements (x and y) of each letter.
If I wasn't clear until now, don't worry, I'll show you exactly what I need (quick photoshop):
MATHEMATICAL PROBLEM:
[PLAIN]http://img534.imageshack.us/img534/1780/rotationtranslation.png
Variables I know:
- the angle a
- the angles b
- the 2 sides K
I need to find the blue and orange (y and x) lengths in order to translate my letters properly.
Last edited by a moderator: