Sets the zoom level for the current scene, updating all the \
        views that it is connected to.
        
        :param      amount      <int>  (100 based %)
12205
def setZoomAmount(self, amount):
        
        amount = max(self._minZoomAmount, amount)
        amount = min(self._maxZoomAmount, amount)
        
        # only update when necessary
        if amount == self.zoomAmount():
            return
        
        # calculate the scalar value
        scale = (amount / 100.0)
        
        # assign the new transform to all of the views
        view = self.mainView()
        view.setTransform(QTransform.fromScale(scale, scale))
        
        # emit the value changed signal for the scene
        if not (self.signalsBlocked() or view.signalsBlocked()):
            view.zoomAmountChanged.emit(amount)
1207193
def _set_bank_view(self, session):
        """"""
        if self._bank_view == FEDERATED:
            try:
                session.use_federated_bank_view()
            except AttributeError:
                pass
        else:
            try:
                session.use_isolated_bank_view()
            except AttributeError:
                pass
611871
void increment(double amount) {
    spectatorCounter.add(amount);
    if (amount >= 0.0) {
      for (int i = 0; i < Pollers.NUM_POLLERS; ++i) {
        add(count.getCurrent(i), amount);
      }
    }
  }
1213844
public void zoomNext() {
		if (hasNext()) {
			MapViewChangedEvent data = next.remove();
			previous.addFirst(data);
			active = false;
			mapView.applyBounds(data.getBounds(), MapView.ZoomOption.LEVEL_CLOSEST);
			updateActionsAbility();
		}
	}
1224896
def zoomTo(self, bbox):
        ''
        self.fixPoint(self.plotviewBox.xymin, bbox.xymin)
        self.zoomlevel=max(bbox.w/self.canvasBox.w, bbox.h/self.canvasBox.h)
7998
def scale_cb(self, setting, value):
        """"""
        zoomlevel = self.zoom.calc_level(value)
        self.t_.set(zoomlevel=zoomlevel)

        self.redraw(whence=0)
303326
public void setZoom(int zoom)
    {
        zoomChanging = true;
        mainMap.setZoom(zoom);
        miniMap.setZoom(mainMap.getZoom() + 4);
        if (sliderReversed)
        {
            zoomSlider.setValue(zoomSlider.getMaximum() - zoom);
        }
        else
        {
            zoomSlider.setValue(zoom);
        }
        zoomChanging = false;
    }
624533
private void setScaleStrokeWidth(byte zoomLevel) {
        int zoomLevelDiff = Math.max(zoomLevel - STROKE_MIN_ZOOM_LEVEL, 0);
        this.renderTheme.scaleStrokeWidth((float) Math.pow(STROKE_INCREASE, zoomLevelDiff), this.rendererJob.tile.zoomLevel);
    }
181265
def set_viewup(self, vector):
        
        if isinstance(vector, np.ndarray):
            if vector.ndim != 1:
                vector = vector.ravel()
        self.camera.SetViewUp(vector)
        self._render()
596710
void increment(double amount) {
    if (amount >= 0.0) {
      for (int i = 0; i < ServoPollers.NUM_POLLERS; ++i) {
        add(count.getCurrent(i), amount);
      }
    }
  }
47556
def scrollParts( self, amount ):
        
        change = self._scrollAmount - amount
        self._partsWidget.scroll(change, 0)
        self._scrollAmount = amount
280075
function setBlendMode(mode, context) {
         context = context || this.getContext();
         this.currentBlendMode = mode;

         switch (mode) {
           case "multiply":
             context.globalCompositeOperation = "multiply";
             break;

           default:
             // normal
             context.globalCompositeOperation = "source-over";
             this.currentBlendMode = "normal";
             break;
         }
       }
347328
private void updateMaxExtent() {
		if (targetMap.getMapModel().isInitialized() && getGraphics().isReady()) {
			// map view size may not have been set yet !
			getMapModel().getMapView().setSize(getWidth(), getHeight());
			Bbox targetMaxBounds = getOverviewMaxBounds();

			MapView mapView = getMapModel().getMapView();

			// Set the maxBounds on this map as well:
			mapView.setMaxBounds(targetMaxBounds.buffer(targetMaxBounds.getWidth()));

			// apply buffer
			if (maxExtentIncreasePercentage > 0) {
				targetMaxBounds = targetMaxBounds
						.buffer(targetMaxBounds.getWidth() * maxExtentIncreasePercentage / 100);
			}

			// Then apply the map extent:
			mapView.applyBounds(targetMaxBounds, MapView.ZoomOption.LEVEL_FIT);

			// Immediately draw or remove the max extent rectangle:
			setDrawTargetMaxExtent(drawTargetMaxExtent);
		}
	}
104060
def set_viewlimits(self, axes=None):
        
        if axes is None:
            axes = self.axes

        xmin, xmax, ymin, ymax = self.data_range
        if len(self.conf.zoom_lims) >1:
            zlims = self.conf.zoom_lims[-1]
            if axes in zlims:
                xmin, xmax, ymin, ymax = zlims[axes]

        xmin = max(self.data_range[0], xmin)
        xmax = min(self.data_range[1], xmax)
        ymin = max(self.data_range[2], ymin)
        ymax = min(self.data_range[3], ymax)
        if (xmax < self.data_range[0] or
            xmin > self.data_range[1] or
            ymax < self.data_range[2] or
            ymin > self.data_range[3] ):
            self.conf.zoom_lims.pop()
            return

        if abs(xmax-xmin) < 2:
            xmin = int(0.5*(xmax+xmin) - 1)
            xmax = xmin + 2

        if abs(ymax-ymin) < 2:
            ymin = int(0.5*(ymax+xmin) - 1)
            ymax = ymin + 2

        self.axes.set_xlim((xmin, xmax),emit=True)
        self.axes.set_ylim((ymin, ymax),emit=True)
        self.axes.update_datalim(((xmin, ymin), (xmax, ymax)))

        self.conf.datalimits = [xmin, xmax, ymin, ymax]
        self.redraw()
122030
def set_level(self, level):
        
        for handler in self.__coloredlogs_handlers:
            handler.setLevel(level=level)

        self.logger.setLevel(level=level)
1145339
def set_scale(self, xscale=None, yscale=None, zscale=None, reset_camera=True):
        
        if xscale is None:
            xscale = self.scale[0]
        if yscale is None:
            yscale = self.scale[1]
        if zscale is None:
            zscale = self.scale[2]
        self.scale = [xscale, yscale, zscale]

        # Update the camera's coordinate system
        transform = vtk.vtkTransform()
        transform.Scale(xscale, yscale, zscale)
        self.camera.SetModelTransformMatrix(transform.GetMatrix())
        self.parent._render()
        if reset_camera:
            self.update_bounds_axes()
            self.reset_camera()
609274
public void update(Viewer viewer)
    {
        x = (int) viewer.getX();
        y = (int) viewer.getY() - viewer.getViewY();
        height = viewer.getHeight();
    }