I'm creating a simple asteroids-like game in CSS and JS using the DOM over canvas for...experimentation purposes.   My code is pretty small in this example to make it easy to see what's going on below. The ultimate goal: Let arrow keys smooth...
Let's say I have a div that had translateX and translateY values added dynamically.  <div class="object child0"       style="-webkit-transform: translateX(873.5px) translateY(256px);              width: 50px; height: 50px;">...
I need to obtain actual height of several different elements (for the sake of precise custom tooltip positioning), and some of these elements (not all) are rotated. $(elem).outerHeight() returns the original height, instead of the actual displayed he...
I'm using this script that claims to implement matrix3d operation as described in the spec, however the script is missing matrix perspective operations, so I "cooked" something I'm not sure is either accurate or correct.  // the persp...
When CSS elements are transformed out of their original location the transform-origin doesn't move with them; making all subsequent transforms and rotations still originate from it's original transform-origin ( example below ).  There is one...
I would like to change the transform origin to the center point of the pinch gesture.  This working code (safariDevSample) applies scale and rotation without changing the transform-origin:  window.angle = 0; //global to store data for later reset ......
On my page I have an element that follows users cursor. What I'm trying to do is to use transform instead top/left with plain javascript. Without any libraries or depencies... The problem is that I need to apply values stored in variables to the...
I made this http://codepen.io/adamchenwei/pen/dOvJNX  and I try to apply a certain way of moving for a dom so it move for a fixed distance and stop, instead of animate and move through the whole width of the dom. However, I don't really want to f...
jQuery doesn't work well with CSS "transform: scale()" (however with "transform: translate()" it works fine)  Please take a look at this simple example:    $(document).ready(function() {    $('#root').dblclick(function() {...
Here is my css code:  #pic-1 {     z-index: 1;     -webkit-transform: rotate(-10deg);     -moz-transform: rotate(-10deg);     -o-transform: rotate(-10deg);     transform: rotate(-10deg);     -ms-transform: rotate(-10deg);     filter: progid:DXImageTr...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.