Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

225
Vistas
getScreenCTM() on svg elements yield bad results on FireFox

when working with <svg> in FireFox, getScreenCTM() does not take transforms applied outside of the outermost <svg> element into account.

applying a transform to an enclosing <div> will cause unwanted behavior. here is an example: JSFiddle: getScreenCTM() not working in FireFox

If opened in Chrome, everything works fine. in FireFox, neither the rotation nor scale applied on the outer <div> elements have any effect of the SVGMatrix that's returned from rect.getScreenCTM().inverse(), thus detaching the <rect> element from the mouse position.

If you comment out the #scale and #rotate sections of the CSS file, you'd get a different transformation matrix in Chrome(as expected) and the same one in Firefox which is exactly the problem.

I tried working around this by applying the <div> transforms manually, as seen here: JSFiddle: Manually Applying transforms

This neither worked nor produced consistent result across Chrome and FireFox.

I've seen several reports on Bugzilla from years ago describing a similar bug but these are very old. There are also questions here of StackOverflow regarding the matter but they are not exactly the same, plus the last one was posted in 2016.

I'm trying to tackle this for a while now and I'm at a complete loss. Help would be very much appreciated!

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

I think this is in relations to: https://bugzilla.mozilla.org/show_bug.cgi?id=1610093

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda