Displace this atom in place
310
def displace!(x,y,z)
      self.x += x
      self.y += y
      self.z += z
    end
1268604
function Place (opts) {
    Place.superclass.constructor.call(this, opts)
    this.position = util.copy(opts.position)
}
910712
function make() {
      var _this = this;

      var offset = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;

      this.offset = offset;

      Events.emit('move', {
        movement: this.value
      });

      Components.Transition.after(function () {
        Events.emit('move.after', {
          movement: _this.value
        });
      });
    }
277893
function (element) {
        var buffer = element.buffer;
    
        return !(
            this.bottom < (element.top - buffer) || // Element off bottom
            this.top > (element.bottom + buffer) || // Element off top
            this.left > (element.right + buffer) || // Element off left
            this.right < (element.left - buffer)    // Element off right
        );
    }
82041
def remove(h, i):
    """"""
    n = h.size() - 1
    if n != i:
        h.swap(i, n)
        down(h, i, n)
        up(h, i)

    return h.pop()
922784
function occupySlice(
  targetArr: Array<?string>,
  start: number,
  end: number,
  componentKey: string
): void {
  // eslint-disable-next-line no-plusplus
  for (let ii = start; ii < end; ii++) {
    // eslint-disable-next-line no-param-reassign
    targetArr[ii] = componentKey;
  }
}
809629
private void bondAtom(IAtomContainer container, IAtom atom) {
        double myCovalentRadius = atom.getCovalentRadius();
        double searchRadius = myCovalentRadius + maxCovalentRadius + bondTolerance;
        Point tupleAtom = new Point(atom.getPoint3d().x, atom.getPoint3d().y, atom.getPoint3d().z);
        for (Bspt.EnumerateSphere e = bspt.enumHemiSphere(tupleAtom, searchRadius); e.hasMoreElements();) {
            IAtom atomNear = ((TupleAtom) e.nextElement()).getAtom();
            if (!atomNear.equals(atom) && container.getBond(atom, atomNear) == null) {
                boolean bonded = isBonded(myCovalentRadius, atomNear.getCovalentRadius(), e.foundDistance2());
                if (bonded) {
                    IBond bond = atom.getBuilder().newInstance(IBond.class, atom, atomNear, IBond.Order.SINGLE);
                    container.addBond(bond);
                }
            }
        }
    }
273043
def apply(self, coordinates):
        """"""
        for i in self.affected_atoms:
            coordinates[i] = self.transformation*coordinates[i]
157706
def _strip_stray_atoms(self):
        
        components = self.bond_graph.connected_components()
        major_component = max(components, key=len)
        for atom in list(self.particles()):
            if atom not in major_component:
                self.remove(atom)
1284325
function fixElementPosition() {
        var style = util.getComputedStyle(element);

        // if the element is not positioned, add position relative so the
        // iframe can be positioned properly
        if (style && style.position === 'static') {
            $(element).css({ position: 'relative' });
        }
    }
16797
def move(self, d_xyz):
        
        return Space(Place(self)).move(d_xyz, inplace=False)[0].surface
357042
public static final void shift(Atom a, Atom b){

		Atom natom = add(a,b);
		double x = natom.getX();
		double y = natom.getY() ;
		double z = natom.getZ();
		a.setX(x);
		a.setY(y);
		a.setZ(z);
	}
1127746
def _consolidate_inplace(self):
        """"""

        def f():
            self._data = self._data.consolidate()

        self._protect_consolidate(f)
263755
def randomize_molecule_low(molecule, manipulations):
    """"""

    manipulations = copy.copy(manipulations)
    shuffle(manipulations)
    coordinates = molecule.coordinates.copy()
    for manipulation in manipulations:
        manipulation.apply(coordinates)
    return molecule.copy_with(coordinates=coordinates)
1168036
public static void shift(Atom[] ca, Atom b) {
		for (Atom atom : ca)
			Calc.shift(atom, b);
	}
640010
def discard(self, element):
        """"""
        key = self._transform(element)
        if key in self._elements:
            del self._elements[key]
1032939
function() {
    $("body").css({width: $(window).width(), minHeight: $(window).height() });
    var $ass = $(".assignment");
    // reposition the assignment tab
    if ($ass.hasClass("hidden")) { // assignment tab hidden, need to reposition
      $ass.css({left: "-" + $ass.find(".assignmentText").outerWidth() + "px"});
    }
    // position the timer bar
    $("#timer").css({top: $("#header").innerHeight()});
  }