public void paint(java.awt.Graphics g_) {
		Graphics2D g = (Graphics2D) g_;
		g.setColor(Color.LIGHT_GRAY);
		g.fillRect(0, 0, getWidth(), getHeight());
		Utilities.drawCheckerPattern(g.create(0, 0, getViewWidth(), getViewHeight()),checkerSize);
		g.drawImage(image,0,0, image.getWidth()*zoom, image.getHeight()*zoom,0,0,image.getWidth(),image.getHeight(),null);
		for(Object selected: editorFrame.animationManager.getSelectedObjects()) {
			if(selected instanceof Animation) {
				Animation animation = (Animation) selected;
				for(Frame frame: animation.getFrames()) {
					paintFrame(g, frame);
				}
			} 
			if (selected instanceof Frame) {
				Frame frame = (Frame) selected;
				paintFrame(g,frame);
			}		
		}
		if(freeOffsetStart != null && freeOffsetEnd != null) {
			Point base = toScreen(freeOffsetStart);
			Point vector = toScreen(new Point(freeOffsetEnd.x-freeOffsetStart.x, freeOffsetEnd.y-freeOffsetStart.y));
			g.setColor(Color.RED);
			drawArrow(g, vector, base);
		}
		if(parent.isSettingOffsetWithTemporaryPivot()) {
			Point pivot1 = parent.temporaryPivotOffsetButton.getPivot1();
			Point pivot2 = parent.temporaryPivotOffsetButton.getPivot2();
			if(pivot1!=null) {
				g.setColor(Color.GREEN);
				Point framePivot = parent.temporaryPivotOffsetButton.getPrevFramePivot();
				Point vector = new Point(pivot1.x-framePivot.x, pivot1.y-framePivot.y);
				drawArrow(g, toScreen(vector), toScreen(framePivot));
			}
			if(pivot2!=null) {
				g.setColor(Color.GREEN);
				Point framePivot = parent.temporaryPivotOffsetButton.getCurFramePivot();
				Point vector = new Point(pivot2.x-framePivot.x, pivot2.y-framePivot.y);
				drawArrow(g, toScreen(vector), toScreen(framePivot));
			}
		}
	}