2 * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
3 * Copyright (C) 2006 - INRIA - Jean-Baptiste Silvy
5 * This file must be used under the terms of the CeCILL.
6 * This source file is licensed as described in the file COPYING, which
7 * you should have received as part of this distribution. The terms
8 * are also available at
9 * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
13 /*------------------------------------------------------------------------*/
14 /* file: axesScale.h */
15 /* desc : Contains functions to compute scale changes in a specific */
17 /*------------------------------------------------------------------------*/
19 #ifndef _AXES_SCALE_H_
20 #define _AXES_SCALE_H_
21 #include "dynlib_graphics.h"
22 #include "ObjectStructure.h"
24 /*------------------------------------------------------------------------------*/
25 GRAPHICS_IMPEXP int sciZoom2D(char * subwinUID, const double zoomRect[4]);
26 GRAPHICS_IMPEXP int sciZoom3D(char * subwinUID, const double zoomBox[6]);
27 GRAPHICS_IMPEXP int sciZoomRect(sciPointObj * pObj, const double zoomRect[4]);
28 GRAPHICS_IMPEXP int sciDefaultZoom2D(const double zoomRect[4]);
29 GRAPHICS_IMPEXP int sciFigureZoom2D(sciPointObj * figure, const double zoomRect[4]);
30 GRAPHICS_IMPEXP void sciGetZoom3D(sciPointObj * pObj, double zoomBox[6]);
31 GRAPHICS_IMPEXP void sciDefaultInteractiveZoom(void);
32 GRAPHICS_IMPEXP void sciInteractiveZoom(sciPointObj * pObj);
33 GRAPHICS_IMPEXP void sciUnzoomSubwin(char* subwinUID);
34 GRAPHICS_IMPEXP void sciUnzoomFigure(char* figureUID);
35 GRAPHICS_IMPEXP void sciUnzoomArray(char* objectsUID[], int nbSubwin);
38 * Update subwin size and scale if needed
40 GRAPHICS_IMPEXP void updateSubwinScale(char * pSubwinUID);
43 * Update text bounds if needed
45 GRAPHICS_IMPEXP void updateTextBounds(char * pTextUID);
48 * Zoom an object using a rectangular selection given in pixels.
49 * @param pObj must be a figure or subwin handle
50 * @param x1 X coordinate of a corner of the selection
51 * @param y1 Y coordinate of a corner of the selection
52 * @param x2 X coordinate of the oppoiste corner of the selection
53 * @param y2 Y coordinate of the opposite corner of the selection
55 GRAPHICS_IMPEXP void sciZoomObject(sciPointObj * pObj, int x1, int y1, int x2, int y2);
60 GRAPHICS_IMPEXP void unzoomSubwin(sciPointObj * pSubwin);
61 /*------------------------------------------------------------------------------*/
62 GRAPHICS_IMPEXP BOOL checkDataBounds(char * subwinUID, double xMin, double xMax,
63 double yMin, double yMax, double zMin, double zMax);
64 /*------------------------------------------------------------------------------*/
67 #endif /* _AXES_SCALE_H_ */